Re: sessions

2008-08-26 Thread Lars Haugseth
* [EMAIL PROTECTED] (Jeff Pang) wrote:
 
 On Mon, Aug 25, 2008 at 2:06 AM, Lars Haugseth [EMAIL PROTECTED] wrote:
 
 
  Another solution, which is not really what the OP was asking about, but
  probably fixes his problem, is to ensure that each request from the same
  client will always be sent to the same webserver (based on a hashing of
  the client's IP address, for example.)
 
 But client's IP can be changed from day to day, especially for the
 dialup clients.

Changes from one day to another shouldn't be a problem, as long as it
doesn't change in the middle of a session.

Certain load balancing systems can be configured to direct one client
to the same host on subsequent requests. The one we're using does this
through cookies issued by the load balancer.

-- 
Lars Haugseth

If anyone disagrees with anything I say, I am quite prepared not only to
 retract it, but also to deny under oath that I ever said it. -Tom Lehrer

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: sessions

2008-08-26 Thread Dwalu Z. Khasu
On Sun, 24 Aug 2008, Lars Haugseth wrote:

=* [EMAIL PROTECTED] (David Dorward) wrote:
= 
= JuneEarth wrote:
=  How to make CGI sessions to be shared among multi-webservers? Thanks.
= 
= They have to use a shared data store for the session information. Using
= a database for that would be one approach.
=
=Another solution, which is not really what the OP was asking about, but
=probably fixes his problem, is to ensure that each request from the same
=client will always be sent to the same webserver (based on a hashing of
=the client's IP address, for example.)
=
=
Unfortunately using sticky sessions puts a site in the categories of 
Does not scale, Unreliable, and We have many frustrated users.  

David's earlier response for a shared data store for session information 
(via database).  

Search for distributed sessions on your favorite search engine.
-- 
- Dwalu
.peace
--
I am an important person in this world -
Now is the most important time in my life -
My mistakes are my best teachers -
So I will be fearless.
- Student Creed

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: sessions

2008-08-25 Thread Lars Haugseth
* [EMAIL PROTECTED] (David Dorward) wrote:
 
 JuneEarth wrote:
  How to make CGI sessions to be shared among multi-webservers? Thanks.
 
 They have to use a shared data store for the session information. Using
 a database for that would be one approach.

Another solution, which is not really what the OP was asking about, but
probably fixes his problem, is to ensure that each request from the same
client will always be sent to the same webserver (based on a hashing of
the client's IP address, for example.)

-- 
Lars Haugseth

If anyone disagrees with anything I say, I am quite prepared not only to
 retract it, but also to deny under oath that I ever said it. -Tom Lehrer

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: sessions

2008-08-25 Thread Lawrence Statton
 
  Another solution, which is not really what the OP was asking about, but
  probably fixes his problem, is to ensure that each request from the same
  client will always be sent to the same webserver (based on a hashing of
  the client's IP address, for example.)
 
 But client's IP can be changed from day to day, especially for the
 dialup clients.
 

Or in the case of broadband users from request-to-request.

I've been in six different major cities here, and in every one, the
cable company gives you an RFC-1918 addresses and run a cadre of proxy
servers.  

Where I am now, to get a real IP address from Megacable would cost
me 70EUR per month above and beyond the regular price.

Imagine a million users behind a block of 48 IP addresses.

--L

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: sessions

2008-08-24 Thread David Dorward
JuneEarth wrote:
 How to make CGI sessions to be shared among multi-webservers? Thanks.

They have to use a shared data store for the session information. Using
a database for that would be one approach.

-- 
David Dorward   http://dorward.me.uk/

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: sessions

2008-08-24 Thread Sean Davis
On Sat, Aug 23, 2008 at 2:52 AM, JuneEarth [EMAIL PROTECTED] wrote:
 How to make CGI sessions to be shared among multi-webservers? Thanks.

The simplest way is to use a transactional database system.  You read
the session from the database and write back to the database.  It will
work with as many webservers as you have (with some very high limits,
of course).  There are multiple perl modules that implement sessions
this way.  Also, most of the CGI frameworks use something along these
lines as well.

Sean

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/