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

无法获取etcd的数据信息 #38

Open
xiaoxiangs opened this issue Sep 16, 2019 · 1 comment
Open

无法获取etcd的数据信息 #38

xiaoxiangs opened this issue Sep 16, 2019 · 1 comment

Comments

@xiaoxiangs
Copy link

版本:1.12.2(也尝试过1.14.2)
编译方式:
configure --add-module=./nginx-stream-upsync-module --with-stream
配置:
stream {
upstream test {
server 127.0.0.1:8080 down;
upsync 10.120.174.5:2379/v2/keys/test/nginx/upstream2 upsync_timeout=6m upsync_interval=500ms upsync_type=etcd strong_dependency=off;
upsync_dump_path /opt/nginx_upstream/flow.test.yidian-inc.com_stream2.conf;

    include /opt/nginx_upstream/flow.test.yidian-inc.com_stream2.conf;
}


server {
    listen 12345;

    proxy_connect_timeout 1s;
    proxy_timeout 3s;
    proxy_pass test;
}

}

etcd数据测试:
#curl 10.120.174.5:2379/v2/keys/test/nginx/upstream2
{"action":"get","node":{"key":"/test/nginx/upstream2","dir":true,"nodes":[{"key":"/test/nginx/upstream2/10.126.172.17:8080","value":"{"weight":1, "max_fails":2, "fail_timeout":10, "down":0}","modifiedIndex":1110957,"createdIndex":1110957}],"modifiedIndex":1110862,"createdIndex":1110862}}

麻烦帮忙看下哪里有问题?

@xiaokai-wang
Copy link
Owner

没看出什么问题了,你可以debug 模式看看日志.
server 127.0.0.1:8080 down; 应该放到flow.test.yidian-inc.com_stream2.conf 文件里

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

No branches or pull requests

2 participants