https://netmaker.org logo
Title
b

brash-jewelry-30656

01/20/2023, 10:54 AM
hey all ..figured out issue seems to be with mosquitto not working correctly
b

bored-island-21407

01/20/2023, 10:57 AM
that error usually occurs when ports is question are already taken. Is something else using those ports (1883/8883).. do you have a copy of mosquitto running as a service or in some other container
b

brash-jewelry-30656

01/20/2023, 10:57 AM
nope
fresh install
b

bored-island-21407

01/20/2023, 10:58 AM
output of netstat -ntlp | grep 883
b

brash-jewelry-30656

01/20/2023, 10:58 AM
nroot@localhost:~# netstat -lntp Active Internet connections (only servers) Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name tcp 0 0 127.0.0.1:37899 0.0.0.0:* LISTEN 1625/containerd tcp 0 0 127.0.0.54:53 0.0.0.0:* LISTEN 418/systemd-resolve tcp 0 0 127.0.0.53:53 0.0.0.0:* LISTEN 418/systemd-resolve tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 1/init
b

bored-island-21407

01/20/2023, 11:02 AM
what does your mosquitto.conf look like
b

brash-jewelry-30656

01/20/2023, 11:06 AM
default from the netmaker-vpn.sh frol @jolly-london-20127 script
btw i think i got it going
let me show you what i did
maybe you can tell me if its alright
per_listener_settings false port 1883 protocol mqtt port 8883 protocol mqtt allow_anonymous false listener 1883 protocol websockets listener 8883 protocol websockets allow_anonymous false plugin /usr/lib/mosquitto_dynamic_security.so plugin_opt_config_file /mosquitto/data/dynamic-security.json
b

bored-island-21407

01/20/2023, 11:08 AM
interesting
b

brash-jewelry-30656

01/20/2023, 11:09 AM
does it work for you without these changes ?
i am on ubuntu 22.10
b

bored-island-21407

01/20/2023, 11:10 AM
yes... I have our dev server running with
per_listener_settings true

listener 8883
protocol websockets
allow_anonymous true

listener 1883
protocol websockets
allow_anonymous false

plugin /usr/lib/mosquitto_dynamic_security.so
plugin_opt_config_file /mosquitto/data/dynamic-security.json
mosuitto image running mq: container_name: mq image: eclipse-mosquitto:2.0.11-openssl
it is setup for testing so I would not set allow_anonymous true in production
b

brash-jewelry-30656

01/20/2023, 11:13 AM
er_listener_settings false listener 8883 protocol websockets allow_anonymous false listener 1883 protocol websockets allow_anonymous false plugin /usr/lib/mosquitto_dynamic_security.so plugin_opt_config_file /mosquitto/data/dynamic-security.json
this is what script pulls
b

bored-island-21407

01/20/2023, 11:13 AM
that should just work (tm)
b

brash-jewelry-30656

01/20/2023, 11:14 AM
yep doesnt for me till i googled /posted here/ and made those changes
ohh well atleasrt mq is booting now
thanx
btw docker-compose that the script pulls has mosquito:2.0.15-openssl an you have 2.0.11-openssl
maybe something there ?
b

bored-island-21407

01/20/2023, 12:10 PM
no, I have another test server running with 2.0.15-openssl and it works fine
b

brash-jewelry-30656

01/20/2023, 12:22 PM
still not working 😦
netmaker | [netmaker] Fatal: Admin: could not connect to broker, token timeout, exiting ...