Hide Forgot
Description of problem: Not able to shutdown the RHEL 7.3 VM by using virsh command. Version-Release number of selected component (if applicable): RHEL 7.3 beta Running guest = 7.3 beta. How reproducible:- 100% Steps to Reproduce: 1.Create new VM on top of RHEL 7.3 with graphical installation. 2.try to shutdown VM by command. # virsh -c qemu:///system shutdown rhel7.3 3. After running above command guest didnt turned off, only screen become black. Actual results:- After running above command guest vm didnt turned off, its screen become black. Expected results: VM should get turned off after running shutdown command. Additional info:
Tested it on rhel7.3 and rhel7.2, rhel7.3 and rhel7.2 can reproduce the issue with guest graphical model. follow are the details 1. Version: rhel7.2: kernel-3.10.0-327.43.1.el7.x86_64 qemu-kvm-1.5.3-105.el7_2.10.x86_64 rhel7.3: kernel-3.10.0-514.1.1.el7.x86_64 qemu-kvm-1.5.3-126.el7.x86_64 2. Test scenario: rhel7.2 qemu-kvm + 7.2 guest (kernel-3.10.0-327.el7.x86_64) rhel7.3 qemu-kvm + 7.2 guest (kernel-3.10.0-327.el7.x86_64) rhel7.3 qemu-kvm + 7.3 guest (kernel-3.10.0-506.el7.x86_64) 3. Test details 1) Boot guest with command[1]; 2) Set guest as graphic model and terminal model : systemctl set-default graphical.target/multi-user.target 3) shutdown guest through "system_powerdown" in hmp 4. Test Result: 1) graphical model: guest didn't turn off and display black screen 2) terminal model: guest can turn off successfully Add info Tried it with virsh cmd (virsh -c qemu:///system shutdown generic) on rhel7.2 host, the same test result with above [1] /usr/libexec/qemu-kvm \ -M pc \ -cpu SandyBridge \ -nodefaults -rtc base=utc \ -m 4G \ -smp 2,sockets=2,cores=1,threads=1 \ -enable-kvm \ -name rhel7.3 \ -uuid 990ea161-6b67-47b2-b803-19fb01d30d12 \ -smbios type=1,manufacturer='Red Hat',product='RHEV Hypervisor',version=el6,serial=koTUXQrb,uuid=feebc8fd-f8b0-4e75-abc3-e63fcdb67170 \ -k en-us \ -serial unix:/tmp/console,server,nowait \ -boot menu=on \ -bios /usr/share/seabios/bios.bin \ -chardev file,path=/home/seabios.log,id=seabios \ -device isa-debugcon,chardev=seabios,iobase=0x402 \ -qmp tcp::8887,server,nowait \ -vga qxl \ -spice port=5932,disable-ticketing \ -drive file=/home/bug/rhel72.img,if=none,id=drive-virtio-disk0,format=qcow2,cache=none,werror=stop,rerror=stop \ -device virtio-blk-pci,drive=drive-virtio-disk0,id=virtio-disk0,bootindex=1 \ -netdev tap,id=hostnet1 \ -device virtio-net-pci,netdev=hostnet1,id=net1,mac=54:52:00:B6:40:22 \ -monitor stdio \ -usb -device usb-mouse,id=mouse \ Thanks Jing Zhao
(In reply to jingzhao from comment #5) > Tested it on rhel7.3 and rhel7.2, rhel7.3 and rhel7.2 can reproduce the > issue with guest graphical model. follow are the details > > 1. Version: > > rhel7.2: > kernel-3.10.0-327.43.1.el7.x86_64 > qemu-kvm-1.5.3-105.el7_2.10.x86_64 > > rhel7.3: > kernel-3.10.0-514.1.1.el7.x86_64 > qemu-kvm-1.5.3-126.el7.x86_64 > > 2. Test scenario: > > rhel7.2 qemu-kvm + 7.2 guest (kernel-3.10.0-327.el7.x86_64) > rhel7.3 qemu-kvm + 7.2 guest (kernel-3.10.0-327.el7.x86_64) > rhel7.3 qemu-kvm + 7.3 guest (kernel-3.10.0-506.el7.x86_64) > > 3. Test details > 1) Boot guest with command[1]; > 2) Set guest as graphic model and terminal model > : systemctl set-default graphical.target/multi-user.target > 3) shutdown guest through "system_powerdown" in hmp > > 4. Test Result: > 1) graphical model: guest didn't turn off and display black screen > 2) terminal model: guest can turn off successfully > > Add info > Tried it with virsh cmd (virsh -c qemu:///system shutdown generic) on > rhel7.2 host, the same test result with above Thanks for the testing, this confirms it's not a regression from 7.2. Can you please run one more test, now with qemu-kvm-rhev?
The same result when tested it with qemu-kvm-rhev Test version: rhel7.2: kernel-3.10.0-327.43.1.el7.x86_64 qemu-kvm-rhev-2.3.0-31.el7_2.23.x86_64 rhel7.3: kernel-3.10.0-514.1.1.el7.x86_64 qemu-kvm-rhev-2.6.0-28.el7.x86_64 Test scenario: rhel7.2 qemu-kvm + 7.2 guest (kernel-3.10.0-327.el7.x86_64) rhel7.3 qemu-kvm + 7.2 guest (kernel-3.10.0-327.el7.x86_64) rhel7.3 qemu-kvm + 7.3 guest (kernel-3.10.0-506.el7.x86_64) Thanks Jing Zhao
May be related to Bug 1394469
please test whenever this seabios test build fixes the issue: http://people.redhat.com/ghoffman/bz1392569/
I think it's not a bug. 'virsh shutdown' use agent mode in default with qemu hypervisor. If not setting guest agent, then use acpi mode. To use acpi mode correctly with rhel7.2/rhel7.3 guest(since the default value of "# gsettings get org.gnome.settings-daemon.plugins.power button-power" is "suspend" in rhel7.2/rhel7.3. When running shutdown command by acpi mode,the guest will not shutdown.), it needs to execute the following command in the guest firstly: #gsettings set org.gnome.settings-daemon.plugins.power button-power shutdown The guest can shutdown correctly after executing the command. The guest also can shutdown correctly if setting agent channel in the domain xml and start qemu-guest-agent service in the guest.
(In reply to yafu from comment #10) > I think it's not a bug. 'virsh shutdown' use agent mode in default with qemu > hypervisor. If not setting guest agent, then use acpi mode. To use acpi mode > correctly with rhel7.2/rhel7.3 guest(since the default value of "# gsettings > get org.gnome.settings-daemon.plugins.power button-power" is "suspend" in > rhel7.2/rhel7.3. When running shutdown command by acpi mode,the guest will > not shutdown.), it needs to execute the following command in the guest > firstly: > #gsettings set org.gnome.settings-daemon.plugins.power button-power shutdown > > The guest can shutdown correctly after executing the command. > The guest also can shutdown correctly if setting agent channel in the domain > xml and start qemu-guest-agent service in the guest. Agree. Thanks for the clarification. *** This bug has been marked as a duplicate of bug 1395097 ***