[CRIU] Name resolved on unconnected socket
Pavel Emelyanov
xemul at parallels.com
Mon Feb 24 05:28:17 PST 2014
On 02/24/2014 05:23 PM, Cyrill Gorcunov wrote:
> On Mon, Feb 24, 2014 at 05:13:55PM +0400, Pavel Emelyanov wrote:
>>>
>>> Well, as far as I know, yes. close-wait is not the state we can safely
>>> ignore. On the other hands restoring such socket in closed state is
>>> not hard. Pavel?
>>
>> Well, CLOSE_WAIT state happens when the peer sends FIN to us, but "us" haven't
>> called close() yet. And for CRIU it's questionable whether it would happen ever,
>> so we should (in theory) handle it.
>>
>> The problem is that in order to properly restore socket in such state we should
>> either patch the kernel's TCP repair engine, or send fake FIN packet to the freshly
>> restored socket, via temporary raw socket. But the latter solution looks too hacky :)
>
> IOW, you propose to enhance kernel's tcp repair engine?
I'd start with the 2nd approach and look what it costs us.
>>
>> And AFAIU the TCP state machine there's no way to workaround this by restoring the
>> socket in ESTABLISHED state. Neither can we restore the socket in CLOSED state.
> .
>
Thanks,
Pavel
More information about the CRIU
mailing list