Bug #19022 [Com]: PHP Warning: Failed to write session data (files)

From: Date: Wed, 17 Jun 2015 07:10:40 +0000
Subject: Bug #19022 [Com]: PHP Warning: Failed to write session data (files)
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-193589@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=19022&edit=1

 ID:                 19022
 Comment by:         roel dot duijnhoven at gmail dot com
 Reported by:        phpbugs at mx4k dot com
 Summary:            PHP Warning:  Failed to write session data (files)
 Status:             No Feedback
 Type:               Bug
 Package:            Session related
 Operating System:   linux (rh7.3), apache 1.3.26
 PHP Version:        4.2.2
 Block user comment: N
 Private report:     N

 New Comment:

A single user of our website keeps getting these errors! They occur after a file upload. I cannot
reproduce them myself but do see them popping up in NewRelic.

Enough disk space and most other sessions work just fine.

I am using PHP 5.5.18.


Previous Comments:
------------------------------------------------------------------------
[2015-06-10 08:43:56] dutchprogrammer at gmail dot com

I had the same error everything was correct like the setting the folder permissions.

It looks like an bug in php in my case because when i delete my PHPSESSID cookie it was working
again so aperently something was messed up and the session got removed but the cookie was still
active so php had to define the cause differently and checking first if the session file is still
they and give another error and not the permission error

------------------------------------------------------------------------
[2011-01-04 22:33:39] jamontoya at unitec dot edu

I just changed the privileges to directory where session files were expected to be saved, that
solved this issue.

------------------------------------------------------------------------
[2010-07-04 05:14:37] glspeed at juno dot com

I do not know if mine is the same "bug"  I went to my site: http://www.videotime.info and I got the following code:
Warning: Unknown: open(/tmp/www.videotime.info/sess_2d42195412bd7242893f1ce67b531875, O_RDWR)
failed: Permission denied (13) in Unknown on line 0

Warning: Unknown: Failed to write session data (files). Please verify that the current setting of
session.save_path is correct (/tmp/www.videotime.info) in Unknown on line 0

I was looking for a solution for this and found your website.  Should I reinstall?  Will that remedy
it temporarily?

Gino

------------------------------------------------------------------------
[2009-03-31 20:15:45] prikid at gmail dot com

We are currently getting the same error on 2 different enviroments. This does not happen all the
time, but often enough to be an annoyance during testing.

Environment as follows:
1. FreeBSD 6.2-RELEASE 
[root@crossbow /]# cat /usr/local/etc/php.ini | grep "session"

session.save_handler = files
session.save_path = "/var/tmp"
session.use_cookies = 1

[root@crossbow /]# php -v
PHP 5.2.9 with Suhosin-Patch 0.9.7 (cli) (built: Mar 31 2009 12:24:17) 
Copyright (c) 1997-2009 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2009 Zend Technologies
[root@crossbow /var/www/branches]# apachectl -v
Server version: Apache/2.0.63
Server built:   Apr 16 2008 16:52:47

---
2. Red Hat Enterprise Linux ES 4

[root@131080-stagingdb /]# cat /etc/php.ini |grep "session"
session.save_handler = files
session.save_path = "/var/lib/php/session"
session.use_cookies = 1

[root@131080-stagingdb /]# php -v
PHP 5.2.9 (cli) (built: Feb 27 2009 14:38:59) 
Copyright (c) 1997-2009 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2009 Zend Technologies
[root@131080-stagingdb logs]# apachectl -v
Server version: Apache/2.0.52
Server built:   Jun 29 2007 05:07:13

------------------------------------------------------------------------
[2008-02-28 17:50:49] rasmus@php.net

session.save_path = "0;\tmp"

??  What is 0;\tmp supposed to mean?

------------------------------------------------------------------------


The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at

    https://bugs.php.net/bug.php?id=19022


--
Edit this bug report at https://bugs.php.net/bug.php?id=19022&edit=1


Thread (75 messages)

« previous php.bugs (#193589) next »