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

Allow proper use of etcd proxies. #329

Closed

Conversation

Lukasa
Copy link

@Lukasa Lukasa commented Aug 25, 2015

Resolves #319.

This pull request adds a --no-discover flag that applies only when using the etcd backend. This flag prevents confd from discovering the whole cluster, and so ensures that it only uses the proxy.

This change may be incomplete: right now with the change in this form you need to provide the etcd authority in the form http://host:port when using the --no-discover flag. If that's problematic, we can copy go-etcd's Client.createHttpPath method, which can add a scheme to the front of the authority if needed. Thoughts?

@Lukasa
Copy link
Author

Lukasa commented Aug 25, 2015

I've actually just gone ahead and added some code that automatically prepends the scheme.

@bacongobbler
Copy link
Collaborator

I think with etcdctl they call this --no-sync so it might make sense to rename it as such. What do you think?

@Lukasa
Copy link
Author

Lukasa commented Sep 3, 2015

Seems reasonable to me.

@markhowells
Copy link

Fixes #354 for me.

@geku
Copy link

geku commented Jan 26, 2016

+1

@kelseyhightower
Copy link
Owner

This should be fixed with the move to the new etcd client libs. Please feel free to reopen if that is not the case.

@jeromegn
Copy link

This is not resolved. I'm still hitting that issue. Any URL options I need to pass? I don't see any relevant CLI flags. Using 0.11

@HeavyHorst
Copy link
Contributor

The new etcd client lib is included in the 0.12 pre-releases. 0.11 still
uses the old Library. Can you please test this with one of the 0.12
releases ?

Jerome Gravel-Niquet notifications@github.com schrieb am Di., 27. Sep.
2016, 22:57:

This is not resolved. I'm still hitting that issue. Any URL options I need
to pass? I don't see any relevant CLI flags. Using 0.11


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
#329 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/AQFc84Rbce19twL4XdZBJPf1ehGtH2Fyks5quYNFgaJpZM4FxpsV
.

@jeromegn
Copy link

@HeavyHorst oh, you're right. I just tried it and it seems to work, mostly.

The initial lookup works, as well as the subsequent ones when watching. Which is what troubles me given my logs are being spammed with:

2016-09-27T18:09:29-04:00 jgn.local confd[78591]: ERROR client: etcd cluster is unavailable or misconfigured
2016-09-27T18:09:37-04:00 jgn.local confd[78591]: ERROR client: etcd cluster is unavailable or misconfigured
2016-09-27T18:09:45-04:00 jgn.local confd[78591]: ERROR client: etcd cluster is unavailable or misconfigured
2016-09-27T18:09:53-04:00 jgn.local confd[78591]: ERROR client: etcd cluster is unavailable or misconfigured
2016-09-27T18:10:01-04:00 jgn.local confd[78591]: ERROR client: etcd cluster is unavailable or misconfigured
2016-09-27T18:10:09-04:00 jgn.local confd[78591]: ERROR client: etcd cluster is unavailable or misconfigured
2016-09-27T18:10:17-04:00 jgn.local confd[78591]: ERROR client: etcd cluster is unavailable or misconfigured

It works though, which is conflicting with those messages.

It's worth noting I current use a 2 proxy setup, through https, I provide a client-ca-keys argument, a username and a password.

@HeavyHorst
Copy link
Contributor

I noticed that the Error occurs every 8 seconds. The etcd-watcher uses http
long polling to track changes. Is it possible that one of your proxies had
a connection timeout of 8 seconds configured and closes the connection
because of that ?

Jerome Gravel-Niquet notifications@github.com schrieb am Mi., 28. Sep.
2016, 00:23:

@HeavyHorst https://github.com/HeavyHorst oh, you're right. I just
tried it and it seems to work, mostly.

The initial lookup works, as well as the subsequent ones when watching.
Which is what troubles me given my logs are being spammed with:

2016-09-27T18:09:29-04:00 jgn.local confd[78591]: ERROR client: etcd cluster is unavailable or misconfigured
2016-09-27T18:09:37-04:00 jgn.local confd[78591]: ERROR client: etcd cluster is unavailable or misconfigured
2016-09-27T18:09:45-04:00 jgn.local confd[78591]: ERROR client: etcd cluster is unavailable or misconfigured
2016-09-27T18:09:53-04:00 jgn.local confd[78591]: ERROR client: etcd cluster is unavailable or misconfigured
2016-09-27T18:10:01-04:00 jgn.local confd[78591]: ERROR client: etcd cluster is unavailable or misconfigured
2016-09-27T18:10:09-04:00 jgn.local confd[78591]: ERROR client: etcd cluster is unavailable or misconfigured
2016-09-27T18:10:17-04:00 jgn.local confd[78591]: ERROR client: etcd cluster is unavailable or misconfigured

It works though, which is conflicting with those messages.

It's worth noting I current use a 2 proxy setup, through https, I provide
a client-ca-keys argument, a username and a password.


You are receiving this because you were mentioned.

Reply to this email directly, view it on GitHub
#329 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/AQFc80n6zmpoeiib-IxSIrvYI_ZS1tknks5quZdvgaJpZM4FxpsV
.

@jeromegn
Copy link

I believe I'm hitting this issue: etcd-io/etcd#3405

I've looked at the proxies' logs and all I see are those premature closed connections (at the same interval you mentioned):

2016-09-28 11:38:38.350727 I | proxy: client 127.0.0.1:51677 closed request prematurely
2016-09-28 11:38:46.351517 I | proxy: client 127.0.0.1:52204 closed request prematurely
2016-09-28 11:38:54.352242 I | proxy: client 127.0.0.1:52714 closed request prematurely
2016-09-28 11:39:02.353108 I | proxy: client 127.0.0.1:53205 closed request prematurely

Could be an issue with compose.io though (that's where my etcd is.)

@jeromegn
Copy link

Looks like this may be related too: etcd-io/etcd#3894 (which is fixed by: etcd-io/etcd#4254)

:thinkingface:

@HeavyHorst
Copy link
Contributor

@jeromegn i can reproduce the error with a newly created compose.io etcd cluster.
i also tested this with github.com/HeavyHorst/remco, its working fine there.

I think it should be sufficient to bump the etcd client to the latest version.

@caseydavenport caseydavenport deleted the proxy-contact-issue branch January 26, 2018 00:06
@caseydavenport caseydavenport restored the proxy-contact-issue branch January 26, 2018 00:06
@tomdee tomdee deleted the proxy-contact-issue branch June 12, 2018 17:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants