浏览 1.9k
Nginx(版本1.19.3)配置tcp协议做负载均衡,运行正常,但是加上ip_hash后报错。
------------------------------------------------
“ip_hash” directive is not allow...
stream {
upstream dataexch {
ip_hash;
server 192.168.40.191:30011;
server 192.168.40.191:30012;
}
server {
listen 2001;
proxy_pass dataexch;
proxy_timeout 1s;
proxy_responses 1;
}
}
第一次在项目中配置Nginx,求教是什么原因。