Project

General

Profile

Actions

Bug #5355

closed

On RHEL system, ncf-builder hangs on a page with only ncf header with "Unable to connect to WSGI daemon process 'ncf_api_flask_app'[...]" in /var/log/rudder/apache2/error.log

Added by Nicolas PERRON over 10 years ago. Updated over 10 years ago.

Status:
Released
Priority:
1 (highest)
Assignee:
Jonathan CLARKE
Category:
System integration
Target version:
Severity:
UX impact:
User visibility:
Effort required:
Priority:
Name check:
Fix check:
Regression:

Description

On RHEL system, ncf-builder does not work since it hangs on a empty page except a ncf header.
Errors appeared in /var/log/rudder/apache2/error.log:

[...]
[Tue Aug 05 17:06:23 2014] [error] [client 10.0.2.2] (13)Permission denied: mod_wsgi (pid=4376): Unable to connect to WSGI daemon process 'ncf_api_flask_app' on '/etc/httpd/logs/wsgi.3417.1.1.sock' after multiple attempts., referer: https://server.rudder.local:8081/ncf-builder/?path=%2Fvar%2Frudder%2Fconfiguration-repository%2Fncf
[...]

On RHEL, the socket is by default located in /etc/httpd/logs/ which is only writable to root:

[vagrant@server ~]$ sudo ls -lh /etc/httpd/logs/
total 8,0K
-rw-r--r-- 1 root   root    0 22 juil. 15:57 access_log
-rw-r--r-- 1 root   root 2,7K  5 août  16:50 error_log
-rw-r--r-- 1 root   root    0 22 juil. 15:57 ssl_access_log
-rw-r--r-- 1 root   root 1,2K  5 août  16:50 ssl_error_log
-rw-r--r-- 1 root   root    0 22 juil. 15:57 ssl_request_log
srwx------ 1 apache root    0  5 août  16:50 wsgi.1315.0.1.sock

On most Linux OS, socket are located int /var/run/ then a workaround is to add in /etc/httpd/conf.d/ncf-api-virtualenv.conf:

WSGISocketPrefix run/wsgi

After this modification, a restart of Apache and the socket will be into /var/run/httpd:

[vagrant@server ~]$ sudo ls -lh /var/run/httpd/
total 4,0K
-rw-r--r-- 1 root   root 5  5 août  17:12 httpd.pid
srwx------ 1 apache root 0  5 août  17:12 wsgi.4454.1.1.sock

Actions

Also available in: Atom PDF