-
Notifications
You must be signed in to change notification settings - Fork 134
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
"Unknown Protocol" error in client #68
Comments
First try upgrading the gnatsd to the current version of 0.5.2 and see if On Tue, Jun 17, 2014 at 6:17 AM, JimmyMa notifications@github.com wrote:
|
The same problem happens with 0.5.2, see below error log: Our gnatsd is in clustered mode with 2 nodes. Please let me know if you need more info. Thanks. |
Can you send me the conf file for the 2 gnatsd servers? Thanks. On Tue, Jun 17, 2014 at 7:45 AM, JimmyMa notifications@github.com wrote:
|
Here are the conf file, ip of 0.nats.default.stage0.microbosh is xx.xx.xx.197 GNATSD 1: net: "xx.xx.xx.197" pid_file: "/var/vcap/sys/run/nats/nats.pid" log_file: "/var/vcap/sys/log/nats/nats.log" authorization { cluster { authorization { routes = [
] GNATSD 2: net: "xx.xx.xx.19" pid_file: "/var/vcap/sys/run/nats/nats.pid" log_file: "/var/vcap/sys/log/nats/nats.log" authorization { cluster { authorization { routes = [
] |
In the routes section you should only have one route to the other gnatsd On Tue, Jun 17, 2014 at 8:40 AM, JimmyMa notifications@github.com wrote:
|
Hi Derek, So the wrong configuration about routes caused the "Unknown Protocol" error in nats client? BTW, the "Unknown Protocol" error not happens always, it only happens in 2-3 of our cloudcontrollers, and 0 - 5 times each day. |
Unclear, just trying to eliminate things. Is it possible to have a nats On Tue, Jun 17, 2014 at 8:59 AM, JimmyMa notifications@github.com wrote:
|
Hi Derek, Only 4222 is configured in the nats client, so I don't think it could connect on 4223 accidentally. I think the root cause is the intermittent network issue in our environment. nats client has "re-connect" capability, and I suspect the "Unknown Protocol" error happens after the "re-connect". Thanks. |
What version of the nats client are you running?
|
According to the below log, the nats client version is 0.5.0.beta.12. |
Thanks, I will try to dig in a bit deeper on the initial description. On Tue, Jun 17, 2014 at 9:04 PM, JimmyMa notifications@github.com wrote:
|
Hi Derek, One more thing I want to mention is that all messed messages contain "INFO" message, hope this could give you more clues. Thanks. |
Ok thanks. Why is connection being dropped?
|
Hi Derek, We suspect our network is not stable, we are investigating/confirming the network instability issue now ... |
You should be able to close this issue now with the latest changes merged. |
Still trying to get some flaky tests passing reliably, will release to On Fri, Jun 27, 2014 at 4:27 AM, Michael Fraenkel notifications@github.com
|
From what I can tell, the connections dropped are always preceeded by a
|
ok I pushed 0.5.0-beta.14 to rubygems. Thanks again for the PR. |
In our CloudFoundry deployment, the CloudController (the NATS client) is getting below error intermittently when the CloudController receives the "dea.advertise" message from NATS (gnatsd) server
{"id":"10-7ee2570336fe4839974e49ee412ccdcb","stacks":["lucid64"],"available_memory":6336,"available_disk":441760,"app_id_to_count":{"2beae3d0-238c-4ec6-a191-890c32a12554":1,"8fbd89d3-d26c-47b2-94de-9b774bb9687f":1,"a432a6b2-c60a-4801-ba28-cf52811be799":1,"7a98cdb9-630d-4a21-b2b9-8c2012eacc43":1,"3736f818-a39b-4e18-a0a0-afe7f748bd2a":1,"dcf171b3-c13c-4ed9-9INFO {"server_id":"5093c491bc3d437e75408f144dd3643f","version":"0.5.0","host":"xx.xx.xx.xx","port":4222,"auth_required":true,"ssl_required":false,"max_payload":1048576}
The "INFO" message gets messed with the "dea.advertise" message.
Now I'm guessing below is the scenario which has the above problem:
{"id":"10-7ee2570336fe4839974e49ee412ccdcb","stacks":["lucid64"],"available_memory":6336,"available_disk":441760,"app_id_to_count":{"2beae3d0-238c-4ec6-a191-890c32a12554":1,"8fbd89d3-d26c-47b2-94de-9b774bb9687f":1,"a432a6b2-c60a-4801-ba28-cf52811be799":1,"7a98cdb9-630d-4a21-b2b9-8c2012eacc43":1,"3736f818-a39b-4e18-a0a0-afe7f748bd2a":1}}
{"id":"10-7ee2570336fe4839974e49ee412ccdcb","stacks":["lucid64"],"available_memory":6336,"available_disk":441760,"app_id_to_count":{"2beae3d0-238c-4ec6-a191-890c32a12554":1,
INFO {"server_id":"5093c491bc3d437e75408f144dd3643f","version":"0.5.0","host":"xx.xx.xx.xx","port":4222,"auth_required":true,"ssl_required":false,"max_payload":1048576}
{"id":"10-7ee2570336fe4839974e49ee412ccdcb","stacks":["lucid64"],"available_memory":6336,"available_disk":441760,"app_id_to_count":{"2beae3d0-238c-4ec6-a191-890c32a12554":1,INFO {"server_id":"5093c491bc3d437e75408f144dd3643f","version":"0.5.0","host":"xx.xx.xx.xx","port":4222,"auth_required":true,"ssl_required":false,"max_payload":1048576}
Maybe the @buf needs to be clean when the client do the reconnection: https://github.com/derekcollison/nats/blob/v0.5.0.beta.12/lib/nats/client.rb#L720
The text was updated successfully, but these errors were encountered: