-
Notifications
You must be signed in to change notification settings - Fork 4.4k
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
Agent can't connect to server when server listens on non-default port #764
Comments
I have similar problem with connecting consul-template (v0.7.0) logs: |
Make sure that |
OK, thanks! I thought agent must connect to server' RPC port, 8300. Changing it to 8301 fixed the problem. I suppose that non-default ports configuration is worth to be mentioned in the documentation: firewalled/port forwarding deployments when "datacenter" is not physical but logical are common now. |
@mthenw I get the same error as yours |
I was getting a ton of |
@alkalinecoffee Do you came up with any solution? |
got exactly the same problem..
I traced the log from both side: Consul Log: ==> Found address '11.7.112.163' for interface 'eth0', setting bind option..., Prometheus Log: level=info ts=2018-07-09T10:02:31.045734474Z caller=main.go:222 msg="Starting Prometheus" version="(version=2.3.1, branch=HEAD, revision=188ca45bd85ce843071e768d855722a9d9dabe03)", |
I am facing the same issue, apparently, the "SERVICE_IGNORE" is not working properly. |
@justinzyw prometheus.yml: conul_sd_configs section
Consul logs
After some research, I resolved this issue.
Here is my Solution
|
That solution worked for me. Logs are clean now. Thx! |
Is there a way to specify server RPC address in consul agent config. In my case we are using consul-k8s and don't want to expose hostport. consul agent trying to connect to pods IP:8300 which is not possible. so wanted to use custom :. |
In order to fix [ERROR] agent.server.rpc: unrecognized RPC byte: byte=71 I had to explicitly define services to scrape in the Prometheus config file:
|
Consul 0.4.1.
In agent config:
"start_join": [ "10.8.7.6:9300" ]
In agent's log:
==> Reading remote state failed: read tcp 10.8.7.6:9300: connection reset by peer
In server's log:
[ERR] consul.rpc: unrecognized RPC byte: 9
The text was updated successfully, but these errors were encountered: