Blue Iris MQTT Disconnect error 138

Post Reply
pwm
Posts: 2
Joined: Fri May 22, 2020 7:34 pm

Blue Iris MQTT Disconnect error 138

Post by pwm »

Hello,
I am trying to setup MQTT with Blue Iris but I am running into some issues. I have set the MQTT broker IP and port and ran the Test in the MQTT configuration. It reports that it ran successfully but a few seconds later there is a disconnect error:

Code: Select all

Initialized
Connecting
Connected OK
Subscribed OK
Publishing test message
Published OK
Disconnect error 138
Shutdown
I don't see any published topics in Mosquitto broker log from Blue Iris so I don't know what the test is actually doing. I have lots of other MQTT traffic going through that broker so I think I must not have Blue Iris set up correctly.
rhatguy
Posts: 2
Joined: Fri Aug 28, 2020 8:54 pm

Re: Blue Iris MQTT Disconnect error 138

Post by rhatguy »

Were you able to sort this out. I'm using an MQTT broker provided through HomeAssistant (Hass.io). I to have other things running through the broker, so I think its working fine. Curious.
rhatguy
Posts: 2
Joined: Fri Aug 28, 2020 8:54 pm

Re: Blue Iris MQTT Disconnect error 138

Post by rhatguy »

As soon as I posted this I remembered that I needed to add the new user to my accesscontrollist file. In hassio that is located at /share/mosquitto/accesscontrollist. I added the following

user blueiris
topic readwrite #
ivamar
Posts: 11
Joined: Mon Jun 21, 2021 1:22 pm

Re: Blue Iris MQTT Disconnect error 138

Post by ivamar »

pwm wrote: Fri May 22, 2020 9:03 pm Hello,
I am trying to setup MQTT with Blue Iris but I am running into some issues. I have set the MQTT broker IP and port and ran the Test in the MQTT configuration. It reports that it ran successfully but a few seconds later there is a disconnect error:

Code: Select all

Initialized
Connecting
Connected OK
Subscribed OK
Publishing test message
Published OK
Disconnect error 138
Shutdown
I don't see any published topics in Mosquitto broker log from Blue Iris so I don't know what the test is actually doing. I have lots of other MQTT traffic going through that broker so I think I must not have Blue Iris set up correctly.
hi, i have excat same error/ output . can you share your solution. thank you.
atreyu
Posts: 56
Joined: Fri Nov 27, 2020 7:22 pm

Re: Blue Iris MQTT Disconnect error 138

Post by atreyu »

For use with Home Assistant, ensure you have a User setup in HA, then configure BI at Settings->Digital IO and IoT->MQTT->Configure. It's good practice to make a new user for each connection. In my case I made a user in HA of mqtt_bi.

Then configure your various MQTT alerts as desired on each camera. You can include additional information in the payload. I put &MEMO in the payload field of the ai alert to do things in HA with that information. But I would guess any listed in the help document under "Timecode and other Macros" would work.

You can also monitor mqtt messages coming in to HA at Configuration->Integrations->Mosquitto Broker->Configure->Listen to a topic. For reasons, I have standard triggers come in on topic bimotion/{camera name} and AI confirmed triggers come in on topic aimotion/triggers/{camera name}. To listen for aimotion messages I listen for "aimotion/#". # is a wildcard in this case.

You can listen for all messages with simply '#', but with all of the BI motion, shellies, and wireless stuff on rtl_433, it's a noisy stream.
Post Reply