Open qinxiaogit opened 5 years ago
2019/08/12 14:14:54 [info] 20160#0: 147 client closed connection while waiting for request, client: 192.168.100.38, server: 0.0.0.0:80 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:95: redirect(): ==[Redirect][PASS THROUGH SELECTOR:c11573bd-dc2c-4fee-8ad9-6d9d8fdeb726], client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:85: rewrite(): ==[Rewrite][PASS THROUGH SELECTOR:27238cbe-a8b3-493b-822d-3ebd30fbe429], client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:97: rewrite(): [Rewrite][PASS-SELECTOR:27238cbe-a8b3-493b-822d-3ebd30fbe429] /, client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:105: rewrite(): ==[DynamicUpstream][START SELECTOR:37de6836-11c5-4244-ace8-a5deb06dd48e,NAME:test-负载], client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:116: rewrite(): [DynamicUpstream][PASS-SELECTOR:37de6836-11c5-4244-ace8-a5deb06dd48e] /, client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:33: filter_rules(): ==[DynamicUpstream][rule name:test][rule id:d0b6e6aa-9ed0-4b1f-81ea-e4fb5542b547], client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:21: ngx_set_uri(): [DynamicUpstream][upstream request][http://default_upstream], client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:112: access(): ==[PropertyRateLimiting][PASS THROUGH SELECTOR:ae85effc-699b-4666-be23-c65d27da2bf3], client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:124: access(): [PropertyRateLimiting][PASS-SELECTOR:ae85effc-699b-4666-be23-c65d27da2bf3] /, client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:109: access(): ==[RateLimiting][PASS THROUGH SELECTOR:2db6cdfc-2ba7-4f62-8cfc-6a43dfdb3b82], client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:121: access(): [RateLimiting][PASS-SELECTOR:2db6cdfc-2ba7-4f62-8cfc-6a43dfdb3b82] /, client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:38: access(): [upstream_url] default_upstream, client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:51: access(): [scheme] nil; [hostname] default_upstream, client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [error] 20159#0: 148 lua entry thread aborted: runtime error: /usr/local/orange/orange/plugins/balancer/handler.lua:103: variable "target" not found for writing; maybe it is a built-in variable that is not changeable or you forgot to use "set $target '';" in the config file to define it first stack traceback: coroutine 0: [C]: in function '__newindex' /usr/local/orange/orange/plugins/balancer/handler.lua:103: in function 'access' /usr/local/orange/orange/orange.lua:165: in function 'access' access_by_lua(nginx.conf:112):3: in function <access_by_lua(nginx.conf:112):1>, client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:15:09 [info] 20159#0: 149 client closed connection while waiting for request, client: 192.168.100.38, server: 0.0.0.0:80
提示信息很明显了,nginx 配置文件中没有设置 target这个变量吧
提示信息很明显了,nginx 配置文件中没有设置 target这个变量吧 这个我知道,我已经解决了。
请问下怎么解决的?
2019/08/12 14:14:54 [info] 20160#0: 147 client closed connection while waiting for request, client: 192.168.100.38, server: 0.0.0.0:80 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:95: redirect(): ==[Redirect][PASS THROUGH SELECTOR:c11573bd-dc2c-4fee-8ad9-6d9d8fdeb726], client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:85: rewrite(): ==[Rewrite][PASS THROUGH SELECTOR:27238cbe-a8b3-493b-822d-3ebd30fbe429], client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:97: rewrite(): [Rewrite][PASS-SELECTOR:27238cbe-a8b3-493b-822d-3ebd30fbe429] /, client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:105: rewrite(): ==[DynamicUpstream][START SELECTOR:37de6836-11c5-4244-ace8-a5deb06dd48e,NAME:test-负载], client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:116: rewrite(): [DynamicUpstream][PASS-SELECTOR:37de6836-11c5-4244-ace8-a5deb06dd48e] /, client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:33: filter_rules(): ==[DynamicUpstream][rule name:test][rule id:d0b6e6aa-9ed0-4b1f-81ea-e4fb5542b547], client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:21: ngx_set_uri(): [DynamicUpstream][upstream request][http://default_upstream], client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:112: access(): ==[PropertyRateLimiting][PASS THROUGH SELECTOR:ae85effc-699b-4666-be23-c65d27da2bf3], client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:124: access(): [PropertyRateLimiting][PASS-SELECTOR:ae85effc-699b-4666-be23-c65d27da2bf3] /, client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:109: access(): ==[RateLimiting][PASS THROUGH SELECTOR:2db6cdfc-2ba7-4f62-8cfc-6a43dfdb3b82], client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:121: access(): [RateLimiting][PASS-SELECTOR:2db6cdfc-2ba7-4f62-8cfc-6a43dfdb3b82] /, client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:38: access(): [upstream_url] default_upstream, client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [info] 20159#0: 148 [lua] handler.lua:51: access(): [scheme] nil; [hostname] default_upstream, client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:14:58 [error] 20159#0: 148 lua entry thread aborted: runtime error: /usr/local/orange/orange/plugins/balancer/handler.lua:103: variable "target" not found for writing; maybe it is a built-in variable that is not changeable or you forgot to use "set $target '';" in the config file to define it first stack traceback: coroutine 0: [C]: in function '__newindex' /usr/local/orange/orange/plugins/balancer/handler.lua:103: in function 'access' /usr/local/orange/orange/orange.lua:165: in function 'access' access_by_lua(nginx.conf:112):3: in function <access_by_lua(nginx.conf:112):1>, client: 192.168.100.38, server: , request: "GET / HTTP/1.1", host: "192.168.100.201" 2019/08/12 14:15:09 [info] 20159#0: 149 client closed connection while waiting for request, client: 192.168.100.38, server: 0.0.0.0:80