Bug 606953

Summary: fork causes trouble for vcpu threads
Product: Red Hat Enterprise Linux 5 Reporter: Glauber Costa <gcosta>
Component: kvmAssignee: Virtualization Maintenance <virt-maint>
Status: CLOSED ERRATA QA Contact: Virtualization Bugs <virt-bugs>
Severity: medium Docs Contact:
Priority: high    
Version: 5.5CC: armbru, ehabkost, gcosta, kcao, kraxel, llim, mkenneth, tburke, virt-maint, ykaul
Target Milestone: rcKeywords: ZStream
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: kvm-83-186.el5 Doc Type: Bug Fix
Doc Text:
In the kvm kernel module, some internal KVM memory slots were incorrectly being handled by copy-on-write after a fork() function call, which caused issues when qemu-kvm ran child processes. This update fixes the handling of internal KVM memory slots on fork() to avoid those issues.
Story Points: ---
Clone Of: 601192 Environment:
Last Closed: 2011-01-13 23:36:34 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
Bug Depends On: 601192    
Bug Blocks: 580949, 610341    

Comment 7 Douglas Silas 2010-07-28 15:39:58 UTC
Technical note added. If any revisions are required, please edit the "Technical Notes" field
accordingly. All revisions will be proofread by the Engineering Content Services team.

New Contents:
In the kvm kernel module, some internal KVM memory slots were incorrectly being handled by copy-on-write after a fork() function call, which caused issues when qemu-kvm ran child processes. This update fixes the handling of internal KVM memory slots on fork() to avoid those issues.

Comment 9 Cao, Chen 2010-11-11 10:13:58 UTC
verified on
# rpm -q kvm
kvm-83-207.el5


boot guest with:
/usr/libexec/qemu-kvm -name 'vm1' -monitor stdio -drive file='/home/autotest-devel/client/tests/kvm/images/win2008-64-virtio.qcow2',index=0,if=virtio,media=disk,cache=none,boot=on,format=qcow2 -net nic,vlan=0,model=virtio,macaddr='9a:30:70:9c:34:b4' -net tap,vlan=0,ifname='virtio_xxx_5900',script='/home/autotest-devel/client/tests/kvm/scripts/qemu-ifup-switch',downscript='no' -m 2048 -smp 2 -soundhw ac97 -vnc :0  -rtc-td-hack -M rhel5.6.0 -usbdevice tablet

migrate with:
migrate "exec:gzip -c > /home/mig-xxxx1"

boot the dst guest with:
/usr/libexec/qemu-kvm -name 'vm1' -monitor stdio -drive file='/home/autotest-devel/client/tests/kvm/images/win2008-64-virtio.qcow2',index=0,if=virtio,media=disk,cache=none,boot=on,format=qcow2 -net nic,vlan=0,model=virtio,macaddr='9a:30:70:9c:34:b4' -net tap,vlan=0,ifname='virtio_xxx_5900',script='/home/autotest-devel/client/tests/kvm/scripts/qemu-ifup-switch',downscript='no' -m 2048 -smp 2 -soundhw ac97 -vnc :0  -rtc-td-hack -M rhel5.6.0 -usbdevice tablet -incoming "exec:gzip -c -d /home/xxxmig"


migration finished good, guest is good, too

Comment 12 errata-xmlrpc 2011-01-13 23:36:34 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHSA-2011-0028.html