[horde] Proxy errors to downstream Horde server

Simon Wilson simon at simonandkate.net
Mon Jun 10 12:51:37 UTC 2013


----- Message from Arjen de Korte <arjen+horde at de-korte.org> ---------
    Date: Mon, 10 Jun 2013 14:46:21 +0200
    From: Arjen de Korte <arjen+horde at de-korte.org>
Subject: Re: [horde] Proxy errors to downstream Horde server
      To: horde at lists.horde.org


> Citeren Simon Wilson <simon at simonandkate.net>:
>
>> ----- Message from Arjen de Korte <arjen+horde at de-korte.org> ---------
>>   Date: Mon, 10 Jun 2013 14:23:40 +0200
>>   From: Arjen de Korte <arjen+horde at de-korte.org>
>> Subject: Re: [horde] Proxy errors to downstream Horde server
>>     To: horde at lists.horde.org
>>
>>
>>> Citeren Simon Wilson <simon at simonandkate.net>:
>>>
>>>> A quick config change to the proxypass timeout with  
>>>> "connectiontimeout 300 timeout 300" makes no discernable  
>>>> difference, so even with 5 minutes timeout I am still getting  
>>>> just as many of the 502s.
>>>>
>>>> How long should the ping process take? and how do I identify when  
>>>> it starts finished in the device log?
>>>
>>> It can take up to $conf[activesync][ping][heartbeatmax] seconds  
>>> (which can be 59 minutes or 3540 seconds max). Usually, it will be  
>>> lower though (depending on the client), with a minimum of  
>>> $conf[activesync][ping][heartbeatmin] seconds.
>>>
>>>> From what I can see a pid is held from the auth request at the  
>>>> start of a PING through to that pid disappearing from the logs  
>>>> for between 2 and 4 minutes.
>>>
>>> That shouldn't happen.
>>>
>>>> Or is there something else that it continues to do that needs to  
>>>> be kept alive for the PING request?
>>>
>>> Yes. It keeps monitoring the folders every  
>>> $conf[activesync][ping][waitinterval] seconds for changes and if  
>>> it finds any, will report that back to the client. The client in  
>>> turn will run a SYNC then. After that (or in the absence of  
>>> changes) the device will initiate a new PING and all starts over  
>>> again. So generally, for any ActiveSync device that is active,  
>>> you'll see a process running on your server with a connection open  
>>> to your IMAP server.
>>
>>
>> Thanks (again) :) Arjen.
>>
>> So my max is set to 2700 - should I have connectiontimeout /  
>> timeout on the proxy set to that?
>
> I would say, at *least* that. You definitly don't want your proxy to  
> take the initiative to terminate a connection, before your client  
> does.
>
>> And any impact on resources on the proxy server, holding processes  
>> for that long?
>
> That largely depends on the number of connections your proxy can  
> handle. It will need to keep two connections open per client (one to  
> the client, one to the server). If that is going to be a problem,  
> largely depends on the size of your userbase (the number of  
> simultaneous connections it should proxy) and whatever other  
> activities are running on that box. Unless you have thousands of  
> users, I wouldn't worry about it.

OK... from what I can see in Apache doco, connectiontimeout is  
"Connect timeout in seconds. The number of seconds Apache waits for  
the creation of a connection to the backend to complete" and timeout  
is "Connection timeout in seconds. The number of seconds Apache waits  
for data sent by / to the backend".

Given those definitions I have set *connectiontimeout* to 600 (if it  
takes longer than 10 minutes to establish a proxy connection to the  
Horde server then I think I have other issues) and *timeout* to 3000  
seconds. I am off to bed now, will see what that does overnight.

Thanks Arjen, you have been very helpful.

Simon.

--
Simon Wilson
M: 0400 12 11 16
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-keys
Size: 1339 bytes
Desc: PGP Public Key
URL: <http://lists.horde.org/archives/horde/attachments/20130610/ceecf49a/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: PGP Digital Signature
URL: <http://lists.horde.org/archives/horde/attachments/20130610/ceecf49a/attachment-0001.bin>


More information about the horde mailing list