Problem with session controiler files in PHP on Roxen
| From: | Andreas Lundgren | Date: | Thu, 06 Sep 2001 18:12:21 +0000 |
| Subject: | Problem with session controiler files in PHP on Roxen | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-66254@lists.php.net to get a copy of this message | ||
Hello!
We installed php 4.0.6 in a Roxen 2.1.625 web server on Solaris 7. Now we have a problem with temporary session files. The session_start() command will abort with the following error message:
Warning: open(/tmp/sess_e8771af1171a6cbdf51eebdba5199d25, O_RDWR) failed: m (0) in [path/file.php] on line 78
Warning: open(/tmp/sess_e8771af1171a6cbdf51eebdba5199d25, O_RDWR) failed: m (0) in Unknown on line 0
Warning: Failed to write session data (files). Please verify that the current setting of session.save_path is correct (/tmp) in Unknown on line 0
The thing is that session.save_path is correct. It points to /tmp, where the web server and php has write permissions. The session controller can read and write existing files. The problem occurs only when session_start() has to create a _new_ session control file.
If we use fopen(), we can read and write files in /tmp. If we create a file with the name of the supposed session control file (sess_..., the name stated in the error message from session_start()) with fopen() and then reload the page, session_start() will execute correctly, using the file we just created for it. Then php will access the file correctly, writing and reading session variables just as it is supposed to.
So, again, the problem occurs only when session_start() has to create a _new_ session control file. Shouldn't a file be created automatically if it doesn't exist?
The only strange thing with the installation of PHP on Roxen was that no binary file was created. We can't find the stand-alone program to execute php files from the shell. This happened even though no error message was given at the time of installation.
The roxen installation was made as the config script suggested.
Does anyone have a clue why this problem occurs?
Best regards,
Andreas Lundgren
mailto:d99alu@efd.lth.se
____________________________________
Andreas Lundgren
Magistratsvägen 55P:405
226 44 Lund
046-320250, 0708-960717, ICQ:1430437