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/12/01 13:53:22 UTC
[GitHub] [apisix] jaredhuang opened a new issue #2912: apisix拉取etcd配置报错
jaredhuang opened a new issue #2912:
URL: https://github.com/apache/apisix/issues/2912
etcd版本为: apisix-2.0-0.el7.noarch.rpm
我的etcd版本如下,已经搭载集群,状态如下:
+--------------------+------------------+---------+---------+-----------+------------+-----------+------------+--------------------+--------+
| ENDPOINT | ID | VERSION | DB SIZE | IS LEADER | IS LEARNER | RAFT TERM | RAFT INDEX | RAFT APPLIED INDEX | ERRORS |
+--------------------+------------------+---------+---------+-----------+------------+-----------+------------+--------------------+--------+
| 172.16.17.154:2379 | 97eff9f7767b8795 | 3.4.13 | 20 kB | true | false | 4 | 13 | 13 | |
| 172.16.16.169:2379 | 71a23c46af8167fe | 3.4.13 | 20 kB | false | false | 4 | 13 | 13 | |
| 172.16.20.226:2379 | d8f14140df69d87 | 3.4.13 | 20 kB | false | false | 4 | 13 | 13 | |
+--------------------+------------------+---------+---------+-----------+------------+-----------+------------+--------------------+--------+
报错日志如下:
2020/12/01 21:49:39 [error] 14690#14690: *34880 [lua] config_etcd.lua:428: failed to fetch data from etcd: failed to read etcd dir, etcd key: /apisix/routes, context: ngx.timer
2020/12/01 21:49:39 [error] 14693#14693: *34882 [lua] config_etcd.lua:428: failed to fetch data from etcd: failed to read etcd dir, etcd key: /apisix/consumers, context: ngx.timer
2020/12/01 21:49:39 [error] 14689#14689: *34883 [lua] config_etcd.lua:428: failed to fetch data from etcd: failed to read etcd dir, etcd key: /apisix/upstreams, context: ngx.timer
2020/12/01 21:49:39 [error] 14690#14690: *34885 [lua] config_etcd.lua:428: failed to fetch data from etcd: failed to read etcd dir, etcd key: /apisix/services, context: ngx.timer
2020/12/01 21:49:39 [error] 14690#14690: *34887 [lua] config_etcd.lua:428: failed to fetch data from etcd: failed to read etcd dir, etcd key: /apisix/plugin_metadata, context: ngx.timer
2020/12/01 21:49:39 [error] 14693#14693: *34888 [lua] config_etcd.lua:428: failed to fetch data from etcd: failed to read etcd dir, etcd key: /apisix/plugin_metadata, context: ngx.timer
2020/12/01 21:49:39 [error] 14689#14689: *34889 [lua] config_etcd.lua:428: failed to fetch data from etcd: failed to read etcd dir, etcd key: /apisix/global_rules, context: ngx.timer
2020/12/01 21:49:39 [error] 14690#14690: *34895 [lua] config_etcd.lua:428: failed to fetch data from etcd: failed to read etcd dir, etcd key: /apisix/upstreams, context: ngx.timer
2020/12/01 21:49:39 [error] 14693#14693: *34896 [lua] config_etcd.lua:428: failed to fetch data from etcd: failed to read etcd dir, etcd key: /apisix/proto, context: ngx.timer
2020/12/01 21:49:39 [error] 14689#14689: *34897 [lua] config_etcd.lua:428: failed to fetch data from etcd: failed to read etcd dir, etcd key: /apisix/services, context: ngx.timer
2020/12/01 21:49:40 [error] 14689#14689: *34861 [lua] config_etcd.lua:428: failed to fetch data from etcd: failed to read etcd dir, etcd key: /apisix/routes, context: ngx.timer
我的etcd集群的数据如下:
[![D4Ckiq.jpg](https://s3.ax1x.com/2020/12/01/D4Ckiq.jpg)](https://imgchr.com/i/D4Ckiq)
----------------------------------------------------------------
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] jaredhuang removed a comment on issue #2912: bug: failed to fetch data from etcd
Posted by GitBox <gi...@apache.org>.
jaredhuang removed a comment on issue #2912:
URL: https://github.com/apache/apisix/issues/2912#issuecomment-737123875
yes ,my etcd cluster add this parameter:
enable-grpc-gateway: true
----------------------------------------------------------------
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] jaredhuang commented on issue #2912: bug: failed to fetch data from etcd
Posted by GitBox <gi...@apache.org>.
jaredhuang commented on issue #2912:
URL: https://github.com/apache/apisix/issues/2912#issuecomment-737124818
yes ,my etcd cluster add this parameter:
enable-grpc-gateway: true
apisix work well . thanks guys~
----------------------------------------------------------------
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] gy09535 commented on issue #2912: bug: failed to fetch data from etcd
Posted by GitBox <gi...@apache.org>.
gy09535 commented on issue #2912:
URL: https://github.com/apache/apisix/issues/2912#issuecomment-737089810
> > 我的etcd版本如下,已经搭载集群
>
> how did you set up the etcd cluster? can you provide the steps? We'll make a try to reproduce this issue
I find many issue cause of etcd version 3.4.13
----------------------------------------------------------------
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] jaredhuang commented on issue #2912: bug: failed to fetch data from etcd
Posted by GitBox <gi...@apache.org>.
jaredhuang commented on issue #2912:
URL: https://github.com/apache/apisix/issues/2912#issuecomment-736945929
[root@tx-apisix-01 ~]# apisix init_etcd true
curl http://0.0.0.0:2379/v3/kv/put -X POST -d '{"value":"aW5pdF9kaXI=", "key":"L2FwaXNpeC9yb3V0ZXMv"}' --connect-timeout 30 --max-time 60 --retry 1 2>&1
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 73 100 19 100 54 24050 68354 --:--:-- --:--:-- --:--:-- 54000
404 page not found
curl http://0.0.0.0:2379/v3/kv/put -X POST -d '{"value":"aW5pdF9kaXI=", "key":"L2FwaXNpeC91cHN0cmVhbXMv"}' --connect-timeout 30 --max-time 60 --retry 1 2>&1
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 77 100 19 100 58 25333 77333 --:--:-- --:--:-- --:--:-- 58000
404 page not found
curl http://0.0.0.0:2379/v3/kv/put -X POST -d '{"value":"aW5pdF9kaXI=", "key":"L2FwaXNpeC9zZXJ2aWNlcy8="}' --connect-timeout 30 --max-time 60 --retry 1 2>&1
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 77 100 19 100 58 22326 68155 --:--:-- --:--:-- --:--:-- 58000
404 page not found
curl http://0.0.0.0:2379/v3/kv/put -X POST -d '{"value":"aW5pdF9kaXI=", "key":"L2FwaXNpeC9wbHVnaW5zLw=="}' --connect-timeout 30 --max-time 60 --retry 1 2>&1
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 77 100 19 100 58 28023 85545 --:--:-- --:--:-- --:--:-- 58000
404 page not found
curl http://0.0.0.0:2379/v3/kv/put -X POST -d '{"value":"aW5pdF9kaXI=", "key":"L2FwaXNpeC9jb25zdW1lcnMv"}' --connect-timeout 30 --max-time 60 --retry 1 2>&1
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 77 100 19 100 58 13600 41517 --:--:-- --:--:-- --:--:-- 58000
404 page not found
curl http://0.0.0.0:2379/v3/kv/put -X POST -d '{"value":"aW5pdF9kaXI=", "key":"L2FwaXNpeC9ub2RlX3N0YXR1cy8="}' --connect-timeout 30 --max-time 60 --retry 1 2>&1
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 81 100 19 100 62 24142 78780 --:--:-- --:--:-- --:--:-- 62000
404 page not found
curl http://0.0.0.0:2379/v3/kv/put -X POST -d '{"value":"aW5pdF9kaXI=", "key":"L2FwaXNpeC9zc2wv"}' --connect-timeout 30 --max-time 60 --retry 1 2>&1
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 69 100 19 100 50 26536 69832 --:--:-- --:--:-- --:--:-- 50000
404 page not found
curl http://0.0.0.0:2379/v3/kv/put -X POST -d '{"value":"aW5pdF9kaXI=", "key":"L2FwaXNpeC9nbG9iYWxfcnVsZXMv"}' --connect-timeout 30 --max-time 60 --retry 1 2>&1
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 81 100 19 100 62 32094 102k --:--:-- --:--:-- --:--:-- 62000
404 page not found
curl http://0.0.0.0:2379/v3/kv/put -X POST -d '{"value":"aW5pdF9kaXI=", "key":"L2FwaXNpeC9zdHJlYW1fcm91dGVzLw=="}' --connect-timeout 30 --max-time 60 --retry 1 2>&1
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 85 100 19 100 66 29051 98k --:--:-- --:--:-- --:--:-- 66000
404 page not found
curl http://0.0.0.0:2379/v3/kv/put -X POST -d '{"value":"aW5pdF9kaXI=", "key":"L2FwaXNpeC9wcm90by8="}' --connect-timeout 30 --max-time 60 --retry 1 2>&1
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 73 100 19 100 54 20299 57692 --:--:-- --:--:-- --:--:-- 54000
404 page not found
curl http://0.0.0.0:2379/v3/kv/put -X POST -d '{"value":"aW5pdF9kaXI=", "key":"L2FwaXNpeC9wbHVnaW5fbWV0YWRhdGEv"}' --connect-timeout 30 --max-time 60 --retry 1 2>&1
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 85 100 19 100 66 21541 74829 --:--:-- --:--:-- --:--:-- 66000
404 page 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] tokers commented on issue #2912: bug: failed to fetch data from etcd
Posted by GitBox <gi...@apache.org>.
tokers commented on issue #2912:
URL: https://github.com/apache/apisix/issues/2912#issuecomment-737097372
@jaredhuang This is due to your etcd cluster doesn't enable the gRPC gateway. This is as same as https://github.com/apache/apisix/issues/2695.
The switch for gRPC gateway is obscure, it's not recorded explicitly, this feature is enabled by default if you just use command line options to bootstrap etcd, however, if you are using configuration file, please add the `enable-grpc-gateway: true` explicitly, it's disabled by default in configuration file.
We already added this situation in doc: https://github.com/apache/apisix/blob/master/doc/install-dependencies.md. Maybe we need to note it more detailed. @membphis
----------------------------------------------------------------
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] jaredhuang commented on issue #2912: bug: failed to fetch data from etcd
Posted by GitBox <gi...@apache.org>.
jaredhuang commented on issue #2912:
URL: https://github.com/apache/apisix/issues/2912#issuecomment-737024153
[root@tx-apisix-01 ~]# etcd --version
etcd Version: 3.4.13
Git SHA: ae9734ed2
Go Version: go1.12.17
Go OS/Arch: linux/amd64
[root@tx-apisix-01 ~]# cat /etc/redhat-release
CentOS Linux release 7.8.2003 (Core)
----------------------------------------------------------------
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 #2912: apisix拉取etcd配置报错
Posted by GitBox <gi...@apache.org>.
nic-chen commented on issue #2912:
URL: https://github.com/apache/apisix/issues/2912#issuecomment-736604666
please run cli:
```sh
apisix init_etcd true
```
and submit the output here.
thanks.
----------------------------------------------------------------
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 commented on issue #2912: bug: failed to fetch data from etcd
Posted by GitBox <gi...@apache.org>.
membphis commented on issue #2912:
URL: https://github.com/apache/apisix/issues/2912#issuecomment-737099641
welcome to push it to FAQ @tokers
and many thx for your nice guide
----------------------------------------------------------------
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 commented on issue #2912: bug: failed to fetch data from etcd
Posted by GitBox <gi...@apache.org>.
membphis commented on issue #2912:
URL: https://github.com/apache/apisix/issues/2912#issuecomment-736949595
> etcd版本为: apisix-2.0-0.el7.noarch.rpm
this is wrong. please provide your `etcd` version. @jaredhuang
```shell
$ etcd --version
etcd Version: 3.4.13
Git SHA: ae9734ed2
Go Version: go1.12.17
Go OS/Arch: linux/amd64
----------------------------------------------------------------
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] jaredhuang commented on issue #2912: bug: failed to fetch data from etcd
Posted by GitBox <gi...@apache.org>.
jaredhuang commented on issue #2912:
URL: https://github.com/apache/apisix/issues/2912#issuecomment-737123875
yes ,my etcd cluster add this parameter:
enable-grpc-gateway: true
----------------------------------------------------------------
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 closed issue #2912: bug: failed to fetch data from etcd
Posted by GitBox <gi...@apache.org>.
spacewander closed issue #2912:
URL: https://github.com/apache/apisix/issues/2912
----------------------------------------------------------------
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 commented on issue #2912: bug: failed to fetch data from etcd
Posted by GitBox <gi...@apache.org>.
membphis commented on issue #2912:
URL: https://github.com/apache/apisix/issues/2912#issuecomment-737083346
> 我的etcd版本如下,已经搭载集群
how did you set up the etcd cluster? can you provide the steps? We'll make a try to reproduce this issue
----------------------------------------------------------------
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