You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by GitBox <gi...@apache.org> on 2020/11/09 10:24:54 UTC

[GitHub] [apisix] jxhecong opened a new issue #2670: request help: while etcd auth enable,apisix cannot get etcd settings after restart

jxhecong opened a new issue #2670:
URL: https://github.com/apache/apisix/issues/2670


   ### Issue description
   enable etcd auth, add right user and password in config.yaml, add a right routes, curl the service is OK
   apisix restart, curl the service result 404
   when remove user and password in config.yaml and disable etcd auth, the service is fine again
   
   ### Environment
   
   * apisix version (cmd: `apisix version`): 2.0
   * OS: centos7.6
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [apisix] jxhecong edited a comment on issue #2670: request help: while etcd auth enable,apisix cannot get etcd settings after restart

Posted by GitBox <gi...@apache.org>.
jxhecong edited a comment on issue #2670:
URL: https://github.com/apache/apisix/issues/2670#issuecomment-723935461


   someting strange:
   etcd --user=***:*** get / --prefix
   the command just output /apisix/routes/1 which is configured
   such as
   "
   /apisix/consumers/
   init_dir
   /apisix/global_rules/
   init_dir
   /apisix/node_status/
   init_dir
   /apisix/plugin_metadata/
   init_dir
   /apisix/plugins/
   init_dir
   /apisix/proto/
   init_dir
   ..."
   is not found


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [apisix] jxhecong commented on issue #2670: request help: while etcd auth enable,apisix cannot get etcd settings after restart

Posted by GitBox <gi...@apache.org>.
jxhecong commented on issue #2670:
URL: https://github.com/apache/apisix/issues/2670#issuecomment-724646545


   > need to add a config option "token" in config.yaml for apisix.etcd, used by init_etcd to add "-H 'Authorization: ***'" in curl command
   
   etcd auth token change easy, it's not a good idea to set it in config.yaml.
   this PR get token by request etcd server when apisix start


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [apisix] jxhecong commented on issue #2670: request help: while etcd auth enable,apisix cannot get etcd settings after restart

Posted by GitBox <gi...@apache.org>.
jxhecong commented on issue #2670:
URL: https://github.com/apache/apisix/issues/2670#issuecomment-724443460


   need to add a config option "token" in config.yaml for apisix.etcd, used by init_etcd to add "-H 'Authorization: ***'" in curl command


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [apisix] jxhecong commented on issue #2670: request help: while etcd auth enable,apisix cannot get etcd settings after restart

Posted by GitBox <gi...@apache.org>.
jxhecong commented on issue #2670:
URL: https://github.com/apache/apisix/issues/2670#issuecomment-723982360


   1. reproduce the failure.
   1.1 etcd --user=: delete / --prefix
         etcd --user=: get / --prefix, to make sure nothing left
   1.2 enable etcd auth, add right user and password in config.yaml, apisix start, add a right routes, curl the service is OK
         etcd --user=: get / --prefix, just output the /apisix/routes/ which is configured
   1.3 apisix restart, curl the service result 404
         etcd --user=: get / --prefix, just output the /apisix/routes/ which is configured
   
   2. to avoid the problem
   2.1 disable etcd auth, apisix restart
         etcd get / --prefix, output all KVs that apisix configured
   2.2 then enable etcd auth, it's OK to restart apisix


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [apisix] membphis closed issue #2670: request help: while etcd auth enable,apisix cannot get etcd settings after restart

Posted by GitBox <gi...@apache.org>.
membphis closed issue #2670:
URL: https://github.com/apache/apisix/issues/2670


   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [apisix] jxhecong commented on issue #2670: request help: while etcd auth enable,apisix cannot get etcd settings after restart

Posted by GitBox <gi...@apache.org>.
jxhecong commented on issue #2670:
URL: https://github.com/apache/apisix/issues/2670#issuecomment-723927410


   just "signal process started" in error.log


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [apisix] nic-chen commented on issue #2670: request help: while etcd auth enable,apisix cannot get etcd settings after restart

Posted by GitBox <gi...@apache.org>.
nic-chen commented on issue #2670:
URL: https://github.com/apache/apisix/issues/2670#issuecomment-724330871


   > someting strange:
   > 
   > etcd --user=***:*** get / --prefix
   > 
   > the command just output /apisix/routes/1 which is configured
   > 
   > such as
   > 
   > "
   > 
   > /apisix/consumers/
   > 
   > init_dir
   > 
   > /apisix/global_rules/
   > 
   > init_dir
   > 
   > /apisix/node_status/
   > 
   > init_dir
   > 
   > /apisix/plugin_metadata/
   > 
   > init_dir
   > 
   > /apisix/plugins/
   > 
   > init_dir
   > 
   > /apisix/proto/
   > 
   > init_dir
   > 
   > ..."
   > 
   > is not found
   
   Thanks for feedback,that is why.
   'init_etcd' doesn't support auth yet.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [apisix] spacewander commented on issue #2670: request help: while etcd auth enable,apisix cannot get etcd settings after restart

Posted by GitBox <gi...@apache.org>.
spacewander commented on issue #2670:
URL: https://github.com/apache/apisix/issues/2670#issuecomment-723921367


   Have you seen any error message after apisix restart?


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [apisix] jxhecong commented on issue #2670: request help: while etcd auth enable,apisix cannot get etcd settings after restart

Posted by GitBox <gi...@apache.org>.
jxhecong commented on issue #2670:
URL: https://github.com/apache/apisix/issues/2670#issuecomment-723935461


   someting strange:
   etcd --user=***:*** get / --prefix
   the command's just output /apisix/routes/1 which is configured
   such as
   "
   /apisix/consumers/
   init_dir
   /apisix/global_rules/
   init_dir
   /apisix/node_status/
   init_dir
   /apisix/plugin_metadata/
   init_dir
   /apisix/plugins/
   init_dir
   /apisix/proto/
   init_dir
   ..."
   is not found


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org