Pidfile option
Marco
13 October 2009, 20:17
Hiawatha version: 6.17.1
Operating System: Linux with kernel 2.6.30.5
Hi Hugo
If I change in hiawatha.conf
Pidfile = /var/run/hiawatha.pid
when I run perl CGI, I see in error.log file this message
Tue 13 Oct 2009 19:54:36 +0200|127.0.0.4|/path/of.cgi|CGI-Wrapper v6.17.1|Only the Hiawatha webserver is allowed to execute this program.
Tue 13 Oct 2009 19:54:36 +0200|127.0.0.4|/var/www/hotspotmaster/perl/vari.cgi|no output
else if...
Pidfile = /usr/local/var/run/hiawatha.pid
It work fine!
Pidfile is writed correctly into /var/run/ and /usr/local/var/run/ !!
Marco
Marco
13 October 2009, 20:26
Sorry, I prefer to always put the logs in readable mode :-)
Tue 13 Oct 2009 19:54:36 +0200|127.0.0.4|/path/of.cgi|no output
Hugo Leisink
14 October 2009, 08:33
The CGI-wrapper needs the Hiawatha PID file. For security reasons, the CGI-wrapper will only work if it's executed by Hiawatha. To verify if it's parent is Hiawatha, the CGI-wrapper needs to know what Hiawatha's PID is. It does this via the Hiawatha PID file. If you change it's location, the CGI-wrapper won't be able to find it. If you use the CGI-wrapper, leave the PID file location unchanged.
Marco
15 October 2009, 12:21
I have simple supposed that cgi-wrapper read hiawatha config file :-)
But I would know if is there a method to move Pidfile from /usr/local/var/run dir
/var/run dir (with cgi-wrapper at work is intended).
Can I change path of Pidfile by modify configure option in installation
phase? because in my server /usr partition dir must be write protect...
Hugo Leisink
15 October 2009, 12:33
The Hiawatha configuration file can be come very big. If the CGI-wrapper is to read the Hiawatha configuration file, it will become slower. If you want to change the PID file locatie and still use the CGI-wrapper, change the PID directory at compile time: after a ./configure and before a make, edit config.h and change the PIDFILE_DIR content.
This topic has been closed.