MQTT Port ( 1883 ) is always closed - Printable Version +- Logic Machine Forum (https://forum.logicmachine.net) +-- Forum: LogicMachine eco-system (https://forum.logicmachine.net/forumdisplay.php?fid=1) +--- Forum: Gateway (https://forum.logicmachine.net/forumdisplay.php?fid=10) +--- Thread: MQTT Port ( 1883 ) is always closed (/showthread.php?tid=3883) |
MQTT Port ( 1883 ) is always closed - savaskorkmaz - 18.02.2022 Hi, We have 2 Logic Machine. Both of them same firmware. Same project. Same MQTT scripts. Same MQTT settings ( without encryption and anonymous connection ). One of them 192.168.1.80 other 192.168.1.81 ip address. I can communicate via MQTT Explorer with 81 address. But i cannot communicate with 80 address. I scan with advanced port scanner. LM with IP Add 81 has http and 1883 port those are open. LM with IP Add 80 has only http port. 1883 is not open. I disabled and enabled and save everytime Enable MQTT broker without encryption setting. I unistalled and installed MQTT Broker App. But everytime 1883 port looks closed in 192.168.1.80 LM How can i open 1883 port , what can i do ? RE: MQTT Port ( 1883 ) is always closed - Daniel - 18.02.2022 MQTT with encryption use 8883 port RE: MQTT Port ( 1883 ) is always closed - savaskorkmaz - 19.02.2022 8883 and encrypton is not working also. 8883 is closed. 1883 and 8883 is both close. I cannot open anyhow RE: MQTT Port ( 1883 ) is always closed - hummelsystemhaus - 01.07.2022 Hey guys, what's new here, we also use controllers where port 8883 doesn't work to the outside. How can this be resolved? RE: MQTT Port ( 1883 ) is always closed - admin - 01.07.2022 Run this script and post what you get in logs: Code: res = io.readproc('netstat -pln | grep mosquitto') RE: MQTT Port ( 1883 ) is always closed - cedricdw - 01.07.2022 I think I might experience the same issue here. I was using 2 LM5's with an external MQTT broker, using the client scripts that circulate in this forum. This works just fine. Now, I wanted to use one of the devices as a broker. So I've installed the broker app and the config page appears do do what it's supposed to, but the broker is actually never started. The "mosquitto -d -c /tmp/mosquitto.conf" command is never executed. I tried just about everything, including rebooting, factory resetting, updating to the latest firmware, re-injecting the firmware and so on. I even tried to use the broker on the second LM5, and the results were identical: The broker isn't started, no ports are opened. These devices both run the 20211215 firmware, which is the latest if I'm not mistaking. The system log on both devices gives me a hint of what's wrong: "LogicMachine user.info sysinit: chown: unknown user mosquitto". Now for the kicker: I tried it on a third device, exactly the same firmware and type of device... and that one actually does work. The only meaningful difference I can think of, is that this device never ran the MQTT client scripts. I checked all of the installed package versions between the devices, and there is no difference whatsoever. I would really appreciate your help on this. Thanks in Advance! Greets, Cedric Just to be complete, even though the results are as expected, the output of the suggested commands: netstat output: * string: mosquitto.conf: * string: allow_anonymous true password_file /tmp/mosquitto.users sys_interval 0 user mosquitto listener 1883 listener 8883 certfile /tmp/mosquitto.crt keyfile /tmp/mosquitto.key skip_ca true RE: MQTT Port ( 1883 ) is always closed - admin - 04.07.2022 Install these updated packages (System config > System > Packages > Add (+) button) and see if they work for you: https://dl.openrb.com/pkg/libmosquitto_2.0.14-2_imx6.ipk https://dl.openrb.com/pkg/mosquitto_2.0.14-2_imx6.ipk RE: MQTT Port ( 1883 ) is always closed - hummelsystemhaus - 06.07.2022 (01.07.2022, 10:57).admin Wrote: Run this script and post what you get in logs: There is no difference if port 8883 is opened or closed. I checked with telnet ... 8883 Code: check_MQTT 06.07.2022 09:02:01 Installation of the packages mosquitto_2.0.14-2_imx6.ipk and libmosquitto_2.0.14-2_imx6.ipk is not successfull. Checked with lm5m3ex-20180828.img RE: MQTT Port ( 1883 ) is always closed - admin - 06.07.2022 These packages are for 2021.12 firmware. It might not work on older firmwares. RE: MQTT Port ( 1883 ) is always closed - cedricdw - 08.07.2022 (04.07.2022, 07:51)admin Wrote: Install these updated packages (System config > System > Packages > Add (+) button) and see if they work for you: This did the trick for me, MQTT broker seems to be running fine now. I also tested multiple clients including the internal LM scripts, this works. Thanks a lot, you made my day |