[Devel] Re: kernel based checkpoint/restart: about X windows application checkpoint and restart support.

Matt Helsley matthltc at us.ibm.com
Wed Oct 28 01:47:17 PDT 2009


On Wed, Oct 28, 2009 at 10:51:32AM +0800, Will Huang wrote:
> Dear All,
> 
>          Did the Kernel based checkpoint/restart patch support X windows
> application such as firefox?

No, and I think it may be a long time before that happens.

(Disclaimer: I haven't even tried to see what part of checkpointing
X breaks first. I suspect it'd be the open device files...)

The display and input device hardware presents a serious challenge for 
one thing. They may not be available during restart if it occurs
on a different machine -- or they may be entirely different hardware. 

Perhaps checkpoint/restart of programs with these devices open should
"simulate" hot-[un]plug. Checkpoint could save enough information to make
the kernel generate the necessary uevents. At restart the file
descriptors for those devices are never opened and syscalls on them will
return errno==EBADF. Next we'd need to send uevents for the
"new-but-not-new" devices. There's a "new-but-not-new" uevent pathway in
the kernel used during boot -- perhaps there's some way to reuse that.
Lastly, we send the unplug uevents to get X to drop its use of the old
devices -- send those last so X always thinks there's hardware.

That's one way it _could_ be done. Others might rely on device
"virtualization" -- writing pseudo-device code (CUSE?).

X also has its own session support. As far as I know how that could
work with kernel-based checkpoint/restart hasn't been discussed yet.

Of course this is all off the top of my head. Others are welcome to
make considerate use of cluebats to inform me of any misconceptions I
may have.

Cheers,
	-Matt Helsley
_______________________________________________
Containers mailing list
Containers at lists.linux-foundation.org
https://lists.linux-foundation.org/mailman/listinfo/containers




More information about the Devel mailing list