Re: SO_KEEPALIVE question
Re: SO_KEEPALIVE question
- Subject: Re: SO_KEEPALIVE question
- From: Vincent Lubet <email@hidden>
- Date: Wed, 28 Mar 2007 16:10:03 -0700
Dave,
SO_KEEPALIVE is not a system wide setting, but a per socket options.
To set the timer to 5 minutes you have to set SO_KEEPALIVE to 1 and
set TCP_KEEPALIVE to 600 (the unit is half a second)
Vincent
On Mar 28, 2007, at 3:51 PM, Dave Camp wrote:
I'm porting some code from Windows that uses the Windows equivalent
of ioctl to set the keepalive time for a TCP connection to 5
minutes. The usage in this case is an HTTP connection back to a
internet backup server. The client app is backing up files from the
users machine via HTTP (presumably because HTTP almost always makes
it through the firewall).
Looking through the Stevens UNP book, the closest thing I see is
SO_KEEPALIVE which is noted to be a system wide setting instead of
a per-socket setting.
I also see some flamewars in the list archives about the use of
this setting. :-)
What is the proper thing to do here? ifdef out that section of
code? Is there an equivalent setting I've missed?
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Macnetworkprog mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden