我按照这个网站安装 RabbitMQ https://attacomsian.com/blog/install-rabbitmq-macos-ubuntu
在安装 RabbitMq 的第 5 步,当我运行命令时出现此错误
rabbitmq-server.service - RabbitMQ Messaging Server
Loaded: loaded (/lib/systemd/system/rabbitmq-server.service; enabled; vendor preset: enabled)
Active: activating (auto-restart) (Result: exit-code) since Fri 2021-08-20 10:11:27 IST; 5ms ago
Process: 361473 ExecStart=/usr/sbin/rabbitmq-server (code=exited, status=1/FAILURE)
Main PID: 361473 (code=exited, status=1/FAILURE)
dpkg: error processing package rabbitmq-server (--configure):
installed rabbitmq-server package post-installation script subprocess returned error exit status 1
Processing triggers for man-db (2.9.1-1) ...
Processing triggers for systemd (245.4-4ubuntu3.11) ...
Errors were encountered while processing:
rabbitmq-server
E: Sub-process /usr/bin/dpkg returned an error code (1)
当我运行 sudo apt update 时,显示此错误
E: The repository 'http://www.rabbitmq.com/debian testing 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.
请关注官方文档: https ://www.rabbitmq.com/install-debian.html#apt-quick-start-packagecloud
使用一个简单的脚本,你可以很容易地在 ubuntu 上安装 rabbitmq。
例如:
和 ..
发生这种情况是因为文件中的环境变量重新加载
/var/lib/dpkg/info/rabbitmq-server.postinst
,该行:
您可以将其注释掉并执行以下操作:
apt install --fix-broken -y