VeryNginx icon indicating copy to clipboard operation
VeryNginx copied to clipboard

安装一切成功,手动安装了最新的新了 OR,报这个错误。

Open Castleeee opened this issue 4 years ago • 2 comments

everything was installd successfully,but when us nginx -t, it boomd。

nginx: [emerg] unknown directive "balancer_by_lua_file" in /opt/verynginx/verynginx/nginx_conf/in_http_block.conf:3 nginx: configuration file /etc/nginx/nginx.conf test failed

i don't know how to fix it because i was new to lua&nginx. please help me thank you. 求解答

Castleeee avatar Jul 27 '19 03:07 Castleeee

balancer_by_lua* 需要放在upstream context中,在其他位置不能识别,eg: upstream vn_upstream{ server 127.0.0.1; balancer_by_lua_file /opt/verynginx/verynginx/lua_script/on_banlance.lua; keepalive 1024; #Connection pool }

forkone avatar Sep 09 '19 06:09 forkone

everything was installd successfully,but when us nginx -t, it boomd。

nginx: [emerg] unknown directive "balancer_by_lua_file" in /opt/verynginx/verynginx/nginx_conf/in_http_block.conf:3 nginx: configuration file /etc/nginx/nginx.conf test failed

i don't know how to fix it because i was new to lua&nginx. please help me thank you. 求解答

请问下问题是否已解决?

wuxfun avatar Oct 27 '21 03:10 wuxfun