[systemd-devel] Question about nspawn.c

Stef Bon stefbon at gmail.com
Wed Aug 24 06:43:37 PDT 2011


2011/8/24 Lennart Poettering <lennart at poettering.net>:
> On Wed, 24.08.11 14:38, Stef Bon (stefbon at gmail.com) wrote:
>
>>
>> Please let me explain why I think this is strange to me:
>>
>> in line 713 there is a call to clone, so here the cloned child process
>> has it's own namespace.
>>
>> in line 759 all the submount like proc, dev and sys are done on the
>> directory to change to.
>>
>> in line 775 the mount is done were talking about, using arg_directory
>>
>> A bind mount I can understand, but a move?? Moving the root to
>> arg_directory will overwrite the just
>> created mounts done in line 759?
>
> No, it's the other way round. We move arg_directory to /, so that it
> becomes our new root directory of the namespace.

Ah!
That explains it. I did not see that.
Thanks a lot!

Stef


More information about the systemd-devel mailing list