Skip to content
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 service changes status from active (running) to active (exited) after connect with faulty credentials #733

Open
chessweb01 opened this issue Mar 19, 2018 · 4 comments

Comments

@chessweb01
Copy link

chessweb01 commented Mar 19, 2018

I'm running mosquitto 1.4.14 as a service on Ubuntu 16.04 with websocket support.

When I connect with the HiveMQ websocket client (https://www.hivemq.com/demos/websocket-client/) using the correct username/password credentials everything is fine. I can connect/disconnect as often as I like.

When I try to connect using faulty credentials (e.g. a misspelled username or password) I get an error message that the socket is closed which is also ok.

However, even after correcting the credentials I can no longer connect. The error message stays the same.

The reason is this: Just trying to connect with wrong credentials causes the mosquitto service to change status from active (running) to active (exited). Is that a bug and if not, how can I deal with it?

@toast-uz
Copy link
Contributor

Could you show your mosquitto.log?

@chessweb01
Copy link
Author

chessweb01 commented Mar 20, 2018

When I repeat the above procedure, i.e.

  1. successfully connect with correct credentials
  2. disconnect
  3. failed connect with faulty credentials
  4. repeated tries to connect with correct credentials (always failing)

there is nothing added to the log file after step 2.

By the way, the change in service status from active (running) to active (exited) happens on the first try in step 4 and not on step 3 as the original post and the title suggests.

@toast-uz
Copy link
Contributor

Could you add followings at your mosquitto.conf and reproduce the issue in order to get more useful logs?

log_type all
websockets_log_level 255

@chessweb01
Copy link
Author

chessweb01 commented Mar 21, 2018

The attached file contains the complete logs from restarting the broker through steps 1 to 4 with one unsuccessful try to connect with correct credentials.

mosquitto.log

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants