Skip to content

upsync_lb ip_hash不生效,寻求解答 #321

@caibird1990

Description

@caibird1990

各位好,
upstream erp-sales {
#server 10.6.125.38:8080 max_fails=3 fail_timeout=10s;
#ip_hash;
server 127.0.0.2:1111 down;
upsync 10.6.124.175:2379/v2/keys/upstreams/erp-sales upsync_timeout=6m upsync_interval=500ms upsync_type=etcd strong_dependency=off;
upsync_lb ip_hash;
upsync_dump_path /data/nginx/consul/conf/upstream.erp-sales;
check interval=3000 rise=2 fall=3 timeout=1000 type=http;
check_http_send "HEAD /glhealthcheck/status HTTP/1.0\r\n\r\n";
check_http_expect_alive http_2xx http_3xx;

在日志中,发现请求还是轮询请求到不同的服务器上
image
有遇到同类问题的同学,麻烦指点一二,谢谢

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions