-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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 4.12 on Debian, hangs and eat 100% CPU #496
Comments
Not much of an answer I realise, but could you try 1.4.14? |
Is there any already built deb package for it? |
It was all updated apart from for jessie - that is now fixed as well. repo.mosquitto.org. |
(thanks for making me realise jessie wasn't up to date!) |
Hi, 3 days ago I disable websockets listener and it works normal without hangs till today. Thanks for debian release. |
It's still work normally, so I think on 99% it was websocket listener issue |
Same thing here. With websockets activated the mosquitto process sometimes may even not survive for 1 hour. It is not a load dependent issue, production system with 1200 clients and testing environment with 0 clients (and no messages at all) stops processing messages within the same amount of time. There is nothing in the logs at the time of hanging. |
@VeeNee Do you have websockets logging enabled and with a high verbosity? |
We are using "log_type all" which i believe includes websockets and everything else. |
@VeeNee Please also set |
It's possible this bug is related to #490. Would you be able to give the latest changes in the fixes branch a try? |
Enabled websockets_log_level 255, now waiting till process hangs.
Debian Jessie, GCC 4.9.2 |
Here is a patch that should work on Jessie: |
Thanks, succesfully built with this lws-fixes patch and cherry-picked 2 commits from #490. |
That's a shame but it's a good starting point that you noticed it being scanned. |
@ralight |
I am actually getting the same on Centos also, is there a patch available? |
Here is output I have had issues with not being able to get mosquitto built with websockets for over a year, finally came back to try and tackle it today :) Any help with the below would be appreciated :)
|
I can still reproduce the issue with 1.4.14. Running for 1 or 2 hours. Then 1 cpu core starts to max at 100%. |
I also tried to compile mqtt with websocket=no. Same result. |
The versions involved in this issue are now very out of date, so I'm closing it. If this is really still a problem with 2.0.14 then please do reopen the bug and add more details. |
Hi,
I have strange problem with mosqutto on debian, it was on 4.10, update to 4.12 doesn't help.
After several days of normal work it hangs and eat 100% of CPU.
Maybe You can help to investigate reason of it, maybe I can run mosquiito in debug mode?
Mosquitto log has some strange lines with rejected connections like:
1500027624: ACL denying access to client with dangerous client id "paho/4DD5940EF291D60EE2"
1500027634: ACL denying access to client with dangerous client id "paho/4DD5940EF291D60EE2"
1500027644: Socket error on client paho/4DD5940EF291D60EE2, disconnecting.
But as I remember previous logs when it hangs doesn't has this lines.
mosquittolog.txt
Part of strace of existing mosqutto process:
poll([{fd=5, events=POLLIN}, {fd=6, events=POLLIN}, {fd=9, events=POLLIN}], 3, 100) = 1 ([{fd=5, revents=POLLNVAL}]) rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 poll([{fd=8, events=POLLIN}], 1, 0) = 0 (Timeout) rt_sigprocmask(SIG_SETMASK, [INT], [], 8) = 0 poll([{fd=5, events=POLLIN}, {fd=6, events=POLLIN}, {fd=9, events=POLLIN}], 3, 100) = 1 ([{fd=5, revents=POLLNVAL}]) rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 poll([{fd=8, events=POLLIN}], 1, 0) = 0 (Timeout) rt_sigprocmask(SIG_SETMASK, [INT], [], 8) = 0 poll([{fd=5, events=POLLIN}, {fd=6, events=POLLIN}, {fd=9, events=POLLIN}], 3, 100) = 1 ([{fd=5, revents=POLLNVAL}]) rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
Part of ltrace of existing mosquitto process:
13259 libwebsocket_service(0xa8e5d0, 0, 0xa6e010, 2) = 0 13259 clock_gettime(1, 0x7ffd3d7bf340, 0, -1) = 0 13259 clock_gettime(1, 0x7ffd3d7bf240, 0xd3f135, 24) = 0 13259 memset(0xa96460, '\377', 48) = 0xa96460 13259 time(0) = 1500282490 13259 clock_gettime(1, 0x7ffd3d7bf340, 0xa8e1c8, 6) = 0 13259 time(0) = 1500282490 13259 clock_gettime(1, 0x7ffd3d7bf340, 9, 1) = 0 13259 sigprocmask(SIG_UNBLOCK, <1>, <>) = 0 13259 poll(0xa96460, 3, 100, -1) = 1 13259 sigprocmask(SIG_UNBLOCK, <>, nil) = 0 13259 libwebsocket_service(0xa8e5d0, 0, 0xa6e010, 2) = 0 13259 clock_gettime(1, 0x7ffd3d7bf340, 0, -1) = 0 13259 clock_gettime(1, 0x7ffd3d7bf240, 0xd3f135, 24) = 0 13259 memset(0xa96460, '\377', 48) = 0xa96460 13259 time(0) = 1500282490 13259 clock_gettime(1, 0x7ffd3d7bf340, 0xa8e1c8, 6) = 0 13259 time(0) = 1500282490 13259 clock_gettime(1, 0x7ffd3d7bf340, 9, 1) = 0 13259 sigprocmask(SIG_UNBLOCK, <1>, <>) = 0 13259 poll(0xa96460, 3, 100, -1) = 1 13259 sigprocmask(SIG_UNBLOCK, <>, nil) = 0 13259 libwebsocket_service(0xa8e5d0, 0, 0xa6e010, 2) = 0 13259 clock_gettime(1, 0x7ffd3d7bf340, 0, -1) = 0 13259 clock_gettime(1, 0x7ffd3d7bf240, 0xd3f135, 24) = 0 13259 memset(0xa96460, '\377', 48) = 0xa96460 13259 time(0) = 1500282490 13259 clock_gettime(1, 0x7ffd3d7bf340, 0xa8e1c8, 6) = 0 13259 time(0) = 1500282490 13259 clock_gettime(1, 0x7ffd3d7bf340, 9, 1) = 0 13259 sigprocmask(SIG_UNBLOCK, <1>, <>) = 0 13259 poll(0xa96460, 3, 100, -1) = 1 13259 sigprocmask(SIG_UNBLOCK, <>, nil) = 0 13259 libwebsocket_service(0xa8e5d0, 0, 0xa6e010, 2) = 0 13259 clock_gettime(1, 0x7ffd3d7bf340, 0, -1) = 0 13259 clock_gettime(1, 0x7ffd3d7bf240, 0xd3f135, 24) = 0 13259 memset(0xa96460, '\377', 48) = 0xa96460 13259 time(0) = 1500282490 13259 clock_gettime(1, 0x7ffd3d7bf340, 0xa8e1c8, 6) = 0 13259 time(0) = 1500282490 13259 clock_gettime(1, 0x7ffd3d7bf340, 9, 1) = 0 13259 sigprocmask(SIG_UNBLOCK, <1>, <>) = 0 13259 poll(0xa96460, 3, 100, -1) = 1 13259 sigprocmask(SIG_UNBLOCK, <>, nil) = 0 13259 libwebsocket_service(0xa8e5d0, 0, 0xa6e010, 2) = 0 13259 clock_gettime(1, 0x7ffd3d7bf340, 0, -1) = 0 13259 clock_gettime(1, 0x7ffd3d7bf240, 0xd3f135, 24) = 0 13259 memset(0xa96460, '\377', 48) = 0xa96460 13259 time(0) = 1500282490
The text was updated successfully, but these errors were encountered: