Use SO_KEEPALIVE to avoid disconnects