TCP_KEEPIDLE vs TCPTV_KEEP_IDLE

Richard Sharpe realrichardsharpe at gmail.com
Sun May 5 16:40:44 UTC 2013


Samba currently has a way to set socket parameters from the smb.conf.

This works fine for things like SO_SNDBUF etc, but not so well for the
TCP KeepAlive parameters.

In this area Samba has a Linux bias.

I am looking at adding support for this under FreeBSD.

The simplest way, it seems to me, is to enhance configure to find the
appropriate symbols under FreeBSD (and it might be extendable to
NetBSD etc) and then map them to the Linux symbols:

#ifdef THIS_IS_SOME_SORT_OF_BSD
#define TCP_KEEPIDLE TCPTV_KEEP_IDLE
#endif

However, that does mean that *BSD types would have to know that this
happening because the names you would use in the smb.conf file would
be Linux-specific, and documentation is often woefully incomplete.

Is there a better method?

-- 
Regards,
Richard Sharpe
(何以解憂?唯有杜康。--曹操)


More information about the freebsd-net mailing list