ESGF / esgf-installer

ESGF P2P Node Installer
https://esgf.llnl.gov/
Other
21 stars 21 forks source link

httpd error_log reporting permissions issue. #578

Open nathanlcarlson opened 5 years ago

nathanlcarlson commented 5 years ago

From /var/log/httpd/error_log

(13)Permission denied: mod_wsgi (pid=23841): Unable to connect to WSGI daemon process 'cog-site' on '/etc/httpd/run/wsgi.23829.0.3.sock' as user with uid=48.

It seems there is a permission issue.

nathanlcarlson commented 5 years ago

It appears there is a line the specifies the group for the process in /etc/httpd/conf/esgf-httpd.conf

WSGIProcessGroup cog-site

After commenting this line out the permissions message error went away.

nathanlcarlson commented 5 years ago

After spending some more time on this I have not yet figured out why this httpd config works for 2.x and not 3.x. If it is not essential that this WSGIProcessGroup parameter be set, it may be best to remove it.

nathanlcarlson commented 5 years ago

The WSGIProcessGroup parameter was removed in #591

nathanlcarlson commented 5 years ago

This is reopened as this has been reinvestigated. The cause of this permission error is a result of this code in the installer:

os.chmod("/var/run", stat.S_IWRITE)
os.chmod("/var/run", stat.S_IWGRP)
os.chmod("/var/run", stat.S_IWOTH)

This results in only the o+w mode being set as each command turns only that bit on and all others off.

nathanlcarlson commented 5 years ago

PR #676 has been made to resolve this.