Bugs item #2113169, was opened at 2008-09-16 00:24
Message generated for change (Comment added) made by cvinh
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=676128&aid=2113169&group_id=116817
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: Other
Group: None
Status: Open
Resolution: None
Priority: 4
Private: No
Submitted By: kostos (kostos)
Assigned to: wimpunk (wimpunk)
Summary: Timeout option doesn't prevent hangs
Initial Comment:
Hi,
i have Aolynk DR814 ADSL modem which is hanging from time to time and wifi-router (Dlink) connected between ADSL modem and server running ddclient.
In this configiration, when ADSL modem hangs, ddclient also hanging with message like " ddclient - read from 192.168.1.1 .." and still hanged infinitely, even after modem restarted, regardless timeout option is set.
As W/A i have changed the source code line below:
local $SIG{'ALRM'} = sub { $timeout = 1; };
to close socket descriptor when timeout happens:
local $SIG{'ALRM'} = sub { $timeout = 1; close($sd);};
Not sure is it good enough solution, but after week of testing (2 or 3 hangs happened) - it seem working, ddclient didn't hang since. Could you please check if it possible to include similar change into release?
P.S.
Could you also please consider small extension of functionality: in my feeling, it would be not too bad idea to log error message when timeout happens, or even better - to call external script given by option parameter to try to fix the issue.
----------------------------------------------------------------------
Comment By: Cyril VINH-TUNG (cvinh)
Date: 2009-08-16 17:57
Message:
Hello
I have exactly the same problem with web checkip.
ddclient hangs at :
CONNECT: checkip.dyndns.org
CONNECTED: using HTTP
SENDING: GET / HTTP/1.0
SENDING: Host: checkip.dyndns.org
SENDING: User-Agent: ddclient/3.7.3
SENDING: Connection: close
SENDING:
I tried to modify the script with
local $SIG{'ALRM'} = sub { $timeout = 1; close($sd);};
but I have a segfault after timeout (20s) and ddclient daemon crashes :
Aug 16 07:41:53 videosurvey ddclient[8215]: CONNECT: checkip.dyndns.org
Aug 16 07:41:54 videosurvey ddclient[8215]: CONNECTED: using HTTP
Aug 16 07:41:54 videosurvey ddclient[8215]: SENDING: GET / HTTP/1.0
Aug 16 07:41:54 videosurvey ddclient[8215]: SENDING: Host:
checkip.dyndns.org
Aug 16 07:41:54 videosurvey ddclient[8215]: SENDING: User-Agent:
ddclient/3.7.3
Aug 16 07:41:54 videosurvey ddclient[8215]: SENDING: Connection: close
Aug 16 07:41:54 videosurvey ddclient[8215]: SENDING:
Aug 16 07:42:14 videosurvey kernel: ddclient[8215]: segfault at 8 ip
002abf9c sp bfdb7a70 error 6 in libperl.so[101000+257000]
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=676128&aid=2113169&group_id=116817
|