I would use a special session solution in which sessions are stored in a database.
This way, all web servers will have access to the same session repository, and you can decide how long the session should be kept.
You can create something that works with regular PHP sessions or a fully autonomous class to handle them.
I did something similar to share the session between asp and asp.net on different services, and it works.
If performance is a problem, use a separate database, memcached or mysql cluster (also memory), or possibly mongoDB for sessions.
source
share