Hide Forgot
Description of problem: Install rhel5.6 domain guest failed,with error"TCP/IP error: vnc connection to hypervisor hsot got fefused or disconnected". My test host os tree is :http://download.englab.nay.redhat.com/pub/rhel/rel-eng/RHEL5.7-Server-20110413.1/tree-x86_64/ Version-Release number of selected component (if applicable): libvirt-0.8.2-18.el5 xen-3.0.3-127.el5 kernel-xen-2.6.18-256.el5 How reproducible: 5/5 Steps to Reproduce: 1.#cat cdrom.xml <domain type='xen'> <name>cdrom</name> <uuid>bd95c210-2541-b313-5e09-36f064ace782</uuid> <memory>524288</memory> <currentMemory>524288</currentMemory> <vcpu>1</vcpu> <os> <type arch='x86_64' machine='xenfv'>hvm</type> <loader>/usr/lib/xen/boot/hvmloader</loader> <boot dev='cdrom'/> </os> <features> <acpi/> <apic/> <pae/> </features> <clock offset='utc'/> <on_poweroff>destroy</on_poweroff> <on_reboot>restart</on_reboot> <on_crash>restart</on_crash> <devices> <emulator>/usr/lib64/xen/bin/qemu-dm</emulator> <disk type='file' device='disk'> <driver name='file'/> <source file='/var/lib/xen/images/cdrom.img'/> <target dev='hda' bus='ide'/> </disk> <disk type='block' device='cdrom'> <driver name='phy'/> <source dev='/dev/sr0'/> <target dev='hdc' bus='ide'/> <readonly/> </disk> <interface type='bridge'> <mac address='00:16:36:0b:77:f1'/> <source bridge='virbr0'/> <script path='vif-bridge'/> <target dev='vif11.0'/> </interface> <serial type='pty'> <target port='0'/> </serial> <console type='pty'> <target port='0'/> </console> <input type='mouse' bus='ps2'/> <graphics type='vnc' port='-1' autoport='yes' keymap='en-us'/> </devices> </domain> 2.Create image # qemu-img create /var/lib/xen/images/cdrom.img 6G 3.Define and start rhel5.6 domain guest. # virsh define test.xml Domain cdrom defined from test.xml # virsh start cdrom Domain cdrom started 4.Use virt-manager to finished install. Actual results: Install rhel5.6 domain guest failed,with error"TCP/IP error: vnc connection to hypervisor hsot got fefused or disconnected" Expected results: Domain install should be successful. Additional info: Use Virt-manager to install rhel5.6 guest from cdrom: Steps: 1.New->forward and input VM name 'cdrom' 2.Select Fully virtualized 3.Select form cdrom to install a Linux rhel5.6 domain guest. 4.Select cdrom or DVD option 5.Click forward with default set to finished. Issue:Install rhel5.6 domain guest failed,with error"TCP/IP error: vnc connection to hypervisor hsot got fefused or disconnected" Note:Install rhel5.6 domain guest from HTTP have the same issue.
Created attachment 495725 [details] Virt-manager log Note messgae log: #tail -f /var/log/messages .................................................... Apr 29 00:07:28 localhost kernel: device vif16.0 left promiscuous mode Apr 29 00:07:28 localhost kernel: virbr0: port 3(vif16.0) entering disabled state 00:16:36:05:b9:e4 Apr 29 00:08:02 localhost dnsmasq[3344]: DHCPREQUEST(virbr0) 192.168.122.99 00:16:36:05:b9:e4 Apr 29 00:08:02 localhost dnsmasq[3344]: DHCPACK(virbr0) 192.168.122.99 00:16:36:05:b9:e4 Apr 29 00:09:48 localhost kernel: virbr0: port 1(tap0) entering disabled state Apr 29 00:09:48 localhost kernel: virbr0: port 1(tap0) entering disabled state Apr 29 00:09:48 localhost kernel: device tap0 left promiscuous mode Apr 29 00:09:48 localhost kernel: virbr0: port 1(tap0) entering disabled state Virt-manger Log details please sees the attachment. ............................... Thu, 28 Apr 2011 21:58:22 virt-manager 4529] DEBUG (create:736) Install completed [Thu, 28 Apr 2011 21:58:22 virt-manager 4529] DEBUG (manager:485) About to append vm: cdrom [Thu, 28 Apr 2011 21:58:22 virt-manager 4529] DEBUG (manager:469) VM cdrom started [Thu, 28 Apr 2011 21:58:22 virt-manager 4529] DEBUG (details:1205) Trying console login [Thu, 28 Apr 2011 21:58:22 virt-manager 4529] DEBUG (details:1229) Graphics console configured at vnc://127.0.0.1:5909 [Thu, 28 Apr 2011 21:58:22 virt-manager 4529] DEBUG (details:1242) Starting connect process for 127.0.0.1 5909 [Thu, 28 Apr 2011 21:58:22 virt-manager 4529] DEBUG (engine:323) window counter incremented to 3 [Thu, 28 Apr 2011 21:58:22 virt-manager 4529] DEBUG (details:1205) Trying console login [Thu, 28 Apr 2011 21:58:22 virt-manager 4529] DEBUG (details:1229) Graphics console configured at vnc://127.0.0.1:5909 [Thu, 28 Apr 2011 21:58:22 virt-manager 4529] DEBUG (details:1242) Starting connect process for 127.0.0.1 5909 [Thu, 28 Apr 2011 21:58:22 virt-manager 4529] DEBUG (details:1125) VNC initialized [Thu, 28 Apr 2011 22:00:47 virt-manager 4529] DEBUG (details:1111) VNC disconnected ..................................................
Could not reproduce this bug on the following components: libvirt-0.8.2-15.el5 virt-manager-0.6.1-13.el5 kernel-xen-2.6.18-238.el5
Well, I am a bit confused while trying to reproduce this bug. First you define and run 'cdrom' domain via virsh. Right after that you try to define domain with the same name. Virt-manager should really resist here. And it is on my box. And if I change the name of domain in virt-manager, I am still unable to reproduce the bug (running the same versions as you). However, this is marked as libvirt bug, so could you please provide libvirt logs as well? They might give a picture what's going on. Thanks.
So finally I found the right way of reproducing this bug. Although, I believe this is a Xen bug. What is happening here: one start installation, during which xen dies. The qemu-dm process becomes zombie and therefore every attempt to connect to VNC gets rejected (in TCP handsake). However, I was unable to reproduce this with xen-3.0.3-132.el5 (libvirt & kernel stay the same) What is more interesting, libvirt logs do not show any sign of this fail. Virsh does at least. Domain is in 'no state'.
Created attachment 502322 [details] ps_axf ps -axf
Created attachment 502323 [details] qemu-dm.6033.log
Created attachment 502324 [details] qemu-dm.6706.log
Created attachment 502325 [details] xend.log
While trying to reproduce again, xen randomly rebooted (previous PID 6033, new 6706): [root@dhcp-27-62 ~]# netstat -tlnp Active Internet connections (only servers) Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name tcp 0 0 127.0.0.1:5901 0.0.0.0:* LISTEN 6033/qemu-dm [root@dhcp-27-62 ~]# netstat -tlnp Active Internet connections (only servers) Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name tcp 0 0 127.0.0.1:5902 0.0.0.0:* LISTEN 6706/qemu-dm And then I reproduced this bug successfuly. As we can see from attachment 502322 [details] qemu-dm is in Zombie state, thus netstat doesn't show any process listening on localhost for incoming TCP/IP connections.
This looks like problem in guest configuration - qemu gets invalid parameters so it crash. Can you please provide more info on how to reproduce problem?
What about /var/log/xen/qemu-dm.{PID}.log ? Anything relevant there? Michal
(In reply to comment #14) > What about /var/log/xen/qemu-dm.{PID}.log ? Anything relevant there? > > Michal Sorry, overlooked that the qemu-dm is already there. I remember I run into the issue of "inp: bad size 0 0" when I was working on SCSI patchset however this is coming from the do_inp() which emulates the "in" instruction of the CPU as far as I know. Since the size coming there is bogus (zero) then it's failing with this message and dies silently (as can be seen in ioemu/target-i386-dm/helper2.c of the source codes). This means something is emulated the wrong way AFAIK. Michal
Can you please retest with xen-3.0.3-128.el5? Cdrom patches should be reverted in this version so testing should be successfull.
retest it on build: xen-3.0.3-132.el5 libvirt-0.8.2-20.el5 kernel-xen-2.6.18-266.el5 That issue has be reverted successful.