Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Description of problem:
Virt-install fails when create a guest with --channel parameter
Version-Release number of selected component (if applicable):
virt-manager-0.9.0-15.el6.x86_64
libvirt-0.10.2-4.el6.x86_64
python-virtinst-0.600.0-9.el6.noarch
qemu-kvm-0.12.1.2-2.316.el6.x86_64
kernel-2.6.32-309.el6.x86_64
How reproducible:
100%
Steps to Reproduce:
1.Use virt-install with --channel spicevmc,target_type=virtio,name=com.redhat.spice.0 to install a guest.
# virt-install --name cache --ram 1024 --vcpu=1 --disk path=/var/lib/libvirt/images/cache.img,size=6,cache=writeback --location http://tree.englab.nay.redhat.com/pub/rhel/released/RHEL-6/6.3/Server/x86_64/os/ --graphics spice --video qxl --channel spicevmc,target_type=virtio,name=com.redhat.spice.0
Starting install...
Retrieving file vmlinuz... | 7.6 MB 00:00 ...
Retrieving file initrd.img... | 58 MB 00:00 ...
ERROR internal error process exited while connecting to monitor: char device redirected to /dev/pts/15
qemu-kvm: -device virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=com.redhat.spice.0: virtio-serial-bus: Out-of-range port id specified, max. allowed: 0
qemu-kvm: -device virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=com.redhat.spice.0: Device 'virtserialport' could not be initialized
2.Use virt-install with --channel pty,target_type=virtio,name=org.linux-kvm.port.1 to install a guest.
# virt-install --name cache --ram 1024 --vcpu=1 --disk path=/var/lib/libvirt/images/cache.img,size=6,cache=writeback --location http://tree.englab.nay.redhat.com/pub/rhel/released/RHEL-6/6.3/Server/x86_64/os/ --channel pty,target_type=virtio,name=org.linux-kvm.port.1
Starting install...
Retrieving file vmlinuz... | 7.6 MB 00:00 ...
Retrieving file initrd.img... | 58 MB 00:00 ...
ERROR internal error process exited while connecting to monitor: char device redirected to /dev/pts/15
char device redirected to /dev/pts/16
qemu-kvm: -device virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=org.linux-kvm.port.1: virtio-serial-bus: Out-of-range port id specified, max. allowed: 0
qemu-kvm: -device virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=org.linux-kvm.port.1: Device 'virtserialport' could not be initialized
3.Tried to add the channel in xml,then use virsh to create a guest,it can be created successfully.
<graphics type='spice' autoport='yes' listen='127.0.0.1'>
<listen type='address' address='127.0.0.1'/>
<video>
<model type='qxl' vram='65536' heads='1'/>
<alias name='video0'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
</video>
<channel type='spicevmc'>
<target type='virtio' name='com.redhat.spice.0'/>
<alias name='channel0'/>
<address type='virtio-serial' controller='0' bus='0' port='1'/>
</channel>
Actual results:
virt-install fails when create a guest with --channel parameter.
Expected results:
virt-install can create a guest with --channel parameter successfully..
Additional info:
1.There is a bug:Bug 790745 - [Regression]libvirtd dead when create a guest with "--channel pty,target_type=virtio" by virt-install.
The bug has been fixed on libvirt-0.9.10-2.el6,I've tried libvirt-0.9.10-3.el6,it can be successfully with virt-install with --channel pty,target_type=virtio,name=org.linux-kvm.port.1.
2.When use virt-manager to install a new guest and during installation to add spice channel,the guest will fail with the same error.
3.Attached the debug info.
Tried more times,I found that it is libvirt issues:
version:
virt-manager-0.9.0-15.el6.x86_64
libvirt-0.10.2-4.el6.x86_64
python-virtinst-0.600.0-9.el6.noarch
qemu-kvm-0.12.1.2-2.316.el6.x86_64
kernel-2.6.32-309.el6.x86_64
1.when use virt-manager to create a new guest named channel,it shows in xml as(attached the debug info):
<type arch='x86_64' machine='rhel5.4.0'>hvm</type>
2.After the guest installed,change the graphic type to spice and video as qxl,then add spice channel(attached the xml of the guest)
Start the guest,will get error:
# virsh start channel
error: Failed to start domain channel
error: internal error Process exited while reading console log output: char device redirected to /dev/pts/10
qemu-kvm: -device virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=com.redhat.spice.0: virtio-serial-bus: Out-of-range port id specified, max. allowed: 0
qemu-kvm: -device virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=com.redhat.spice.0: Device 'virtserialport' could not be initialized
3.Change the version in xml from <type arch='x86_64' machine='rhel5.4.0'>hvm</type> to <type arch='x86_64' machine='rhel6.4.0'>hvm</type>,then the guest can boot successfully.
# virsh edit channel
Domain channel XML configuration edited.
# virsh start channel
Domain channel started
As the above steps show,it is not python-virtinst problem,change the component to libvirt,if I am wrong,pls correct.