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

if auth is disabled the etcdctl doesn't work with --user option #7724

Closed
raoofm opened this issue Apr 12, 2017 · 2 comments
Closed

if auth is disabled the etcdctl doesn't work with --user option #7724

raoofm opened this issue Apr 12, 2017 · 2 comments
Assignees

Comments

@raoofm
Copy link
Contributor

raoofm commented Apr 12, 2017

etcdctl fails. It should still work. If this was done intentionally so that the user is aware that auth is disabled then a warning is sufficient. Else after disabling auth all the scripts needs a change too.

[rm@dev-vm-01 etcd]$ sudo ETCDCTL_API=3 ./etcdctl --endpoints=https://dev-vm-01.example.com:2379 version
etcdctl version: 3.1.5
API version: 3.1

[rm@dev-vm-01 etcd]$ sudo ETCDCTL_API=3 ./etcdctl --endpoints=https://dev-vm-01.example.com:2379,https://dev-vm-02.example.com:2379,https://dev-vm-03.example.com:2379 --cacert=/var/home/rm/cfssl/ca.pem --user=root:password endpoint status
2017-04-12 17:35:23.081712 I | warning: ignoring ServerName for user-provided CA for backwards compatibility is deprecated
Error: etcdserver: authentication is not enabled

@raoofm raoofm changed the title if auth is disabled the etcdctl should doesn't work with --user option if auth is disabled the etcdctl doesn't work with --user option Apr 12, 2017
@heyitsanthony
Copy link
Contributor

/cc @mitake

@mitake
Copy link
Contributor

mitake commented Apr 13, 2017

after disabling auth all the scripts needs a change too

Thanks for your report and the above motivation seems to be reasonable. I'll solve this problem.

@mitake mitake self-assigned this Apr 13, 2017
mitake added a commit to mitake/etcd that referenced this issue Apr 18, 2017
ptabor added a commit to ptabor/etcd that referenced this issue Aug 4, 2020
The test was vary flaky on Travis.

Seems that since (etcd-io#7724) the
client is expected to simply ignore whether server is in AuthDisabled
mode even if the user supplies credentials.

The tests used to:
 * use very large cluster (10 nodes)
 * set very low timeout (1 sec)

Such setup led to frequent deadlineExceed errors or following failures:

=== RUN   TestGetTokenWithoutAuth
{"level":"warn","ts":"2020-08-04T16:50:48.686+0200","caller":"clientv3/retry_interceptor.go:62","msg":"retrying of unary invoker failed","target":"endpoint://client-35573307-1ee5-441b-acc7-d073f0bd7de5/localhost:69820396562031027440","attempt":0,"error":"rpc error: code = Unavailable desc = etcdserver: leader changed"}
    user_test.go:151: other errors:etcdserver: leader changed
--- FAIL: TestGetTokenWithoutAuth (10.91s)
ptabor added a commit to ptabor/etcd that referenced this issue Aug 4, 2020
The test is vary flaky on Travis.

Seems that since (etcd-io#7724) the
client is expected to simply ignore whether server is in AuthDisabled
mode even if the user supplies credentials.

The tests used to:
  * use very large cluster (10 nodes)
  * set very low timeout (1 sec)

Such setup led to frequent deadlineExceed errors or following failures:

    === RUN   TestGetTokenWithoutAuth
    {"level":"warn","ts":"2020-08-04T16:50:48.686+0200","caller":"clientv3/retry_interceptor.go:62","msg":"retrying of unary invoker failed","target":"endpoint://client-35573307-1ee5-441b-acc7-d073f0bd7de5/localhost:69820396562031027440","attempt":0,"error":"rpc error: code = Unavailable desc = etcdserver: leader changed"}
        user_test.go:151: other errors:etcdserver: leader changed
    --- FAIL: TestGetTokenWithoutAuth (10.91s)
ptabor added a commit to ptabor/etcd that referenced this issue Aug 4, 2020
The test is vary flaky on Travis.

Seems that since (etcd-io#7724) the
client is expected to simply ignore whether server is in AuthDisabled
mode even if the user supplies credentials.

The tests used to:
  * use very large cluster (10 nodes)
  * set very low timeout (1 sec)

Such setup led to frequent deadlineExceed errors or following failures:

    === RUN   TestGetTokenWithoutAuth
    {"level":"warn","ts":"2020-08-04T16:50:48.686+0200","caller":"clientv3/retry_interceptor.go:62","msg":"retrying of unary invoker failed","target":"endpoint://client-35573307-1ee5-441b-acc7-d073f0bd7de5/localhost:69820396562031027440","attempt":0,"error":"rpc error: code = Unavailable desc = etcdserver: leader changed"}
        user_test.go:151: other errors:etcdserver: leader changed
    --- FAIL: TestGetTokenWithoutAuth (10.91s)
ptabor added a commit to ptabor/etcd that referenced this issue Aug 4, 2020
The test is vary flaky on Travis.

Seems that since (etcd-io#7724) the
client is expected to simply ignore whether server is in AuthDisabled
mode even if the user supplies credentials.

The tests used to:
  * use very large cluster (10 nodes)
  * set very low timeout (1 sec)

Such setup led to frequent deadlineExceed errors or following failures:

    === RUN   TestGetTokenWithoutAuth
    {"level":"warn","ts":"2020-08-04T16:50:48.686+0200","caller":"clientv3/retry_interceptor.go:62","msg":"retrying of unary invoker failed","target":"endpoint://client-35573307-1ee5-441b-acc7-d073f0bd7de5/localhost:69820396562031027440","attempt":0,"error":"rpc error: code = Unavailable desc = etcdserver: leader changed"}
        user_test.go:151: other errors:etcdserver: leader changed
    --- FAIL: TestGetTokenWithoutAuth (10.91s)
xiang90 pushed a commit that referenced this issue Aug 7, 2020
The test is vary flaky on Travis.

Seems that since (#7724) the
client is expected to simply ignore whether server is in AuthDisabled
mode even if the user supplies credentials.

The tests used to:
  * use very large cluster (10 nodes)
  * set very low timeout (1 sec)

Such setup led to frequent deadlineExceed errors or following failures:

    === RUN   TestGetTokenWithoutAuth
    {"level":"warn","ts":"2020-08-04T16:50:48.686+0200","caller":"clientv3/retry_interceptor.go:62","msg":"retrying of unary invoker failed","target":"endpoint://client-35573307-1ee5-441b-acc7-d073f0bd7de5/localhost:69820396562031027440","attempt":0,"error":"rpc error: code = Unavailable desc = etcdserver: leader changed"}
        user_test.go:151: other errors:etcdserver: leader changed
    --- FAIL: TestGetTokenWithoutAuth (10.91s)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

3 participants