Hi,
I'm trying to make z-push function with fast-cgi. Before switching to fast-cgi, everything worked OK using mod_php. However, I have to run apache in worker mode.
I've followed the related topic Working Solution for Z-Push and PHP in (Fast)CGI Mode (viewtopic.php?f=4&t=1245&p=5121&hilit=fast+cgi#p4762), and although it did solved in part a problem, I have another major issue, maybe similar to other topics ("Z-Push 2.0 alpha2 released"), but unresolved.
I am syncing the emails using an iphone and I can authenticate successfully. On the iphone, it seems to fully connect to the server and does not report any error. However, about 2 minutes later, the iphone displays [unable to read mail. Server error, contact the administrator].
I tried all versions of z-push and none work, but I am using z-push 2.0 alpha 2 right now.
Any idea on how to make z-push2 work with fast-cgi and/or how to resolve this problem (which render z-push unusable) ?
The error log file is empty.
The other log file contains:
09/10/2011 02:15:49 [ 2221] [DEBUG] -------- Start
09/10/2011 02:15:49 [ 2221] [ INFO] Version='z-push-2.0alpha2-777' method='OPTIONS' from='FROMIP' cmd='' getUser='' devId='' devType=''
09/10/2011 02:15:49 [ 2221] [DEBUG] NoPostRequestException: Options request - code: 1
09/10/2011 02:15:49 [ 2221] [ INFO] Options request
09/10/2011 02:15:49 [ 2221] [DEBUG] -------- End
...
09/10/2011 02:15:51 [ 2234] [USER] [ INFO] BackendIMAP->Logon(): User 'USER' is authenticated on IMAP
09/10/2011 02:15:51 [ 2234] [USER] [DEBUG] ZPush::CommandNeedsPlainInput('FolderSync'): false
09/10/2011 02:15:51 [ 2234] [USER] [ WARN] The HierarchyCache should have been initialized by now. Getting empty cache
09/10/2011 02:15:51 [ 2234] [USER] [DEBUG] ASDevice->GetHierarchyCache(): HierarchyCache is up - Cached objects: 0
09/10/2011 02:15:51 [ 2234] [USER] [DEBUG] Initializing folder diff engine
09/10/2011 02:15:51 [ 2234] [USER] [DEBUG] ImportChangesDiff->InitializeExporter(): Initializing folder diff engine
09/10/2011 02:15:51 [ 2234] [USER] [ WARN] ...z-push-2.0a2/backend/imap.php:619 Undefined property: BackendIMAP::$_server (8)
09/10/2011 02:15:51 [ 2234] [USER] [ WARN] ...z-push-2.0a2/backend/imap.php:619 Undefined property: BackendIMAP::$_server (8)
09/10/2011 02:15:51 [ 2234] [USER] [ WARN] ...z-push-2.0a2/backend/imap.php:619 Undefined property: BackendIMAP::$_server (8)
09/10/2011 02:15:51 [ 2234] [USER] [ WARN] ...z-push-2.0a2/backend/imap.php:619 Undefined property: BackendIMAP::$_server (8)
...
09/10/2011 02:15:52 [ 2234] [USER] [DEBUG] ASDevice->GetHierarchyCache(): HierarchyCache is up - Cached objects: 25
09/10/2011 02:15:52 [ 2234] [USER] [DEBUG] FileStateMachine->SetState() written 18196 bytes on file: '/var/lib/z-push/t/4/ApplXXXXXX$
09/10/2011 02:15:52 [ 2234] [USER] [DEBUG] FileStateMachine->SetState() written 4971 bytes on file: '/var/lib/z-push/t/4/ApplXXXXXX-$
09/10/2011 02:15:52 [ 2234] [USER] [DEBUG] BackendIMAP->Logoff(): IMAP connection closed
09/10/2011 02:15:52 [ 2234] [USER] [DEBUG] DeviceManager->Save(): Device data changed
09/10/2011 02:15:52 [ 2234] [USER] [DEBUG] FileStateMachine->SetState() written 2493 bytes on file: '/var/lib/z-push/t/4/ApplXXXXXXXXX-devicedata'
09/10/2011 02:15:52 [ 2234] [USER] [DEBUG] DeviceManager->Save(): Device data saved
09/10/2011 02:15:52 [ 2234] [USER] [DEBUG] -------- End
...
09/10/2011 02:17:03 [ 2396] [USER] [DEBUG] -------- Start
09/10/2011 02:17:03 [ 2396] [USER] [ INFO] Version='z-push-2.0alpha2-777' method='POST' from='FROMIP' cmd='Sync' getUser='USER' devId='ApplXXXXXXXXXXXX$
09/10/2011 02:17:03 [ 2396] [USER] [DEBUG] Used timezone 'America/Montreal'
09/10/2011 02:17:03 [ 2396] [USER] [DEBUG] Including backend file: '...z-push2/backend/imap.php'
09/10/2011 02:17:03 [ 2396] [USER] [DEBUG] Incoming PolicyKey: 2518006593
09/10/2011 02:17:03 [ 2396] [USER] [DEBUG] Client supports version: 2.5
09/10/2011 02:17:03 [ 2396] [USER] [DEBUG] ZPush::CommandNeedsProvisioning('Sync'): true
09/10/2011 02:17:03 [ 2396] [USER] [DEBUG] ASDevice initialized for DeviceID 'ApplXXXXXXXXXX'
09/10/2011 02:17:03 [ 2396] [USER] [DEBUG] FileStateMachine->GetState() on file: '/var/lib/z-push/t/4/ApplXXXXXXXXXX-devicedata'
09/10/2011 02:17:03 [ 2396] [USER] [DEBUG] ASDevice data loaded for user: 'USER'
09/10/2011 02:17:03 [ 2396] [USER] [DEBUG] ZPush::HierarchyCommand('Sync'): false
09/10/2011 02:17:03 [ 2396] [USER] [DEBUG] DeviceManager->ProvisioningRequired('2518006593') saved device key '2518006593': false
09/10/2011 02:17:03 [ 2396] [USER] [DEBUG] ZPush::CommandNeedsAuthentication('Sync'): true
09/10/2011 02:17:03 [ 2396] [USER] [ INFO] BackendIMAP->Logon(): User 'USER' is authenticated on IMAP
09/10/2011 02:17:03 [ 2396] [USER] [DEBUG] ZPush::CommandNeedsPlainInput('Sync'): false
09/10/2011 02:17:03 [ 2396] [USER] [DEBUG] Sync folder: 'Email'
09/10/2011 02:17:03 [ 2396] [USER] [DEBUG] ZPush::GetAdditionalSyncFolderStore('INBOX'): 'false'
09/10/2011 02:17:03 [ 2396] [USER] [DEBUG] ImportChangesDiff->InitializeExporter(): Initializing message diff engine. '0' messages in state
09/10/2011 02:17:03 [ 2396] [USER] [DEBUG] BackendIMAP->GetMessageList('INBOX','1315462623')
09/10/2011 02:17:06 [ 2396] [USER] [DEBUG] Received date is false. Message might be broken.
09/10/2011 02:17:06 [ 2396] [USER] [ INFO] ImportChangesDiff->InitializeExporter(): Found '50' changes
09/10/2011 02:17:06 [ 2396] [USER] [ WARN] StatusException: DiffState->GetState(): Error, state not available - code: 12
09/10/2011 02:17:06 [ 2396] [USER] [ INFO] User-agent: 'Apple-iPhone3C1/810.2'
09/10/2011 02:17:06 [ 2396] [USER] [DEBUG] ZPush::PrintZPushLegal()
About the getState error:
09/10/2011 02:43:06 [ 1942] [USER] [ERROR] Exception: DiffState->GetState(): Error, state not available
Trace:
Array
(
[0] => Array
(
[file] => .../z-push-2.0a2/lib/requestprocessor.php
[line] => 1062
[function] => GetState
[class] => DiffState
[type] => ->
[args] => Array
(
)
)
[1] => Array
(
[file] => .../z-push-2.0a2/lib/requestprocessor.php
[line] => 124
[function] => HandleSync
[class] => RequestProcessor
[type] => ::
[args] => Array
(
)
)
[2] => Array
(
[file] => ...html/z-push-2.0a2/index.php
[line] => 128
[function] => HandleRequest
[class] => RequestProcessor
[type] => ::
[args] => Array
(
)
)
)
09/10/2011 02:17:06 [ 2396] [USER] [DEBUG] -------- End
