On 7/9/20 3:35 AM, Daniel P. Berrangé wrote:
On Wed, Jul 08, 2020 at 10:15:37PM +0300, Vladimir Sementsov-Ogievskiy wrote:
Hi all!
We understood, that keepalive is almost superfluous with default 2 hours
in /proc/tcp_keepalive_time. Forcing user to setup keepalive for the
whole system doesn't seem right, better setup it per-socket.
Adding the ability to explicitly configure the keepalive settings makes
sense for QEMU. Completely ignoring system defaults when no explicit
settings are given though is not valid IMHO.
We already have the ability to add per-socket keepalive (see commit
aec21d3175, in 4.2). I guess what you are trying to further do is
determine whether the default value for that field, when not explicitly
specified by the user, can have saner semantics (default off for chardev
sockets, default on for nbd clients where retry was enabled). But since
you already have to explicitly opt-in to nbd retry, what's so hard about
opting in to keepalive at the same time, other than more typing? Given
that the easiest way to do this is via a machine-coded generation of the
command line or QMP command, it doesn't seem that hard to just keep
things as they are with explicit opt-in to per-socket keepalive.
--
Eric Blake, Principal Software Engineer
Red Hat, Inc. +1-919-301-3226
Virtualization: qemu.org | libvirt.org