Subject: Re: persistent/restorable unix procs?
To: None <current-users@NetBSD.ORG>
From: der Mouse <mouse@Collatz.McRCIM.McGill.EDU>
List: current-users
Date: 02/08/1996 18:46:48
[This dates from late November; I'm plowing through backlogged mail.]

> Has anyone done any work on (or looking into) how one might dump a
> process's state to disk & restore it, assuming it's a cooperating
> process?  E.G. maybe you have a process that wants to save itself on
> purpose.

I did this, long ago, on a VAX under 4.3.  As I recall, I punted on the
open-file-descriptor problem, making the relevant syscalls work only if
the calling process has no open file descriptors.  It was done by just
ripping off the core-dump code and I think dumping a little more info,
then hacking severely on exec() to reload the thing....

I've never looked at doing it on any other hardware or under any other
OS.

> To make it harder, how about an uncooperative process?

Forget it, is my opinion.  There's too much state that can't be saved,
primarily open file descriptors.  (Not just open files - they could be
connected to pipes or network connections or any of a number of
things.)

					der Mouse

			    mouse@collatz.mcrcim.mcgill.edu