[libvirt] What is the robust/recommended way to retrieve the PID of a VM's init process ?

Eric Blake eblake at redhat.com
Tue Jan 21 13:15:34 UTC 2014


On 01/21/2014 05:20 AM, Thierry Parmentelat wrote:
> Hi again

[once again, please don't top-post on technical lists]

> 
> So I did give this interesting lxc-enter-namespace feature a try 

Thank you.

> 
> So my comments are, 
> - first that defining some even minimal PATH would help;

PATH relative to the container?  Yes, that might be a nice addition;
would you like to propose the means of passing that information through
to the child?

> - and second that in this first form, it would be great if virsh could write some error on stderr instead of being almost totally silent, it took me some time to figure that it kind of worked
> Does this mean we would lose any message sent on stderr ? 

No, stderr is preserved.  But I have patches awaiting review that make
the process nicer, including informing you of any non-zero exit status
of the executed command:
https://www.redhat.com/archives/libvir-list/2013-December/msg01247.html

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 604 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20140121/d4efbd1e/attachment-0001.sig>


More information about the libvir-list mailing list