Re: 0 byte session files.
| From: | 1LT John W. Holmes | Date: | Mon, 23 Sep 2002 14:57:36 +0000 |
| Subject: | Re: 0 byte session files. | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-117283@lists.php.net to get a copy of this message | ||
I ran into a problem with sessions on sourceforge, which uses load
balancing. What's probably happening for you is that each server is looking
in it's own /tmp directory for the sessions. So, a user logs on from a page
on Server A, which creates a good session file on Server A for the user.
Now, the next request goes to Server B. It doesn't have a session file to
load, but it sees a session_start() in the code, so it creates an empty
session file.
I'm surprised your sessions are even working. A solution would be to have
all four servers share a common folder to write session data to. I don't
know how possible/easy that is, though...
---John Holmes...
----- Original Message -----
From: <jacob@keystreams.com>
To: <php-general@lists.php.net>
Sent: Monday, September 23, 2002 10:40 AM
Subject: [PHP] 0 byte session files.
> Hello,
>
> I run a site that operates across 4 load balanaced servers and we seem to
be
> getting a problem where session files are created with 0 bytes (contain no
> data) on 2 of the 4 servers. All the servers are FreeBSD 4.5 running
Apache
> 1.3.26 and PHP 4.2.3. Any suggestions would be appreciated. Note: We have
> already investigated most ownership/file privilege possibilities.
>
> Jacob
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>