Hi,
I am seeing a problem with a earlier working domain configuration. Here
is the domain xml file. I am not getting the virsh console now. I am
trying this on RHEL 6.0.
Here is the list of steps that I am using:
[root@krm1 test]# virsh define vmtest.xml
Domain vmtest3 defined from vmtest.xml
[root@krm1 test]# virsh start vmtest3
Domain vmtest3 started
[root@krm1 test]# virsh console vmtest3
Connected to domain vmtest3
Escape character is ^]
[root@krm1 test]# virsh dominfo vmtest3
Id: 2
Name: vmtest3
UUID: 2b38ff93-1bc6-c78c-1ed8-ffb936c86dac
OS Type: hvm
State: running
CPU(s): 1
CPU time: 17.3s
Max memory: 524288 kB
Used memory: 524288 kB
Persistent: yes
Autostart: disable
[root@krm1 test]#
The state of the domain shows running. One more thing that i noted was
that qemu-kvm is consuming 100% of the cpu. So not sure if the qemu-kvm
has started properly. I am not sure how to debug the issue. Would
appreciate some help on this.
Some more information:
I have attached following file /var/log/libvirt/qemu/vmtest3.log
Executing the following command on the bash works fine and the VM comes up:
/usr/libexec/qemu-kvm -M rhel6.0.0 -enable-kvm -m 512 -smp 1,sockets=1,cores=1,threads=1
-drive file=/home/bharata/cgroup-scalability/test/test.qcow2 -nographic
While executing the command in the vmtest3.log, the VM does not come at
all.
Here is the domain xml:
<domain type='kvm'>
<name>vmtest3</name>
<memory>524288</memory>
<vcpu>1</vcpu>
<os>
<type arch='i686'>hvm</type>
<boot dev='hd'/>
</os>
<on_poweroff>destroy</on_poweroff>
<on_reboot>restart</on_reboot>
<on_crash>restart</on_crash>
<devices>
<emulator>/usr/libexec/qemu-kvm</emulator>
<disk type='file' device='disk'>
<driver name='qemu' type='qcow2'/>
<source file='/home/bharata/cgroup-scalability/test/test.qcow2'/>
<target dev='hda' bus='ide'/>
</disk>
<serial type='pty'>
<target port='0'/>
</serial>
<console type='pty'>
<target port='0'/>
</console>
</devices>
</domain>
Thanks,
Nikunj
LC_ALL=C PATH=/sbin:/usr/sbin:/bin:/usr/bin /usr/libexec/qemu-kvm -S -M rhel6.0.0 -cpu
qemu32 -enable-kvm -m 512 -smp 1,sockets=1,cores=1,threads=1 -name vmtest3 -uuid
2b38ff93-1bc6-c78c-1ed8-ffb936c86dac -nographic -nodefconfig -nodefaults -chardev
socket,id=monitor,path=/var/lib/libvirt/qemu/vmtest3.monitor,server,nowait -mon
chardev=monitor,mode=control -rtc base=utc -no-acpi -boot c -drive
file=/home/bharata/cgroup-scalability/test/test.qcow2,if=none,id=drive-ide0-0-0,boot=on,format=qcow2
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 -chardev
pty,id=serial0 -device isa-serial,chardev=serial0 -usb -device
virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x2
09:53:22.536: debug : virCgroupNew:493 : New group /libvirt/qemu/vmtest3
09:53:22.536: debug : virCgroupDetect:230 : Detected mount/mapping 0:cpu at /cgroup/cpu in
09:53:22.536: debug : virCgroupDetect:230 : Detected mount/mapping 1:cpuacct at
/cgroup/cpuacct in
09:53:22.536: debug : virCgroupDetect:230 : Detected mount/mapping 2:cpuset at
/cgroup/cpuset in
09:53:22.536: debug : virCgroupDetect:230 : Detected mount/mapping 3:memory at
/cgroup/memory in
09:53:22.536: debug : virCgroupDetect:230 : Detected mount/mapping 4:devices at
/cgroup/devices in
09:53:22.536: debug : virCgroupDetect:230 : Detected mount/mapping 5:freezer at
/cgroup/freezer in
09:53:22.536: debug : virCgroupMakeGroup:451 : Make group /libvirt/qemu/vmtest3
09:53:22.536: debug : virCgroupMakeGroup:463 : Make controller
/cgroup/cpu/libvirt/qemu/vmtest3/
09:53:22.536: debug : virCgroupMakeGroup:463 : Make controller
/cgroup/cpuacct/libvirt/qemu/vmtest3/
09:53:22.536: debug : virCgroupMakeGroup:463 : Make controller
/cgroup/cpuset/libvirt/qemu/vmtest3/
09:53:22.536: debug : virCgroupMakeGroup:463 : Make controller
/cgroup/memory/libvirt/qemu/vmtest3/
09:53:22.536: debug : virCgroupMakeGroup:463 : Make controller
/cgroup/devices/libvirt/qemu/vmtest3/
09:53:22.536: debug : virCgroupMakeGroup:463 : Make controller
/cgroup/freezer/libvirt/qemu/vmtest3/
09:53:22.536: debug : virCgroupSetValueStr:275 : Set value
'/cgroup/cpu/libvirt/qemu/vmtest3/tasks' to '7312'
09:53:22.545: debug : virCgroupSetValueStr:275 : Set value
'/cgroup/cpuacct/libvirt/qemu/vmtest3/tasks' to '7312'
09:53:22.554: debug : virCgroupSetValueStr:275 : Set value
'/cgroup/cpuset/libvirt/qemu/vmtest3/tasks' to '7312'
09:53:22.562: debug : virCgroupSetValueStr:275 : Set value
'/cgroup/memory/libvirt/qemu/vmtest3/tasks' to '7312'
09:53:22.569: debug : virCgroupSetValueStr:275 : Set value
'/cgroup/devices/libvirt/qemu/vmtest3/tasks' to '7312'
09:53:22.577: debug : virCgroupSetValueStr:275 : Set value
'/cgroup/freezer/libvirt/qemu/vmtest3/tasks' to '7312'
09:53:22.585: debug : qemudInitCpuAffinity:2618 : Setting CPU affinity
09:53:22.586: debug : qemuSecurityDACSetProcessLabel:547 : Dropping privileges of VM to
107:107
char device redirected to /dev/pts/2