Re: [PHP-DEV] Sessio variables and Load Balancing From: Chris Adams (chris <email protected>)
Date: 06/30/00

> > > How do we all know that NFS is unreliable under Linux? Why is it
> > > unreliable and were do I find documentation to support this? I've
heard
> > > people say this, but never with any information to back that up..
seems
> > > more of a "feeling".
> >
> > Search around if you want to see reports of unreliability and
performance
> > problems with NFS. There've been a couple Ask Slashdots about it, with
the
> > general conclusion that recent kernels are much better than the old
ones.
> >
>
> feeling? i doubt that, i've used NFS for linux, most people know that NFS
is
> an invention is Sun, which is not as of this day open source, and does not
> have very good support in linux, read the NFS-howto and read yourself that
> NFS linux-client linux-server interactions are VERY slow and VERY
upstable.
> 2.4.x should have much better support for this, and there is talk of Sun
> going opensource with NFS, but until either of those happen it would not
be
> a very good idea to use NFS for thousands of sessions.

Oh, I agree with you completely. The original poster was the one who thought
that it'd be faster to use the files handler over NFS than a persistent
connection to mysql.

> > If you're using MySQL or a well-tuned Oracle install, this won't be a
big
> > deal at all. Retrieving a record on an indexed column is extremely fast.
> If
> > the single query necessary to retrieve a session's data measurably
affects
> > your site performance, your database is either severely underspeced or
> your
> > DBA should be fired for gross incompetence.
> >
>
> agreed, however if the programmer is writing to sessions 4-5 times per
page
> that could have very detrimental effects on the database server. everyone
> needs to be informed whats going on and write things suitable for it.

The session read handler should be called once at the start of the page and
the write handler once at the end. With a decent session handler, it's 2
queries per page (SELECT,UPDATE), with an additional INSERT when the session
is first created and a DELETE when session_destroy() is called.

-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, e-mail: php-dev-unsubscribe <email protected>
For additional commands, e-mail: php-dev-help <email protected>
To contact the list administrators, e-mail: php-list-admin <email protected>