Bug 804019

Summary: Guest reboot instead of suspend during implementing S3 with virtio scsi disk
Product: Red Hat Enterprise Linux 6 Reporter: Qunfang Zhang <qzhang>
Component: kernelAssignee: Paolo Bonzini <pbonzini>
Status: CLOSED CURRENTRELEASE QA Contact: Virtualization Bugs <virt-bugs>
Severity: medium Docs Contact:
Priority: medium    
Version: 6.3CC: acathrow, amit.shah, areis, bsarathy, juzhang, michen, mkenneth, pbonzini, virt-maint, wdai
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-06-20 15:12:46 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 788942, 802127, 803187, 804493    
Bug Blocks: 832177, 833566    
Attachments:
Description Flags
Serial log of the guest when hitting the problem none

Description Qunfang Zhang 2012-03-16 10:32:30 UTC
Description of problem:
Suspend guest to mem with virtio scsi disk, guest reboot instead of suspend. 
I disabled "-kvmclock" to avoid bug 803132. And I only hit this problem once after more than 20 times attempts.

I got the guest serial output when hitting the problem. Please check the attachment.

Version-Release number of selected component (if applicable):
Host:
kernel-2.6.32-251.el6.x86_64
qemu-kvm-0.12.1.2-2.246.el6.x86_64
Guest:
kernel-2.6.32-251.el6.x86_64

How reproducible:
1/20 

Steps to Reproduce:
1. Boot guest with virtio scsi disk and disable kvmclock to avoid bug 803132.
 /usr/libexec/qemu-kvm -M rhel6.3.0 -cpu Conroe,-kvmclock -enable-kvm -m 4G -smp 2,sockets=1,cores=2,threads=1 -name rhel6.3 -uuid 4c84db67-faf8-4498-9829-19a3d6431d9d -rtc base=localtime,driftfix=slew -drive file=/home/rhel6.3-64.raw,if=none,format=raw,id=scsi0 -device virtio-scsi-pci,id=scsi0 -device scsi-hd,drive=scsi0 -netdev tap,id=hostnet0,script=/etc/qemu-ifup -device e1000,netdev=hostnet0,id=net0,mac=00:1a:2a:42:10:66,bus=pci.0 -usb -device usb-tablet,id=input0 -boot c -monitor stdio -qmp tcp:0:4444,server,nowait -chardev socket,id=charserial0,path=/tmp/qzhang-isa,server,nowait -device isa-serial,chardev=charserial0,id=serial0 -drive file=/home/boot.iso,if=none,media=cdrom,id=drive-ide0-1-0,readonly=on,format=raw -device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 -spice port=5930,disable-ticketing -vga qxl -global qxl-vga.vram_size=33554432

2.Inside guest :#pm-suspend or #echo mem > /sys/power/state

3.Resume guest and repeat step 2.
  
Actual results:
Guest reboot.

Expected results:
Guest should suspend and resume successfully.

Additional info:

Comment 1 Qunfang Zhang 2012-03-16 10:33:14 UTC
Created attachment 570560 [details]
Serial log of the guest when hitting the problem

Comment 3 Paolo Bonzini 2012-03-16 17:10:30 UTC
Likely a dup of bug 802127.

Comment 4 Ademar Reis 2012-06-19 18:48:05 UTC
(In reply to comment #3)
> Likely a dup of bug 802127.

Could someone from QA please confirm if this is still reproduced with latest RHEL6.3 (Bug 802127 has been verified)? Thanks.

Comment 5 daiwei 2012-06-20 05:20:20 UTC
Test this issue with the same steps in comment 0 and the following configuration:

# uname -r;rpm -q qemu-kvm
2.6.32-279.el6.x86_64
qemu-kvm-0.12.1.2-2.295.el6.x86_64


1. Boot guest with virtio scsi disk and disable kvmclock to avoid bug 803132.
/usr/libexec/qemu-kvm -M rhel6.3.0 -cpu Conroe,-kvmclock -enable-kvm -m 4G -smp 2,sockets=1,cores=2,threads=1 -name rhel6.3 -uuid 4c84db67-faf8-4498-9829-19a3d6431d9d -rtc base=localtime,driftfix=slew -drive file=/home/rhel6.3-64.raw,if=none,format=raw,id=scsi0 -device virtio-scsi-pci,id=scsi0 -device scsi-hd,drive=scsi0 -netdev tap,id=hostnet0,script=/etc/qemu-ifup -device e1000,netdev=hostnet0,id=net0,mac=00:1a:2a:42:10:66,bus=pci.0 -usb -device usb-tablet,id=input0 -boot c -monitor stdio -qmp tcp:0:4444,server,nowait -chardev socket,id=charserial0,path=/tmp/qzhang-isa,server,nowait -device isa-serial,chardev=charserial0,id=serial0 -drive file=/home/boot.iso,if=none,media=cdrom,id=drive-ide0-1-0,readonly=on,format=raw -device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 -spice port=5930,disable-ticketing -vga qxl -global qxl-vga.vram_size=33554432 -bios /usr/share/seabios/bios-pm.bin

2.Inside guest :#pm-suspend or #echo mem > /sys/power/state
  wakeup guest by command system_wakeup or press any key.

3.Repeat step 2 more than 100 times

After step 3, guest can suspend and resume successfully.