Re: init is pid 1 vs. initrd

Raul Miller (rdm@test.legislate.com)
Fri, 17 Apr 1998 21:51:20 -0400


H. Peter Anvin <hpa@transmeta.com> wrote:
> But you can't do that if the process you're running in is holding the
> old root open. This is why I propose telling the kernel where the
> pivot is, and then exiting (no processes running.)

Why would it be holding the old root open?

Just to re-iterate, I'm envisioning:

...
mount new root
cd /
exec new init
...
free old root
...

True, you can't free up the ram disk if you have some prehistoric
process hanging around. That's a feature, not a bug.

I guess I am expecting to be able to do a little surgery to pull
any references to the old root from any running processes. Basically,
I'm envisioning that each such reference would be replaced with
a reference to the new root, but I don't see why this is dangerous.

-- 
Raul

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu