On Thu, Jul 09, 2020 at 11:49:17AM +0300, Vladimir Sementsov-Ogievskiy wrote: > 09.07.2020 11:29, Daniel P. Berrangé wrote: > > On Wed, Jul 08, 2020 at 10:15:39PM +0300, Vladimir Sementsov-Ogievskiy > > wrote: > > > Keep-alive won't hurt, let's try to enable it even if not requested by > > > user. > > > > Keep-alive intentionally breaks TCP connections earlier than normal > > in face of transient networking problems. > > > > The question is more about which type of pain is more desirable. A > > stall in the network connection (for a potentially very long time), > > or an intentionally broken socket. > > > > I'm not at all convinced it is a good idea to intentionally break > > /all/ QEMU sockets in the face of transient problems, even if the > > problems last for 2 hours or more. > > > > I could see keep-alives being ok on some QEMU socket. For example > > VNC/SPICE clients, as there is no downside to proactively culling > > them as they can trivially reconnect. Migration too is quite > > reasonable to use keep alives, as you generally want migration to > > run to completion in a short amount of time, and aborting migration > > needs to be safe no matter what. > > > > Breaking chardevs or block devices or network devices that use > > QEMU sockets though will be disruptive. The only solution once > > those backends have a dead socket is going to be to kill QEMU > > and cold-boot the VM again. > > > > Reasonable, thanks for explanation. > > We are mostly interested in keep-alive for migration and NBD connections. > (NBD driver has ability to reconnect). What do you think about setting > keep-alive (with some KEEPIDLE smaller than 2 hours) by default for > migration and NBD (at least when NBD reconnect is enabled), would it be > valid?
I think it should be reasonable to set by default for those particular scenarios, as both are expecting failures and ready to take action when they occur. Regards, Daniel -- |: https://berrange.com -o- https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o- https://fstop138.berrange.com :| |: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|