Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.

Bug 1290589

Summary: ship sysctl file enabling vm.allocate_pgste for s390x kvm
Product: [Fedora] Fedora Reporter: Jan Stodola <jstodola>
Component: qemuAssignee: Fedora Virtualization Maintainers <virt-maint>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: medium    
Version: 23CC: agedosier, amit.shah, berrange, cfergeau, clalancette, crobinso, dan, dwmw2, itamar, jforbes, laine, libvirt-maint, pbonzini, rjones, veillard, virt-maint
Target Milestone: ---   
Target Release: ---   
Hardware: s390x   
OS: Linux   
Whiteboard:
Fixed In Version: qemu-2.4.1-9.fc23 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-05-15 05:27:51 UTC Type: Bug
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:    
Bug Blocks: 467765    
Attachments:
Description Flags
fedora23_install.xml none

Description Jan Stodola 2015-12-10 21:33:09 UTC
Description of problem:
An attempt to start a VM on an s390x host fails with the following error:

[root@rtt8 ~]# virsh start fedora23 --console
error: Failed to start domain fedora23
error: internal error: early end of file from monitor: possible problem:
ioctl(KVM_CREATE_VM) failed: 22 Invalid argument
Host kernel setup problem detected. Please verify:
- for kernels supporting the switch_amode or user_mode parameters, whether
  user space is running in primary address space
- for kernels supporting the vm.allocate_pgste sysctl, whether it is enabled
failed to initialize KVM: Invalid argument

"sysctl vm.allocate_pgste=1" fixes this issue, but this should be set automatically, not by the user.


Version-Release number of selected component (if applicable):
kernel-4.2.6-300.fc23.s390x
libvirt-1.2.18.1-2.fc23.s390x
qemu-kvm-2.4.1-1.fc23.s390x

How reproducible:
always

Steps to Reproduce:
1. prepare an XML definition of a virtual machine (will be attached)
2. 
dnf install libvirt qemu-kvm
systemctl start libvirtd
cd /var/lib/libvirt/images/
qemu-img create -f qcow2 fedora23.img 6G
wget http://dl.fedoraproject.org/pub/fedora-secondary/releases/23/Server/s390x/os/images/kernel.img
wget http://dl.fedoraproject.org/pub/fedora-secondary/releases/23/Server/s390x/os/images/initrd.img
modprobe kvm
virsh define fedora23_install.xml
virsh start fedora23 --console

Actual results:
error: Failed to start domain fedora23
error: internal error: early end of file from monitor: possible problem:
ioctl(KVM_CREATE_VM) failed: 22 Invalid argument

Expected results:
VM starts

Comment 1 Jan Stodola 2015-12-10 21:34:33 UTC
Created attachment 1104493 [details]
fedora23_install.xml

For additional info see the following thread:
https://www.mail-archive.com/kvm@vger.kernel.org/msg115576.html

Comment 2 Cole Robinson 2015-12-24 00:18:48 UTC
heh and I even replied to that thread in april but completely forgot about it. Fix is to ship the sysctl file in the qemu-kvm package for s390x arch

Comment 3 Cole Robinson 2016-05-02 20:16:29 UTC
This change was made in f24 but still need to backport it to f23 package

Comment 4 Fedora Update System 2016-05-10 13:59:42 UTC
qemu-2.4.1-9.fc23 has been submitted as an update to Fedora 23. https://bodhi.fedoraproject.org/updates/FEDORA-2016-f2b1f07256

Comment 5 Fedora Update System 2016-05-12 09:35:41 UTC
qemu-2.4.1-9.fc23 has been pushed to the Fedora 23 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-f2b1f07256

Comment 6 Fedora Update System 2016-05-15 05:25:18 UTC
qemu-2.4.1-9.fc23 has been pushed to the Fedora 23 stable repository. If problems still persist, please make note of it in this bug report.