[lxc-devel] Two process on a same namespcae with clone()
Rob Landley
rlandley at parallels.com
Wed Feb 16 13:40:16 UTC 2011
On 02/16/2011 01:25 AM, Maheswara Reddy C - ERS, HCL Tech wrote:
> Hi,
>
> Could someone help me out,
>
> I want to run the two process on same name space, shall it possible
> using the clone()
You call clone with the CLONE_NEW* flags to create a new namespace. And
then you just fork() normally (without those flags) to create additional
processes in that same namespace.
It's a bit like chroot: you do something extra to get in it, and then
children inherit that environment by default.
Rob
P.S. Fix your hilarious legalese .sig.
More information about the lxc-devel
mailing list