
On 09/09/15 18:58 +0800, Nick Xiao wrote:
In my environment i want to use ovirt-ga replace qemu-ga. Hypervisor is Ubuntu 14.04 (OpenStack Icehouse) and the virtual machine is Ubuntu 14.04 cloudimage.
In Hypervisor launch a instance and attach a chardev, like: # ps -ef | grep guest_agent libvirt+ 2649 1 1 Sep08 ? 00:15:36 /usr/bin/qemu-system-x86_64 ... -chardev socket,id=charchannel0,path=/var/lib/libvirt/qemu/org.qemu.guest_agent.0.instance-00000210.sock,server,nowait -device virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=org.qemu.guest_agent.0 ...
In virtual machine was installed ovirt-guest-agent 1.0.11-1.1 and service running OK.
But i don't know how to get memory usage and other information in hypervisor(OpenStack compute node)? I have failed when i try to use linux command 'socat' and python socket.
I need some sample or link.
I took a look at the libvirt domain XML from one of my running oVirt VMs and found the following device: <channel type='unix'> <source mode='bind' path='/var/lib/libvirt/qemu/channels/14182ea9-c01f-428d-ac67-5a7e2639c931.com.redhat.rhevm.vdsm'/> <target type='virtio' name='com.redhat.rhevm.vdsm' state='disconnected'/> <alias name='channel0'/> <address type='virtio-serial' controller='0' bus='0' port='1'/> </channel> You might try adding this to your VM. I'm almost certain that ovirt-ga searches for a device with the name 'com.redhat.rhevm.vdsm' when starting up. Once you are connected, take a look at vdsm/virt/guestagent.py in the vdsm source code for hints about how to talk to the agent. -- Adam Litke