Hide Forgot
Description of problem: Can't remove a rng device when the guest is running sometimes. Version-Release number of selected component (if applicable): virt-manager-1.3.2-1.el7.noarch libvirt-1.3.3-2.el7.x86_64 How reproducible: 50% Steps to Reproduce: 1. Prepare a shut off guest without rng device. 2. Running the guest and prepare a rng xml. # cat rng.xml <rng model="virtio"> <backend model="random">/dev/random</backend> </rng> 3.Run "virsh attach-device $guest rng.xml" to attach the rng device to the $guest in Host. # virsh attach-device $guest rng.xml Device attached successfully There will be a rng device in the guest's hardware details. 4.Run "ls /dev|grep hwrng" in the guest. # ls /dev|grep hwrng hwrng 5. Run "virsh detach-device $guest rng.xml" to detach the rng device from the $guest in Host. # virsh detach-device $guest rng.xml Device detached successfully 6. Run "virsh dumpxml $guest|grep -A4 rng" in Host and check if there is the rng device in hardware details of the guest. Actual results: After Step6: 1.#virsh dumpxml $guest|grep -A4 rng <rng model='virtio'> <backend model='random'>/dev/random</backend> <alias name='rng0'/> <address type='pci' domain='0x0000' bus='0x00' slot='0x0b' function='0x0'/> </rng> 2.There is still a rng device in hardware details of the guest . Expected results: 1.#virsh dumpxml $guest|grep -A4 rng 2.The rng device in hardware details of the guest is gone. Additional info: Please try step 3-6 several times if the bug don't reproduce.
Looks like an issue with the RNG device itself since libvirt correctly removes it sometimes. PCI devices require guest cooperation with the guest to eject. Please provide version of qemu and the guest OS that was used. Moving to qemu for further investigation.
(In reply to Peter Krempa from comment #2) > Looks like an issue with the RNG device itself since libvirt correctly > removes it sometimes. PCI devices require guest cooperation with the guest > to eject. > > Please provide version of qemu and the guest OS that was used. > > Moving to qemu for further investigation. Host: qemu-kvm-rhev-2.3.0-31.el7_2.12.x86_64 Guest: kernel-3.10.0-327.el7.x86_64 Red Hat Enterprise Linux Server release 7.2 Thanks.
*** This bug has been marked as a duplicate of bug 1348044 ***