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

start_type lazy didn't reconnect. dump core. #259

Closed
hakofugu41 opened this issue Sep 5, 2016 · 3 comments
Closed

start_type lazy didn't reconnect. dump core. #259

hakofugu41 opened this issue Sep 5, 2016 · 3 comments

Comments

@hakofugu41
Copy link

hakofugu41 commented Sep 5, 2016

Hello,
I am trying to use lazy option, but mosquitto crashed.
Then, dumps core.

ENV:
CentOS 6.7
mosquitto version 1.4.8

Figure:
mosquitto_pub --send message--> mosquitto(A) --bridge--> mosquitto(B)

I did these steps on my PC. (One host only)

1.Execute mosquitto(B)
$ mosquitto -v

2.Execute mosquitto(A).
Connect mosquitto(A) and mosquitto(B).
$ mosquitto -c start_type.conf
(The contents of start_type.conf are below)

3.Interrupt mosquitto(B) with Ctrl+C.

4.Try to reconnect mosquitto(A) and mosquitto(B)
$ mosquitto -v
Because of threshold option, not reconnected.

5.Send message to mosquitto(A)
$ mosquitto_pub -t /topic/A -m test1 -p 1884

6.Resend message to mosquitto(A)
$ mosquitto_pub -t /topic/A -m test2 -p 1884

7.mosquitto(A) carashes. Then, dumps core files.
Logs:
1473063013: Connecting bridge bridge_out (127.0.0.1:1883)
mosquitto: loop.c:451: loop_handle_reads_writes: Assertion `pollfds[context->pollfd_index].fd == context->sock' failed.
Aborted (core dumped)


start_type.conf

for bridge(out)

connection bridge_out
address 127.0.0.1:1883
topic /topic/# out 2
start_type lazy
threshold 2
idle_timeout 10

for mosquitto_pub

listener 1884

@hakofugu41
Copy link
Author

I have tried with mosquitto 1.4.10 and show the same behavior.

ralight added a commit that referenced this issue Sep 20, 2016
@ralight
Copy link
Contributor

ralight commented Sep 20, 2016

I've been able to reproduce this thanks to your instructions. I've pushed a fix to the "fixes" branch which will either end up in 1.4.11 or 1.5.

Thanks very much for reporting it!

@hakofugu41
Copy link
Author

Thanks!!! XD

ralight added a commit that referenced this issue Feb 20, 2017
@lock lock bot locked as resolved and limited conversation to collaborators Aug 8, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants