You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Background: Just downloaded nsq release 0.3.8 for Darwin to test for a potential project. I am new to the project so I apologize if I've missed something crucial here.
Problem: When starting nsqlookupd, nsqd and nsqadmin, it looks like nsqd stops sending heartbeats to nsqlookupd shortly thereafter.
Steps to recreate:
Download release 0.3.8 (for Darwin) from Github.
Open up three terminal.
In terminal 1, execute ./nsqlookupd.
In terminal 2, start a clean nsqd: rm *.dat && ./nsqd -lookupd-tcp-address localhost:4160. Notice that there is communication happening between the nsqd and nsqlookupd.
In terminal 3, execute ./nsqadmin -lookupd-http-address localhost:4161
In browser, open http://localhost:4171/nodes and make sure that your single nsqd is listed there.
Notice that terminal 2 (log below) sends 4 heartbeats, but then stops sending heartbeats.
After 5-6 minutes, reload http://localhost:4171/nodes and notice there is no nsqd listed there despite the fact that it's running.
Expected: That heartbeats are sent to continuously to nsqlookupd and that nsqd is constrantly listed in nsqadmin GUI.
Discussion:
Suspecting that heartbeats were only sent when there were messages ready for consumtion on nsqd I also sent a few messages to it using to_nsq script. I double checked there was a queue depth in nsqadmin. nsqlookupd logs [nsqlookupd] 2017/03/05 18:49:25.876432 DB: client([::1]:52076) REGISTER category:topic key:testtopic subkey:, but nsqd did not start sending heartbeats and it doesn't show up in nsqlookupd. 😢
I asked a question about this on IRC, but didn't get any answer within my personal timeout ;) Decided to create an issue instead.
It feels like I'm missing something here as this is basic stuff. Please clarify and maybe we can improve documentation/default somehow!
I can't reproduce, but I think this could have something to do with the fact that Go 1.6.2 isn't compatible with macOS Sierra — is that the version you're running? I'm on 10.12.3.
I suggest installing NSQ on macOS with brew instead.
Since I'm not seeing this, if you're interested in debugging further, you could send nsqd a SIGQUIT (CTRL + \) to get a stack trace and see if there are any deadlocks related to lookupd goroutines.
@mreiferson I am on MacOSX Sierra (10.12.3), too. Just double checking, how did you try to recreate this? Using the release downloadable here on Github, or by building your own binary/brew?
That said, I Installed 0.3.8 using brew and heartbeat is continuously being submitted now.
I dumped the stacks and you can find them here: https://gist.github.com/JensRantil/2d97bba40ebd9512049b9a8a693fbb12 I don't expect you to spend time to look at them, but I do note that the lookupLoop function is at least running. I'll leave this for now since it works great when installing from brew.
Background: Just downloaded
nsq
release 0.3.8 for Darwin to test for a potential project. I am new to the project so I apologize if I've missed something crucial here.Problem: When starting
nsqlookupd
,nsqd
andnsqadmin
, it looks likensqd
stops sending heartbeats tonsqlookupd
shortly thereafter.Steps to recreate:
./nsqlookupd
.nsqd
:rm *.dat && ./nsqd -lookupd-tcp-address localhost:4160
. Notice that there is communication happening between thensqd
andnsqlookupd
../nsqadmin -lookupd-http-address localhost:4161
http://localhost:4171/nodes
and make sure that your singlensqd
is listed there.http://localhost:4171/nodes
and notice there is nonsqd
listed there despite the fact that it's running.Expected: That heartbeats are sent to continuously to
nsqlookupd
and thatnsqd
is constrantly listed innsqadmin
GUI.Discussion:
nsqd
I also sent a few messages to it usingto_nsq
script. I double checked there was a queue depth innsqadmin
.nsqlookupd
logs[nsqlookupd] 2017/03/05 18:49:25.876432 DB: client([::1]:52076) REGISTER category:topic key:testtopic subkey:
, butnsqd
did not start sending heartbeats and it doesn't show up innsqlookupd
. 😢Logs:
Terminal 1:
$ ./nsqlookupd [nsqlookupd] 2017/03/05 18:19:11.323092 nsqlookupd v0.3.8 (built w/go1.6.2) [nsqlookupd] 2017/03/05 18:19:11.323495 TCP: listening on [::]:4160 [nsqlookupd] 2017/03/05 18:19:11.323526 HTTP: listening on [::]:4161 [nsqlookupd] 2017/03/05 18:19:16.223427 TCP: new client([::1]:51680) [nsqlookupd] 2017/03/05 18:19:16.223456 CLIENT([::1]:51680): desired protocol magic ' V1' [nsqlookupd] 2017/03/05 18:19:16.223674 CLIENT([::1]:51680): IDENTIFY Address:MacBook-Pro-3.lan TCP:4150 HTTP:4151 Version:0.3.8 [nsqlookupd] 2017/03/05 18:19:16.223711 DB: client([::1]:51680) REGISTER category:client key: subkey: [nsqlookupd] 2017/03/05 18:19:31.223651 CLIENT([::1]:51680): pinged (last ping 14.999954538s) [nsqlookupd] 2017/03/05 18:19:46.223603 CLIENT([::1]:51680): pinged (last ping 14.999967991s) [nsqlookupd] 2017/03/05 18:20:01.223691 CLIENT([::1]:51680): pinged (last ping 15.000067492s) [nsqlookupd] 2017/03/05 18:20:16.223746 CLIENT([::1]:51680): pinged (last ping 15.000070542s) [nsqlookupd] 2017/03/05 18:21:22.327779 200 GET /nodes ([::1]:51707) 91.301µs [nsqlookupd] 2017/03/05 18:23:51.552302 200 GET /nodes ([::1]:51714) 34.067µs [nsqlookupd] 2017/03/05 18:31:56.538593 200 GET /nodes ([::1]:52054) 30.236µs [nsqlookupd] 2017/03/05 18:32:09.292243 CLIENT([::1]:51680): closing [nsqlookupd] 2017/03/05 18:32:09.292265 DB: client([::1]:51680) UNREGISTER category:client key: subkey: [nsqlookupd] 2017/03/05 18:32:09.292272 ERROR: client([::1]:51680) - EOF ^C[nsqlookupd] 2017/03/05 18:33:33.343569 HTTP: closing [::]:4161 [nsqlookupd] 2017/03/05 18:33:33.343627 TCP: closing [::]:4160
Terminal 2:
Terminal 3:
The text was updated successfully, but these errors were encountered: