LLMモジュールの標準スタックは、ちっとも公開されない風なので、OSSで国産のREMDISを試してみる。たぶん、RAM不足で動かないと思うけど。
REMDIS(Realtime Multimodal Dialogue System Toolkit)はこれ。
remdis/remdis: The Remdis toolkit: Building advanced real-time multimodal dialogue systems with incremental processing and large language models
https://github.com/remdis/remdis
本は出ているのだけど、Windows/macOSへのインストールがメインで、Linuxベースのインストールの解説はない。Pythonの仮想環境ベースなので、そんなに変わらない気もするのだけど。
デフォルトの構成と変更する部分は以下の予定。
・RabbitMQをDockerで利用しているが、これはネイティブ動作のものにする。
・LLMは外部商用APIを利用するようになっているが、これはLLMモジュール内部で動いているものを使用するか、メモリきつそうなのでmacOS側でOllamaにアクセスするようにする。
・GUIは持っていないので、エージェントインターフェイスであるMMDAgent-EXは使用しない。
・Python仮想環境は、uvを使用する。
ストーレジあんま空いてないな... まぁしょうがない。
root@m5stack-LLM:~# df -h /
Filesystem Size Used Avail Use% Mounted on
/dev/root 28G 19G 9.1G 68% /
これは、3.11以降が必要だっけか...
root@m5stack-LLM:~# python3 --version
Python 3.10.12
RabbitMQのインストール
まずは、Erlang環境を整備する必要がある。
パッケージでインストールできるのは、erlang-base 1:24.2.1+dfsg-1ubuntu0.1だ。
Ealangはプロジェクトで、debパッケージを独自にリリースしているので、最新版を必要とする場合は、そのリポジトリを利用することになる。ざっと見ると、最新版は25.2.2-2だった。しかし、arm64環境で利用できるパッケージは、jammy対応だと見当たらないな...
リポジトリの追加に必要なcurl, gnupgパッケージはデフォルトでインストールされている。
リポジトリを追加する。
root@m5stack-LLM:~# curl -fsSL https://packages.erlang-solutions.com/ubuntu/erlang_solutions.asc | sudo tee /etc/apt/trusted.gpg.d/erlang.asc
-----BEGIN PGP PUBLIC KEY BLOCK-----
Version: GnuPG v1.4.10 (GNU/Linux)
(snip)
-----END PGP PUBLIC KEY BLOCK-----
root@m5stack-LLM:~# echo "deb https://packages.erlang-solutions.com/ubuntu $(lsb_release -cs) contrib" | sudo tee /etc/apt/sources.list.d/erlang.list
deb https://packages.erlang-solutions.com/ubuntu jammy contrib
root@m5stack-LLM:~# cat /etc/apt/sources.list.d/erlang.list
deb https://packages.erlang-solutions.com/ubuntu jammy contrib
パッケージデータベースの更新。
root@m5stack-LLM:~# sudo apt-get update
Hit:1 https://download.docker.com/linux/ubuntu jammy InRelease
Hit:2 http://ports.ubuntu.com/ubuntu-ports jammy InRelease
Get:3 http://ports.ubuntu.com/ubuntu-ports jammy-updates InRelease [128 kB]
Ign:4 https://packages.erlang-solutions.com/ubuntu jammy InRelease
Err:5 https://packages.erlang-solutions.com/ubuntu jammy Release
404 Not Found [IP: 18.173.121.39 443]
Hit:6 http://ports.ubuntu.com/ubuntu-ports jammy-backports InRelease
Get:7 http://ports.ubuntu.com/ubuntu-ports jammy-security InRelease [129 kB]
Get:8 http://ports.ubuntu.com/ubuntu-ports jammy-updates/main arm64 Packages [2022 kB]
Get:9 http://ports.ubuntu.com/ubuntu-ports jammy-updates/universe arm64 Packages [1144 kB]
Reading package lists... Done
E: The repository 'https://packages.erlang-solutions.com/ubuntu jammy Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
うわわん。jammy対応のリリースなんてないわって言われた...
無念。入れたファイルを削除。
root@m5stack-LLM:~# rm /etc/apt/trusted.gpg.d/erlang.gpg /etc/apt/sources.list.d/erlang.list
root@m5stack-LLM:~# sudo apt-get update
古いパッケージのものを入れる。なんか、いっぱい入っていやだわ。
root@m5stack-LLM:~# sudo apt-get install erlang
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following additional packages will be installed:
adwaita-icon-theme alsa-topology-conf alsa-ucm-conf aspell aspell-en
at-spi2-core bubblewrap ca-certificates-java dconf-gsettings-backend
dconf-service default-jre-headless dictionaries-common enchant-2 erlang-asn1
erlang-base erlang-common-test erlang-crypto erlang-debugger erlang-dev
erlang-dialyzer erlang-diameter erlang-edoc erlang-eldap erlang-erl-docgen
erlang-et erlang-eunit erlang-examples erlang-ftp erlang-inets
erlang-jinterface erlang-megaco erlang-mnesia erlang-mode erlang-observer
erlang-odbc erlang-os-mon erlang-parsetools erlang-public-key erlang-reltool
erlang-runtime-tools erlang-snmp erlang-src erlang-ssh erlang-ssl
erlang-syntax-tools erlang-tftp erlang-tools erlang-wx erlang-xmerl
fontconfig fuse3 glib-networking glib-networking-common
glib-networking-services gsettings-desktop-schemas gstreamer1.0-gl
gstreamer1.0-plugins-base gstreamer1.0-plugins-good gstreamer1.0-x
gtk-update-icon-cache hicolor-icon-theme humanity-icon-theme hunspell-en-us
iso-codes java-common libaa1 libasound2 libasound2-data libaspell15
libasyncns0 libatk-bridge2.0-0 libatk1.0-0 libatk1.0-data libatspi2.0-0
libavc1394-0 libcaca0 libcairo-gobject2 libcairo2 libcanberra0
libcdparanoia0 libcolord2 libcups2 libdatrie1 libdconf1 libdrm-amdgpu1
libdrm-common libdrm-nouveau2 libdrm-radeon1 libdrm2 libdv4 libdw1
libegl-mesa0 libegl1 libenchant-2-2 libepoxy0 libevdev2 libflac8 libfuse3-3
libgbm1 libgdk-pixbuf-2.0-0 libgdk-pixbuf2.0-bin libgdk-pixbuf2.0-common
libgl1 libgl1-amber-dri libgl1-mesa-dri libglapi-mesa libgles2 libglu1-mesa
libglvnd0 libglx-mesa0 libglx0 libgraphene-1.0-0 libgraphite2-3
libgstreamer-gl1.0-0 libgstreamer-plugins-base1.0-0
libgstreamer-plugins-good1.0-0 libgstreamer1.0-0 libgtk-3-0 libgtk-3-bin
libgtk-3-common libgudev-1.0-0 libharfbuzz-icu0 libharfbuzz0b
libhunspell-1.7-0 libhyphen0 libice6 libiec61883-0 libjack-jackd2-0
libjavascriptcoregtk-4.0-18 libjs-jquery-metadata libjs-jquery-tablesorter
libjson-glib-1.0-0 libjson-glib-1.0-common liblcms2-2 libllvm15
libmanette-0.2-0 libmp3lame0 libmpg123-0 libnotify4 libnspr4 libnss3
libodbc2 libogg0 libopengl0 libopus0 liborc-0.4-0 libpango-1.0-0
libpangocairo-1.0-0 libpangoft2-1.0-0 libpipewire-0.3-0
libpipewire-0.3-common libpipewire-0.3-modules libpixman-1-0
libpolkit-agent-1-0 libpolkit-gobject-1-0 libproxy1v5 libpulse0
libraw1394-11 librsvg2-2 librsvg2-common libsamplerate0 libsecret-1-0
libsecret-common libsensors-config libsensors5 libshout3 libsm6 libsndfile1
libsoup2.4-1 libsoup2.4-common libspa-0.2-modules libspeex1 libtag1v5
libtag1v5-vanilla libtdb1 libtext-iconv-perl libthai-data libthai0
libtheora0 libtwolame0 libunwind8 libvisual-0.4-0 libvorbis0a libvorbisenc2
libvorbisfile3 libvpx7 libwavpack1 libwayland-client0 libwayland-cursor0
libwayland-egl1 libwayland-server0 libwebkit2gtk-4.0-37 libwebpdemux2
libwebpmux3 libwebrtc-audio-processing1 libwoff1 libwxbase3.0-0v5
libwxgtk-webview3.0-gtk3-0v5 libwxgtk3.0-gtk3-0v5 libx11-xcb1 libxcb-dri2-0
libxcb-dri3-0 libxcb-glx0 libxcb-present0 libxcb-randr0 libxcb-render0
libxcb-shm0 libxcb-sync1 libxcb-xfixes0 libxcomposite1 libxcursor1
libxdamage1 libxfixes3 libxi6 libxinerama1 libxkbcommon0 libxrandr2
libxrender1 libxshmfence1 libxslt1.1 libxtst6 libxv1 libxxf86vm1
openjdk-11-jre-headless pipewire pipewire-bin pipewire-media-session pkexec
policykit-1 polkitd rtkit session-migration sound-theme-freedesktop
ubuntu-mono x11-common xdg-dbus-proxy xdg-desktop-portal
xdg-desktop-portal-gtk xkb-data
Suggested packages:
aspell-doc spellutils default-jre wordlist erlang-manpages erlang-doc
xsltproc fop gvfs hunspell openoffice.org-hunspell | openoffice.org-core
isoquery libasound2-plugins alsa-utils libcanberra-gtk0 libcanberra-pulse
colord cups-common libdv-bin oss-compat libenchant-2-voikko
libvisual-0.4-plugins gstreamer1.0-tools jackd2 liblcms2-utils gnome-shell
| notification-daemon odbc-postgresql tdsodbc opus-tools pulseaudio
libraw1394-doc librsvg2-bin lm-sensors speex gstreamer1.0-libav
gstreamer1.0-plugins-bad gstreamer1.0-alsa fonts-dejavu-extra
fonts-ipafont-gothic fonts-ipafont-mincho fonts-wqy-microhei
| fonts-wqy-zenhei fonts-indic accountsservice evince
xdg-desktop-portal-gnome
The following NEW packages will be installed:
adwaita-icon-theme alsa-topology-conf alsa-ucm-conf aspell aspell-en
at-spi2-core bubblewrap ca-certificates-java dconf-gsettings-backend
dconf-service default-jre-headless dictionaries-common enchant-2 erlang
erlang-asn1 erlang-base erlang-common-test erlang-crypto erlang-debugger
erlang-dev erlang-dialyzer erlang-diameter erlang-edoc erlang-eldap
erlang-erl-docgen erlang-et erlang-eunit erlang-examples erlang-ftp
erlang-inets erlang-jinterface erlang-megaco erlang-mnesia erlang-mode
erlang-observer erlang-odbc erlang-os-mon erlang-parsetools
erlang-public-key erlang-reltool erlang-runtime-tools erlang-snmp erlang-src
erlang-ssh erlang-ssl erlang-syntax-tools erlang-tftp erlang-tools erlang-wx
erlang-xmerl fontconfig fuse3 glib-networking glib-networking-common
glib-networking-services gsettings-desktop-schemas gstreamer1.0-gl
gstreamer1.0-plugins-base gstreamer1.0-plugins-good gstreamer1.0-x
gtk-update-icon-cache hicolor-icon-theme humanity-icon-theme hunspell-en-us
iso-codes java-common libaa1 libasound2 libasound2-data libaspell15
libasyncns0 libatk-bridge2.0-0 libatk1.0-0 libatk1.0-data libatspi2.0-0
libavc1394-0 libcaca0 libcairo-gobject2 libcairo2 libcanberra0
libcdparanoia0 libcolord2 libcups2 libdatrie1 libdconf1 libdrm-amdgpu1
libdrm-common libdrm-nouveau2 libdrm-radeon1 libdrm2 libdv4 libdw1
libegl-mesa0 libegl1 libenchant-2-2 libepoxy0 libevdev2 libflac8 libfuse3-3
libgbm1 libgdk-pixbuf-2.0-0 libgdk-pixbuf2.0-bin libgdk-pixbuf2.0-common
libgl1 libgl1-amber-dri libgl1-mesa-dri libglapi-mesa libgles2 libglu1-mesa
libglvnd0 libglx-mesa0 libglx0 libgraphene-1.0-0 libgraphite2-3
libgstreamer-gl1.0-0 libgstreamer-plugins-base1.0-0
libgstreamer-plugins-good1.0-0 libgstreamer1.0-0 libgtk-3-0 libgtk-3-bin
libgtk-3-common libgudev-1.0-0 libharfbuzz-icu0 libharfbuzz0b
libhunspell-1.7-0 libhyphen0 libice6 libiec61883-0 libjack-jackd2-0
libjavascriptcoregtk-4.0-18 libjs-jquery-metadata libjs-jquery-tablesorter
libjson-glib-1.0-0 libjson-glib-1.0-common liblcms2-2 libllvm15
libmanette-0.2-0 libmp3lame0 libmpg123-0 libnotify4 libnspr4 libnss3
libodbc2 libogg0 libopengl0 libopus0 liborc-0.4-0 libpango-1.0-0
libpangocairo-1.0-0 libpangoft2-1.0-0 libpipewire-0.3-0
libpipewire-0.3-common libpipewire-0.3-modules libpixman-1-0
libpolkit-agent-1-0 libpolkit-gobject-1-0 libproxy1v5 libpulse0
libraw1394-11 librsvg2-2 librsvg2-common libsamplerate0 libsecret-1-0
libsecret-common libsensors-config libsensors5 libshout3 libsm6 libsndfile1
libsoup2.4-1 libsoup2.4-common libspa-0.2-modules libspeex1 libtag1v5
libtag1v5-vanilla libtdb1 libtext-iconv-perl libthai-data libthai0
libtheora0 libtwolame0 libunwind8 libvisual-0.4-0 libvorbis0a libvorbisenc2
libvorbisfile3 libvpx7 libwavpack1 libwayland-client0 libwayland-cursor0
libwayland-egl1 libwayland-server0 libwebkit2gtk-4.0-37 libwebpdemux2
libwebpmux3 libwebrtc-audio-processing1 libwoff1 libwxbase3.0-0v5
libwxgtk-webview3.0-gtk3-0v5 libwxgtk3.0-gtk3-0v5 libx11-xcb1 libxcb-dri2-0
libxcb-dri3-0 libxcb-glx0 libxcb-present0 libxcb-randr0 libxcb-render0
libxcb-shm0 libxcb-sync1 libxcb-xfixes0 libxcomposite1 libxcursor1
libxdamage1 libxfixes3 libxi6 libxinerama1 libxkbcommon0 libxrandr2
libxrender1 libxshmfence1 libxslt1.1 libxtst6 libxv1 libxxf86vm1
openjdk-11-jre-headless pipewire pipewire-bin pipewire-media-session pkexec
policykit-1 polkitd rtkit session-migration sound-theme-freedesktop
ubuntu-mono x11-common xdg-dbus-proxy xdg-desktop-portal
xdg-desktop-portal-gtk xkb-data
0 upgraded, 240 newly installed, 0 to remove and 118 not upgraded.
Need to get 193 MB of archives.
After this operation, 707 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
(snip)
残量がつらい。
root@m5stack-LLM:~# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/root 28G 20G 8.2G 71% /
対話シェルを起動して動作確認。^Gで抜ける。
root@m5stack-LLM:~# erl
Erlang/OTP 24 [erts-12.2.1] [source] [64-bit] [smp:2:2] [ds:2:2:10] [async-threads:1]
Eshell V12.2.1 (abort with ^G)
1>
User switch command
--> quit
Unknown command
--> ?
c [nn] - connect to job
i [nn] - interrupt job
k [nn] - kill job
j - list all jobs
s [shell] - start local shell
r [node [shell]] - start remote shell
q - quit erlang
? | h - this message
--> q
抜けないんですが...
^C
BREAK: (a)bort (A)bort with dump (c)ontinue (p)roc info (i)nfo
(l)oaded (v)ersion (k)ill (D)b-tables (d)istribution
a
抜けた。こんなもんだったっけ? 太古のことで忘れたわ...
再度やると普通に抜けた。なんか初期化処理でもやっていたのかな?
root@m5stack-LLM:~# erl
Erlang/OTP 24 [erts-12.2.1] [source] [64-bit] [smp:2:2] [ds:2:2:10] [async-threads:1]
Eshell V12.2.1 (abort with ^G)
1>
User switch command
--> q
root@m5stack-LLM:~#
ようやく、RabbitMQのインストール。同じように専用のリポジトリがある。
root@m5stack-LLM:~# curl -fsSL https://packagecloud.io/rabbitmq/rabbitmq-server/gpgkey | sudo tee /etc/apt/trusted.gpg.d/rabbitmq.asc
-----BEGIN PGP PUBLIC KEY BLOCK-----
(snip)
-----END PGP PUBLIC KEY BLOCK-----
root@m5stack-LLM:~# echo "deb https://packagecloud.io/rabbitmq/rabbitmq-server/ubuntu/ $(lsb_release -cs) main" | sudo tee /etc/apt/sources.list.d/rabbitmq.list
deb https://packagecloud.io/rabbitmq/rabbitmq-server/ubuntu/ jammy main
root@m5stack-LLM:~# cat /etc/apt/sources.list.d/rabbitmq.list
deb https://packagecloud.io/rabbitmq/rabbitmq-server/ubuntu/ jammy main
パッケージデータベースのアップデート。こちらは無事に終わった。
root@m5stack-LLM:~# sudo apt-get update
Hit:1 https://download.docker.com/linux/ubuntu jammy InRelease
Hit:3 http://ports.ubuntu.com/ubuntu-ports jammy InRelease
Hit:4 http://ports.ubuntu.com/ubuntu-ports jammy-updates InRelease
Get:2 https://packagecloud.io/rabbitmq/rabbitmq-server/ubuntu jammy InRelease [29.9 kB]
Hit:5 http://ports.ubuntu.com/ubuntu-ports jammy-backports InRelease
Hit:6 http://ports.ubuntu.com/ubuntu-ports jammy-security InRelease
Get:7 https://packagecloud.io/rabbitmq/rabbitmq-server/ubuntu jammy/main arm64 Packages [16.7 kB]
Fetched 46.5 kB in 3s (17.0 kB/s)
Reading package lists... Done
インストールする。
root@m5stack-LLM:~# sudo apt-get install rabbitmq-server
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
rabbitmq-server : Depends: erlang-base (>= 1:26.0) but 1:24.2.1+dfsg-1ubuntu0.1 is to be installed or
erlang-base-hipe (>= 1:26.0) but it is not installable or
esl-erlang (>= 1:26.0) but it is not installable
Depends: erlang-crypto (>= 1:26.0) but 1:24.2.1+dfsg-1ubuntu0.1 is to be installed or
esl-erlang (>= 1:26.0) but it is not installable
Depends: erlang-eldap (>= 1:26.0) but 1:24.2.1+dfsg-1ubuntu0.1 is to be installed or
esl-erlang (>= 1:26.0) but it is not installable
Depends: erlang-inets (>= 1:26.0) but 1:24.2.1+dfsg-1ubuntu0.1 is to be installed or
esl-erlang (>= 1:26.0) but it is not installable
Depends: erlang-mnesia (>= 1:26.0) but 1:24.2.1+dfsg-1ubuntu0.1 is to be installed or
esl-erlang (>= 1:26.0) but it is not installable
Depends: erlang-os-mon (>= 1:26.0) but 1:24.2.1+dfsg-1ubuntu0.1 is to be installed or
esl-erlang (>= 1:26.0) but it is not installable
Depends: erlang-parsetools (>= 1:26.0) but 1:24.2.1+dfsg-1ubuntu0.1 is to be installed or
esl-erlang (>= 1:26.0) but it is not installable
Depends: erlang-public-key (>= 1:26.0) but 1:24.2.1+dfsg-1ubuntu0.1 is to be installed or
esl-erlang (>= 1:26.0) but it is not installable
Depends: erlang-runtime-tools (>= 1:26.0) but 1:24.2.1+dfsg-1ubuntu0.1 is to be installed or
esl-erlang (>= 1:26.0) but it is not installable
Depends: erlang-ssl (>= 1:26.0) but 1:24.2.1+dfsg-1ubuntu0.1 is to be installed or
esl-erlang (>= 1:26.0) but it is not installable
Depends: erlang-syntax-tools (>= 1:26.0) but 1:24.2.1+dfsg-1ubuntu0.1 is to be installed or
esl-erlang (>= 1:26.0) but it is not installable
Depends: erlang-tools (>= 1:26.0) but 1:24.2.1+dfsg-1ubuntu0.1 is to be installed or
esl-erlang (>= 1:26.0) but it is not installable
Depends: erlang-xmerl (>= 1:26.0) but 1:24.2.1+dfsg-1ubuntu0.1 is to be installed or
esl-erlang (>= 1:26.0) but it is not installable
E: Unable to correct problems, you have held broken packages.
あらー、依存関係で26.0以降のerlangがいるって。こうなると思ったけど。
追加したものを削除。
root@m5stack-LLM:~# rm /etc/apt/trusted.gpg.d/rabbitmq.asc /etc/apt/sources.list.d/rabbitmq.list
root@m5stack-LLM:~# sudo apt-get update
Hit:1 https://download.docker.com/linux/ubuntu jammy InRelease
Hit:2 http://ports.ubuntu.com/ubuntu-ports jammy InRelease
Hit:3 http://ports.ubuntu.com/ubuntu-ports jammy-updates InRelease
Hit:4 http://ports.ubuntu.com/ubuntu-ports jammy-backports InRelease
Hit:5 http://ports.ubuntu.com/ubuntu-ports jammy-security InRelease
Reading package lists... Done
Ubuntuのパッケージとしては、3.9.27-0ubuntu0.1があるので、それを入れる。
root@m5stack-LLM:~# sudo apt-get install rabbitmq-server
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following additional packages will be installed:
socat
The following NEW packages will be installed:
rabbitmq-server socat
0 upgraded, 2 newly installed, 0 to remove and 118 not upgraded.
Need to get 15.6 MB of archives.
After this operation, 24.4 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
(snip)
インストールすると、自動的に動作している。
root@m5stack-LLM:~# sudo systemctl status rabbitmq-server | more
● rabbitmq-server.service - RabbitMQ Messaging Server
Loaded: loaded (/lib/systemd/system/rabbitmq-server.service; enabled; vendo
r preset: enabled)
Active: active (running) since Thu 2025-01-23 17:47:35 CST; 29s ago
Main PID: 22754 (beam.smp)
Tasks: 24 (limit: 2357)
Memory: 81.0M
CPU: 18.913s
CGroup: /system.slice/rabbitmq-server.service
├─22754 /usr/lib/erlang/erts-12.2.1/bin/beam.smp -W w -MBas ageffcb
f -MHas ageffcbf -MBlmbcs 512 -MHlmbcs 512 -MMmcs 30 -P 1048576 -t 5000000 -stbt
db -zdbbl 128000 -sbwt none -sbwtdcpu none -sbwtdio none -- -root /usr/lib/erla
ng -progname erl -- -home /var/lib/rabbitmq -- -pa "" -noshell -noinput -s rabbi
t boot -boot start_sasl -syslog logger "[]" -syslog syslog_error_logger false -k
ernel prevent_overlapping_partitions false
├─22767 erl_child_setup 65536
├─22823 inet_gethost 4
├─22824 inet_gethost 4
└─22883 /bin/sh -s rabbit_disk_monitor
Jan 23 17:47:18 m5stack-LLM systemd[1]: Starting RabbitMQ Messaging Server...
Jan 23 17:47:35 m5stack-LLM systemd[1]: Started RabbitMQ Messaging Server.
RabbitMQにはWebベースの管理UIが用意されてるそうだ。デフォルトでは動作していないのかな?
root@m5stack-LLM:~# curl -O http://localhost:15672
curl: Remote file name has no length!
curl: (23) Failed writing received data to disk/application
プラグインの管理コマンドで動作を調べてみる。
root@m5stack-LLM:~# sudo rabbitmq-plugins list
Listing plugins with pattern ".*" ...
Configured: E = explicitly enabled; e = implicitly enabled
| Status: * = running on rabbit@m5stack-LLM
|/
[ ] rabbitmq_amqp1_0 3.9.27
[ ] rabbitmq_auth_backend_cache 3.9.27
[ ] rabbitmq_auth_backend_http 3.9.27
[ ] rabbitmq_auth_backend_ldap 3.9.27
[ ] rabbitmq_auth_backend_oauth2 3.9.27
[ ] rabbitmq_auth_mechanism_ssl 3.9.27
[ ] rabbitmq_consistent_hash_exchange 3.9.27
[ ] rabbitmq_event_exchange 3.9.27
[ ] rabbitmq_federation 3.9.27
[ ] rabbitmq_federation_management 3.9.27
[ ] rabbitmq_jms_topic_exchange 3.9.27
[ ] rabbitmq_management 3.9.27
[ ] rabbitmq_management_agent 3.9.27
[ ] rabbitmq_mqtt 3.9.27
[ ] rabbitmq_peer_discovery_aws 3.9.27
[ ] rabbitmq_peer_discovery_common 3.9.27
[ ] rabbitmq_peer_discovery_consul 3.9.27
[ ] rabbitmq_peer_discovery_etcd 3.9.27
[ ] rabbitmq_peer_discovery_k8s 3.9.27
[ ] rabbitmq_prometheus 3.9.27
[ ] rabbitmq_random_exchange 3.9.27
[ ] rabbitmq_recent_history_exchange 3.9.27
[ ] rabbitmq_sharding 3.9.27
[ ] rabbitmq_shovel 3.9.27
[ ] rabbitmq_shovel_management 3.9.27
[ ] rabbitmq_stomp 3.9.27
[ ] rabbitmq_stream 3.9.27
[ ] rabbitmq_stream_management 3.9.27
[ ] rabbitmq_top 3.9.27
[ ] rabbitmq_tracing 3.9.27
[ ] rabbitmq_trust_store 3.9.27
[ ] rabbitmq_web_dispatch 3.9.27
[ ] rabbitmq_web_mqtt 3.9.27
[ ] rabbitmq_web_mqtt_examples 3.9.27
[ ] rabbitmq_web_stomp 3.9.27
[ ] rabbitmq_web_stomp_examples 3.9.27
有効ではないようなので、有効化する。
root@m5stack-LLM:~# sudo rabbitmq-plugins enable rabbitmq_management
Enabling plugins on node rabbit@m5stack-LLM:
rabbitmq_management
The following plugins have been configured:
rabbitmq_management
rabbitmq_management_agent
rabbitmq_web_dispatch
Applying plugin configuration to rabbit@m5stack-LLM...
The following plugins have been enabled:
rabbitmq_management
rabbitmq_management_agent
rabbitmq_web_dispatch
started 3 plugins.
PC側で「http://m5stack-llm.local:15672/」にアクセスすると画面が開いた。localhost制限はされていないらしい。

デフォルトのログイン情報は以下。
ユーザー名: guest
パスワード: guest
やっぱアクセス制限あるのね...

設定を変更する。
まずは、登録済みのユーザーの確認。
root@m5stack-LLM:~# sudo rabbitmqctl list_users
Listing users ...
user tags
guest [administrator]
特に制限設定はないようだ。「guest [administrator, only_local]」とかになっていると予想していた。
非推奨だけど、ゲストにアクセスを強制許可する設定を書き込む。通常は、管理ユーザーを追加するようだ。
root@m5stack-LLM:~# sudo vi /etc/rabbitmq/rabbitmq-env.conf
loopback_users = []
RabbitMQを再起動する。
root@m5stack-LLM:~# sudo systemctl restart rabbitmq-server
残念、この方法はもう無効になっているようだ。3.7.0で完全に削除されたとのこと。
観念して、新規ユーザーを作る。
root@m5stack-LLM:~# sudo rabbitmqctl add_user kinneko passwd
Adding user "kinneko" ...
Done. Don't forget to grant the user permissions to some virtual hosts! See 'rabbitmqctl help set_permissions' to learn more.
ユーザーに管理者権限を付与する。
root@m5stack-LLM:~# sudo rabbitmqctl set_user_tags kinneko administrator
Setting tags for user "kinneko" to [administrator] ...
ユーザーにすべての仮想ホストへのフルアクセス権を与える。
root@m5stack-LLM:~# sudo rabbitmqctl set_permissions -p / kinneko "." "." ".*"
Setting permissions for user "kinneko" in vhost "/" ...
デフォルトのguestユーザーの削除。
root@m5stack-LLM:~# sudo rabbitmqctl delete_user guest
Deleting user "guest" ...
ユーザーの追加と削除はできている。
root@m5stack-LLM:~# sudo rabbitmqctl list_users
Listing users ...
user tags
kinneko [administrator]
新しく作ったユーザーで管理UIにアクセスしてみる。こんどはうまくいった。

まだ先は長いな...
オリジナル投稿:
LLMモジュールでREMDISを動かす -1-|kinneko|pixivFANBOX
https://kinneko.fanbox.cc/posts/9256984



