New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Mosquitto 1.5.7: Socket error on client 'xxx', disconnecting. #1177
Comments
Please close this issue. We found the root cause of the problem. We have 2 identical processes which are started from rc.local without any delay. It seems mosquitto generates a connection ID based on system time. So sometimes it's possible to get 2 identical "unique ID" for connection for different processes. We just add 1sec delay between these processes starting and problem goes away. Hope it helps to someone else. |
Thanks for reporting this, I'm sure it's a niggling problem for some. This is actually in the client library, I've now used a finer resolution timer for the random client id generation there so this should be less likely to come up. Future versions of the library won't be generating the client ids themselves. |
Hello, I am facing the same issue but I fail to figure out the cause, can you please help me?
This message repeats to eternity. |
The |
I am terribly sorry, we assumed users and passwords were right - Indeed, there was an error in a password. Thanks for your time to reply. |
Perhaps it would be more helpful to print human readable return code messages rather than numeric codes alone, e.g., "not authorised" instead of "5"? I realize the return codes are documented in the MQTT specification, but here it's not quite obvious that the 2nd value in the parenthesis refers to the reason code, and even if were obvious, unless one has all the codes memorized, it still requires a lookup either in the source code or the documentation to find out the meaning of the code. |
can you please provide me with steps to solve this problem? |
How did you do this? |
Can someone explain how to do this? |
It looks like the same symptoms as described in #875, #872.
Reconnections repeat forever. This happens only if mosquitto and client are started from
rc.local
. If after system started up and the client is killed and started again manually from root session this problem is not repeated.I get this issue on mosquitto 1.5.4 and 1.5.7 under linux 2.6.32
The text was updated successfully, but these errors were encountered: