Hi Keith, Martin

Thanks for reviewing the changes.
I have modified the changes as suggested.With the current changes wget will try for 10 times waiting for around 10 min before it finally gives up.

Webrev : http://cr.opensolaris.org/~nirmal27/7013796/

I have done unit test with options waitretry, tries and timout. In my test case  wget exits in 5 min and 10 sec as expected.


Thanks
Nirmal



Test case output :
------------------------
 $ time wget  --waitretry=5 --tries=5 --timeout=60 129.158.212.1
21
--2011-05-05 14:50:17--  http://129.158.212.121/
Connecting to 129.158.212.121:80... failed: Connection timed out.
Retrying.

--2011-05-05 14:51:18--  (try: 2)  http://129.158.212.121/
Connecting to 129.158.212.121:80... failed: Connection timed out.
Retrying.

--2011-05-05 14:52:21--  (try: 3)  http://129.158.212.121/
Connecting to 129.158.212.121:80... failed: Connection timed out.
Retrying.

--2011-05-05 14:53:24--  (try: 4)  http://129.158.212.121/
Connecting to 129.158.212.121:80... failed: Connection timed out.
Retrying.

--2011-05-05 14:54:28--  (try: 5)  http://129.158.212.121/
Connecting to 129.158.212.121:80... failed: Connection timed out.
Giving up.


real    5m10.054s
user    0m0.002s
sys     0m0.005s
---------------------------------------------------------------------------------------------------------------------------------------------------------------

On 05/04/11 23:25, Martin Widjaja wrote:
Keith - The only thing I am worried about just setting --read-timeout and --connect-timeout is there might be other timeout that's covered by the overall --timeout that may not get set and left to the default wget value of - what is it - 900 sec? If that happens to be the case, then the issue will come back... intermittently.
Other than that, I agree with the rest of the review comments.

Additionally, I noticed the sleep was just removed altogether, but I thought there might be advantage in waiting/sleeping before next retry. Having a static sleep is probably not desireable though, so there is probably advantage in also using --waitretry feature of wget? It sounds like we can reduce the timeout a bit by letting wget incrementally add sleep seconds between retries.

Martin

On 5/4/2011 9:04 AM, Keith Mitchell wrote:
Hi Nirmal,

The CR says that the total timeout should be around 10 minutes. Since TIMEOUT and TRIES on lines 54-55 are unchanged, it looks like it will still end up with 900 sec (15 min) timeouts, and attempting them 20 times, for a total of 5 hours of waiting if the file can't be retrieved.

I imagine the value for TIMEOUT should be closer to 60 seconds, and maybe the parameter to wget should be --read-timeout, not an overall --timeout (--connect-timeout may be valuable to set as well). TRIES can be 20 still, though maybe 10 is sufficient.

- Keith

On 05/ 4/11 05:40 AM, Nirmal Agarwal wrote:
Hi all

Please do a code review of the change for:

7013796 AI shouldn't have a 10 hour timeout when wget'ing files.

Webrev Location :

http://cr.opensolaris.org/~nirmal27/CR7013796/

I have created image using dc and tested it. It works fine.

Thanks,
Nirmal

--
Sun,
              an Oracle company
Sun, an Oracle Company
Nirmal Agarwal
Solaris Install Group
Revenue Product Engineering (RPE), Systems 
|Bangalore |
Green
                Oracle Oracle is committed to developing practices and products that help protect the environment
_______________________________________________ caiman-discuss mailing list [email protected] http://mail.opensolaris.org/mailman/listinfo/caiman-discuss

_______________________________________________ caiman-discuss mailing list [email protected] http://mail.opensolaris.org/mailman/listinfo/caiman-discuss
_______________________________________________ caiman-discuss mailing list [email protected] http://mail.opensolaris.org/mailman/listinfo/caiman-discuss


--
Sun, an
        Oracle company
Sun, an Oracle Company
Nirmal Agarwal
Solaris Install Group
Revenue Product Engineering (RPE), Systems 
|Bangalore |
Green
          Oracle Oracle is committed to developing practices and products that help protect the environment

_______________________________________________
caiman-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/caiman-discuss

Reply via email to