Discussion:
[uWSGI] Getting ProxyPass not working
vogen
2018-08-09 02:44:24 UTC
Permalink
Hi,

I am trying redirect request to localhost/mason to proxy pass

I have apache 2.4.29 and have following line in httpd2.conf
ProxyPass /mason uwsgi://localhost:3031/
I can access http://localhost:3031 but trying to access
http://localhost/mason gives an error in apache error log.

Running uwsgi
$uwsgi --http :3031 --http-modifier1 5 --psgi myapp.pl
*** uWSGI is running in multiple interpreter mode ***
spawned uWSGI worker 1 (and the only) (pid: 77535, cores: 1)
[pid: 77535|app: 0|req: 1/1] 127.0.0.1 () {28 vars in 306 bytes} [Thu Aug
9 12:39:13 2018] GET / => generated 20 bytes in 0 msecs (HTTP/1.1 200) 1
headers in 44 bytes (0 switches on core 0)

Apache error.log
[Thu Aug 09 12:39:20.464327 2018] [proxy:error] [pid 5230] (49)Can't assign
requested address: AH00957: uwsgi: attempt to connect to [::1]:0 (*) failed
[Thu Aug 09 12:39:20.465735 2018] [:error] [pid 5230] [client
127.0.0.1:46189] failed to make connection to backend: localhost:0

Regards,
Alexandre Rossi
2018-08-10 06:14:38 UTC
Permalink
Hi,
Post by vogen
I am trying redirect request to localhost/mason to proxy pass
[...]
Post by vogen
Apache error.log
[Thu Aug 09 12:39:20.464327 2018] [proxy:error] [pid 5230] (49)Can't assign
requested address: AH00957: uwsgi: attempt to connect to [::1]:0 (*) failed
[Thu Aug 09 12:39:20.465735 2018] [:error] [pid 5230] [client
127.0.0.1:46189] failed to make connection to backend: localhost:0
See https://github.com/unbit/uwsgi/commit/6ce856c9fdb98833f9142f84c92b75f546b32dc2#r28100258
and https://github.com/unbit/uwsgi/issues/1491

This is a bug in mod_proxy_uwsgi . Use the supplied patch or as a
workaround, use another port than the default port (i.e. do not use
3031).

Sorry for not having submitted this as a pull request earlier.

Alex

Loading...