Forum

PHP FastCGI daemon exited with code 6

Andre
19 July 2011, 11:23


Hiawatha version: 7.5
Operating System: Linux 2.6.32.42

Where can I find the meaning of the exit codes for php-fcgi?

I rebooted my machine and I keep getting this exit code when I try to run php-fcgi. I can run php-cgi by itself and bind it to a socket and it runs ok /usr/bin/php-cgi -b /var/run/hiawatha.sock but php-fcgi keeps shutting down?

Thanks in advance.
Andre
19 July 2011, 19:59
I've narrowed the problem down to a php shared module mapi.so. I'm running Zarafa Email Collaboration platform on top of hiawatha and it worked well until I rebooted to update my kernel. I went back to the original kernel and still the same problem.

If I disable the mapi.so extension hiawatha php-fcgi executes ok. If I enable the extension, the php-fcgi server will crash. It is being tested with 8 users and so I've had to create a bash loop to make sure php-cgi is running. Unfortunately the only error info I get is PHP FastCGI daemon exited with code 6 so it's difficult to track down the issue without ptrace which I can't do until the weekend.
Hugo Leisink
21 July 2011, 22:07
The php-fcgi exit codes are the perror codes generated by the OS. You can use the commandline tool 'perror' to get the meaning of the code. Error code 6 means "No such device or address".

Perhaps a bad mapi option (invalid hostname or ip address) in php.ini? What are you using the mapi module for?
Andre
26 July 2011, 22:14
The problem ended up being a folder permission in etc/. Once php-fcgi switched the user to http, it was unable to read the configuration file for the mapi.so module. Thanks for the perror info. It helped track it down.
This topic has been closed.