[CRIU] checkpointing xclock failed with Fedora 20: "Can't dump half of stream unix connection"

Pavel Emelyanov xemul at parallels.com
Thu Jan 16 05:12:35 PST 2014


On 01/16/2014 04:40 PM, Andy Johnson wrote:
> Hello,

Hi, Andy!

> I had made this test:
> 1) Ran xclock from a terminal on F20 X86_64 and find its pid, which was 18428.
> 
> 2) Ran the following from a *different* terminal:
>  criu dump -t 18428 --shell-job --ext-unix-sk
> 
> I got this error:
> 
> (00.020250) Error (sk-unix.c:478): Can't dump half of stream unix connection

This means, that xclock opened a stream unix connection to some task, that
you don't take into dump. Most likely this is X-server. You can check this with
the "ss" tool and the "-xanp" options.

> (00.020385) Error (cr-dump.c:1811): Dumping FAILED.
> 
> Many *.img files were created in the folder from which I ran this command, 

Yes, criu generates lots of files. The -D/--images-dir option can be used to 
specify some other dir for this flood :)

> which means work has started for this command.
> 
> My question is: I assume this has to do with Unix sockets. Is there some more
> option which I should pass to the criu command ?

I'm afraid, that in this particular setup -- no. This is generic problem with
X applications :(

We can't dump such an application, as we can't just break this unix connection.
And we can't do this, because if we do, we will have to restore this connection 
back when restoring the xclock, but this cannot be done without knowing the
details of the connection protocol.

There are two possible solutions to it.

First, is if someone who knows the details of X protocol writes a plugin [1] to
CRIU that will help dumping such things.

Second option is to dump X-server too, so that the application-to-server socket
is dumped with both ends. This can be achieved by using VNC server as described 
here [2]

[1] http://criu.org/Plugins
[2] http://criu.org/VNC

Hope that helps.

> should this work on criu 1.0 ? or should this work with the latest
> criu from git ?
> 
> regards,
> Andy

Thanks,
Pavel


More information about the CRIU mailing list