Problem With Session & Resque

I have 4 server:

  • 1 Load balancing (LB) (this server auto redirect to AP1 or AP2)

  • 2 Web server (AP1, AP2)

  • 1 DB server

This is my problem:

  1. I login in AP1 from LB server. But when LB server redirect to AP2. I must relogin.

=> I don’t want to relogin.

I used CDbHttpSession

‘session’ => array (

		'sessionName' => 'Site Session',			

		'class'=> 'CDbHttpSession',			

		'autoCreateSessionTable'=> false,			

		'connectionID' => 'db',			

		'sessionTableName' => 'YiiSession',			

		'useTransparentSessionID'=>(isset($_POST['PHPSESSID']) && $_POST['PHPSESSID']) ? true : false,			

		'autoStart' => false,

		'cookieMode' => 'only',			

		'timeout' => 1440,	


  1. I need use Yii::app()->resque->createJob(…) but it doesn’t run.

I installed resque, redis.

What should I do?

Everybody help me?

Look into "single sign-on" (SSO). There are many techniques of implementing SSO.

As for your yii-resque problem, there are many things you need to look at.

Check the logs, there are some yii-resque-specific logs. That would be the first place to look.