php sessions errors after PHP 4.4.1 and apache 1.3.4 upgrade

SupermanInNY

Well-Known Member
Jul 19, 2003
255
0
166
Hi All,

I'm running in Safe mode. No problems there.

I've upgraded the Apache server with php to latest and now users complain about session issues.

Aparently there is a problem with /tmp denying them write permissions Safe Mode restrictions in effect errors.

Any suggestion?

my /tmp is on a separate partition (has been like that for 4 months with no prob).

/dev/lvmvol/tmp 4.0G 104M 3.7G 3% /tmp

This is how the /tmp permission settings are:

drwxrwxrwt 8 root root 69632 Nov 9 15:22 tmp

Any pointers?

-Alon
 

Cloak

Active Member
Jun 19, 2003
26
0
151
I'm having the same problem, haven't figured out what the problem is yet though.
 

webignition

Well-Known Member
Jan 22, 2005
1,876
1
166
It would probably be best for both of you to first post your OS version, Apache version and PHP version. I'm assuming you're both on Apache 1.3.4 and PHP 4.4.0, but what OS?

This may both help to narrow the problem down and alert others with the same configuration to check their systems too.

I'm on CentOS 3.6, Apache 1.3.4 and PHP 4.4.0 + 5.0.4 and I'm not experiencing this session issue and /tmp is being written to just fine by PHP scripts.

That might not be too useful in itself, as it does nothing to solve the problem, however if you share your configurations you might be able to spot some common issue that points to the problem.

On the assumption that Apache 1.3.4 is not the root cause here, as it causes me no woes, it might be the PHP version. If you're on 4.4.1, you could try downgrading to 4.4.0 as I've seen other threads of late that mention issues with 4.4.1 (not that I can find them now!).
 

mss6

Member
Jun 19, 2003
19
0
151
I'm facing the same problem! Here is my post: http://forums.cpanel.net/showthread.php?t=46280

I had a problem with swap (being of zero size). I solved that problem, but not sure if it is related.

I'm hosting lots of php scripts for customers and I'm in deep trouble already :(

Edit: I'm running WHM 10.1.0 cPanel 10.2.0-R82 RedHat Enterprise 3 i686 apache 1.3.34 PHP 4,3.10 and tried 4.3.11
 
Last edited:

Cloak

Active Member
Jun 19, 2003
26
0
151
Too many complaints to keep it in production, I'm downgrading now, hopefully all will go back to normal. For reference though:

WHM 10.8.0 cPanel 10.8.1-C29
RedHat Enterprise 3 i686 - WHM X v3.1.0

RHE3, Apache 1.3.34
 

mss6

Member
Jun 19, 2003
19
0
151
This problem has nothing to do with PHP 4.x. I'm using 4.3.11 and facing the same trouble.
 

chirpy

Well-Known Member
Verifed Vendor
Jun 15, 2002
13,437
33
473
Go on, have a guess
/tmp should always be chmod 1777 and not just 777 otherwise you're opening yourself up to serious server compromises.
 

SupermanInNY

Well-Known Member
Jul 19, 2003
255
0
166
My OS is RH9
Apache 1.3.34 and PHP 4.4.1 (both are stated in the title).
I've upgraded from PHP 4.3.11 and Apache 1.3.33

The errors I'm getting are:

I am running in Safe Mode On,. but that shouldn't have an effect on /tmp as it is supposed to be available for sessions.

Warning: session_save_path(): SAFE MODE Restriction in effect. The script whose uid is 32033 is not allowed to access owned by uid 0 in

Well.. If I run phpinfo(); I see the correct value:

session.save_path /tmp /tmp

-Alon.
 

Cloak

Active Member
Jun 19, 2003
26
0
151
chirpy said:
/tmp should always be chmod 1777 and not just 777 otherwise you're opening yourself up to serious server compromises.
That's what finally fixed it for me. I noticed that it was changed as well and re-upgraded php and it seems to be working well. I had to also turn off versioning because Zend stopped working with php 4.4.1
 

SupermanInNY

Well-Known Member
Jul 19, 2003
255
0
166
Cloak said:
That's what finally fixed it for me. I noticed that it was changed as well and re-upgraded php and it seems to be working well. I had to also turn off versioning because Zend stopped working with php 4.4.1

Could Zend be the problem?
I've had the Zend Performance Suite until now and of course it is dead now.
I just purchased the Platform1 from them which will support 4.4.1 but haven't installed it yet.
I don't think this is an issue, but I could be wrong.

-Alon.
 

webignition

Well-Known Member
Jan 22, 2005
1,876
1
166
mss6 said:
:eek: Who changed /tmp permission on my server?! :mad:

:) I solved it with chmod 777 /tmp and it is working now :D

Thank you webignition :p
Good to hear that this fixed it for you and everyone else for whom it worked!

However, as Chirpy says, 1777 is preferable to 0777 for /tmp permissions.