[freetds] [PATCH] Configurable TCP KeepAlives
avictor.za at gmail.com
Mon Aug 11 17:03:39 EDT 2008
> FreeTDS configuration parameters affect the Tabular Data Stream only, not
> the application, and not the underlying communication layer. Non-TDS
> behavior is best controlled by non-TDS tools.
But in the real-world TDS probably runs mostly on TCP, and FreeTDS
only runs on TCP.
> When perfectly good network connections fail without any
> attributable cause in the client or server, ...
It's not necessarily always a network issue - the remote host could be
rebooted or have a power-failure, similar for a stateful router /
The keepalive mechanism has to do with detecting these unexpected
"As an example, under default configuration, SQL Server can detect a
'orphaned' connection in about 35 seconds."
Sybase has similar advice about adjusting the TCP keepalive settings.
> Again, I have no problem exposing the underlying endpoint for manipulation
> by ioctl(2). But, because the keepalive parameters are invisible to TDS
> per se, they should not be configured by the library.
Maybe we can then rather add a [tcp] section to the freetds.conf
The patch only modifies the KeepAlive settings if you add the options
to the configuration file. Don't need them, don't add them.
More information about the FreeTDS