Welcome! Log In Create A New Profile

Advanced

[error] 8148#5264: *17 WSARecv() failed (10054: An existing connection was forcibly closed by the remote host) while reading response header from upstream

Posted by rahmadh 
Hello all,

OS: Windows 10 Pro. 64 bit.

I was learning laravel and now I'm trying to use laravel valet.
When first run, it's work. But today can't be used with a message :

2021/11/04 07:55:39 [error] 8148#5264: *17 WSARecv() failed (10054: An existing connection was forcibly closed by the remote host) while reading response header from upstream, client: 127.0.0.1, server: , request: "GET / HTTP/1.1", upstream: "fastcgi://127.0.0.1:9001", host: "coba-laravel.test"

Please advice from the master for the solution, thank you.

Regards,
Rahmad
Hello, I have the same problem now. Is there a corresponding solution? Below are some of my configurations.

worker_processes 2;

error_log logs/error_2.log warn;

pid logs/nginx.pid;

events {
worker_connections 1024;
}

http {
include mime.types;
resolver 8.8.8.8;
default_type application/octet-stream;
rewrite_log on;
access_log logs/access_2.log main;
sendfile on;
underscores_in_headers on;
keepalive_timeout 65;

...others

server{
...others

location /jd/ {
lua_need_request_body on;
default_type 'text/html';
error_log logs/error_3.log warn;
lua_code_cache on;
rewrite_by_lua_file cooperoplua/jumpserver.lua;
}

location @jump_proxy {
proxy_pass $uri;

proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $connection_upgrade;
# proxy_set_header Connection "upgrade";
# proxy_set_header Connection keep-alive;
proxy_set_header Host $host:$server_port;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;

expires 0d;
}

}
}

I've tried some methods, such as ` keepalive_ requests 500;`; Or "worker_connections: 4096;" And other methods. However, there is no effect, and the prompt is still: wsarecv() failed (10054: an existing connection was forcefully closed by the remote host) while reading response header from upstream, but only one host has a problem, the other hosts are good, and there is no problem on my local host
lzjyzq2 Wrote:
-------------------------------------------------------
> Hello, I have the same problem now. Is there a corresponding solution?
> Below are some of my configurations.
>
> worker_processes 2;
>
> error_log logs/error_2.log warn;
>
> pid logs/nginx.pid;
>
> events {
> worker_connections 1024;
> }
>
> http {
> include mime.types;
> resolver 8.8.8.8;
> default_type application/octet-stream;
> rewrite_log on;
> access_log logs/access_2.log main;
> sendfile on;
> underscores_in_headers on;
> keepalive_timeout 65;
>
> ...others
>
> server{
> ...others
>
> location /jd/ {
> lua_need_request_body on;
> default_type 'text/html';
> error_log logs/error_3.log warn;
> lua_code_cache on;
> rewrite_by_lua_file cooperoplua/jumpserver.lua;
> }
>
> location @jump_proxy {
> proxy_pass $uri;
>
> proxy_http_version 1.1;
> proxy_set_header Upgrade $http_upgrade;
> proxy_set_header Connection $connection_upgrade;
> # proxy_set_header Connection "upgrade";
> # proxy_set_header Connection keep-alive;
> proxy_set_header Host $host:$server_port;
> proxy_set_header X-Real-IP $remote_addr;
> proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
>
> expires 0d;
> }
>
> }
> }
>
> I've tried some methods, such as ` keepalive_ requests 500;`; Or
> "worker_connections: 4096;" And other methods. However, there is no
> effect, and the prompt is still: wsarecv() failed (10054: an existing
> connection was forcefully closed by the remote host) while reading
> response header from upstream, but only one host has a problem, the
> other hosts are good, and there is no problem on my local host


This problem has been solved. I have removed the following two configurations:

proxy_ set_ header Host $host:$server_ port;

proxy_ set_ header X-Forwarded-For $ proxy_ add_ x_ forwarded_ for;
Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 83
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready