我使用 vernemq 作为 mqtt 服务器,发现 vernemq 经常卡住并且无法创建新连接。我无法发布新主题。在我重新安装 vernemq 后,它会暂时正常工作。但是几个小时或几天它会再次卡住。
我发现当 vernemq 卡住时,输入命令vmq-admin retain show
会失败。
以下是错误信息:
root@ip-172-31-25-95:/home/ubuntu# vmq-admin retain show
RPC to 'VerneMQ@172.31.25.95' failed: {'EXIT',
{badarg,
[{re,replace,
[[[123,34,101,108,100,101,114,69,
109,97,105,108,34,58,34,110,111,
115,53,53,54,54,49,56,51,64,121,
97,104,111,111,46,99,111,109,46,
116,119,34,44,34,97,108,101,114,
116,84,121,112,101,34,58,34,97,
108,101,114,116,95,104,101,108,
112,34,44,34,116,105,109,101,34,
58,34,48,52,58,53,54,32,80,77,34,
44,34,97,100,100,114,101,115,115,
34,58,34,56,50,48,21488,28771,
39640,38596,24066,23713,23665,
21312,23713,23665,36335,49,55,49,
34399,21608,22285,92,110,40,32,
20301,32622,26356,26032,58,32,48,
52,58,51,55,32,80,77,41,34,44,34,
108,97,116,105,116,117,100,101,
34,58,50,50,46,55,57,49,49,49,56,
55,44,34,108,111,110,103,105,116,
117,100,101,34,58,49,50,48,46,50,
57,53,57,56,50,54,44,34,100,101,
118,105,99,101,73,100,34,58,34,
50,56,51,49,98,97,56,52,45,97,54,
53,100,45,52,56,98,56,45,56,48,
101,56,45,50,100,101,101,98,100,
55,57,102,56,54,98,34,125]],
"\e\\[[^m]+m",[],
[global,{return,list}]],
[{file,"re.erl"},{line,398}]},
{stdout_formatter_utils,
displayed_length,1,
[{file,
"/opt/vernemq/_build/default/lib/stdout_formatter/src/stdout_formatter_utils.erl"},
{line,157}]},
{stdout_formatter_utils,
compute_text_block_size,3,
[{file,
"/opt/vernemq/_build/default/lib/stdout_formatter/src/stdout_formatter_utils.erl"},
{line,147}]},
{stdout_formatter_paragraph,
apply_format_string,1,
[{file,
"/opt/vernemq/_build/default/lib/stdout_formatter/src/stdout_formatter_paragraph.erl"},
{line,209}]},
{stdout_formatter_paragraph,
do_format,1,
[{file,
"/opt/vernemq/_build/default/lib/stdout_formatter/src/stdout_formatter_paragraph.erl"},
{line,174}]},
{stdout_formatter_table,format_cell,
1,
[{file,
"/opt/vernemq/_build/default/lib/stdout_formatter/src/stdout_formatter_table.erl"},
{line,248}]},
{stdout_formatter_table,
'-normalize_row_and_cells/2-lc$^0/1-0-',
2,
[{file,
"/opt/vernemq/_build/default/lib/stdout_formatter/src/stdout_formatter_table.erl"},
{line,219}]},
{stdout_formatter_table,
normalize_row_and_cells,2,
[{file,
"/opt/vernemq/_build/default/lib/stdout_formatter/src/stdout_formatter_table.erl"},
{line,219}]}]}}
这是我的 mqtt 配置:
const mqttConnOpts = {
port: serverPortMqtt,
clientId: clientId_1,
username: user,
password: passwd,
retain :true,
clean: true
}
vernemq 版本:vernemq-1.10.3.bionic.x86_64.deb
操作系统版本:
root@ip-172-31-25-95:/home/ubuntu# cat /etc/os-release
NAME="Ubuntu"
VERSION="18.04.5 LTS (Bionic Beaver)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 18.04.5 LTS"
VERSION_ID="18.04"
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
VERSION_CODENAME=bionic
UBUNTU_CODENAME=bionic
有谁知道发生了什么?有什么建议吗?谢谢