<lukass.vacek@seznam.cz>
2014-Mar-26 22:33 UTC
[libvirt-users] Sending command to virtual machine
Hello, I would like to know if there is a way how to execute a command inside of running virDomainPtr. For example call exec command but not on my computer, but on running virtual machine. If there is a way, what needs to be done for it? Thanks for answer!
On 03/26/2014 04:33 PM, lukass.vacek@seznam.cz wrote:> Hello, > I would like to know if there is a way how to execute a command inside of > running virDomainPtr. For example call exec command but not on my computer, > but on running virtual machine. If there is a way, what needs to be done for > it? > Thanks for answer!This same question was asked earlier this week: https://www.redhat.com/archives/libvirt-users/2014-March/msg00149.html Short answer: if you use LXC, then use, 'virsh lxc-enter-namespace' does just that. If you use qemu, then you need to write a patch to qemu's guest agent (not on this mailing list) or use some other agent of your own creation. -- Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org