On May 26, 2:10 am, rahul <[EMAIL PROTECTED]> wrote:
> Hello,
> I'm new to pylons. Started out a couple of days ago. Comming from
> django, I am attempting to move to pylons for my current project, and
> everything went smoothly until i got to the point of installing pylons
> on apache2 + mod_python.
>
> I followed the instructions on this 
> page:http://docs.pythonweb.org/display/pylonscookbook/Production+deploymen...
>
> Everything seemed to work fine, but my sessions just dosent seem to
> get saved when running from apache.
>
> It works fine when i do the paster serve command.
>
> Any ideas?

What component are you using for providing session support?

When moving to Apache from standalone web servers, a couple of things
that might cause existing code not to work.

The first is that Apache if started as root initially, then runs the
application as a special user. Thus,  if using some sort of existing
file based session database from your standalone web server
configuration, your application may no longer have write access to the
session database.

The second issue is that current working directory of Apache processes
is typically the root directory of the file system and because it is
being run as distinct user as well, you will not have write access to
the current working directory. This would be a problem if code assumed
that the working directory was where the application was and didn't
correctly use absolute paths to access things.

A third issue is that Apache can use multiple processes for handling
requests. Thus if you have code which expected everything to run in
the one process, for example an in memory session database, then the
session information isn't shared and things will only appear to work
if subsequent requests so happen to go to the same process for
handling.

Whether these generic issues are of help or not I don't know, but they
are still worth knowing and always keeping in mind.

Graham


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"pylons-discuss" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/pylons-discuss?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to