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 1589506 - slow qemu-arm-static
Summary: slow qemu-arm-static
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: qemu
Version: 28
Hardware: x86_64
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Fedora Virtualization Maintainers
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-06-10 10:34 UTC by jhorvath
Modified: 2018-08-24 08:03 UTC (History)
9 users (show)

Fixed In Version: qemu-2.11.2-2.fc28
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-08-24 08:03:14 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description jhorvath 2018-06-10 10:34:09 UTC
chroot using qemu-arm-static on fedora 28 is really slow (i am using chroot scripts to change raspbian image and it's unusable):
[root@localhost ~]# time chroot /mnt/2018-04-18-raspbian-stretch-lite/ /bin/sleep 1
real    0m2.716s
user    0m0.161s
sys     0m1.564s

while on fedora 27 it looks ok and is working fine:
[root@localhost ~]# time chroot /mnt/2018-04-18-raspbian-stretch-lite/ /bin/sleep 1
real    0m1.054s
user    0m0.047s
sys     0m0.006s

some info from fedora 28 (but this is just default F28 instalation with qemu-user-static package installed:

[root@localhost ~]# rpm -qa | grep qemu                                                                                                                                                                                                     
ipxe-roms-qemu-20170710-3.git0600d3ae.fc28.noarch
qemu-common-2.11.1-2.fc28.x86_64
qemu-user-static-2.11.1-2.fc28.x86_64

cat /proc/sys/fs/binfmt_misc/qemu-arm
enabled
interpreter /usr/bin/qemu-arm-static
flags: F
offset 0
magic 7f454c4601010100000000000000000002002800
mask ffffffffffffff000000000000000000feffffff

Steps to Reproduce:
1.install Fedora 28 (Server Edition)
2.install qemu-user-static: dnf install qemu-user-static 
3.download and unpack latest raspbian: wget https://downloads.raspberrypi.org/raspbian_lite_latest
4.use kpartx to map partitions : kpartx -av 2018-04-18-raspbian-stretch-lite.img
5.mount root partition : mount /dev/mapper/loop0p2 /mnt/2018-04-18-raspbian-stretch-lite/
6.test it : time chroot /mnt/2018-04-18-raspbian-stretch-lite/ /bin/sleep 1

if you execute the same steps on fedora 27 the chroot commands are not affected by big delay as you can see from the output above


if you need some additional output or tests please let me know

Comment 1 jhorvath 2018-06-11 07:11:37 UTC
switching to qemu-user-static from rawhide fix this issue :
dnf install fedora-repos-rawhide -y
dnf --disablerepo=* --enablerepo=rawhide --releasever=29 upgrade qemu-user-static

so i am now on this version :
rpm -qa | grep qemu-user-static
qemu-user-static-2.12.0-2.fc29.x86_64

isn't related to this bug ? :
https://bugs.launchpad.net/qemu/+bug/1740219
https://lists.nongnu.org/archive/html/qemu-devel/2017-12/msg05236.html

Comment 2 Cole Robinson 2018-06-11 13:05:15 UTC
(In reply to jhorvath from comment #1)
> 
> isn't related to this bug ? :
> https://bugs.launchpad.net/qemu/+bug/1740219
> https://lists.nongnu.org/archive/html/qemu-devel/2017-12/msg05236.html

Sounds like it, thanks for tracking that down! The commit is:

commit 2a53535af471f4bee9d6cb5b363746b8d5ed21dd
Author: Luke Shumaker <lukeshu>
Date:   Thu Dec 28 13:08:13 2017 -0500

    linux-user: init_guest_space: Try to make ARM space+commpage continuous

Comment 3 Fedora Update System 2018-07-31 22:39:40 UTC
qemu-2.11.2-2.fc28 has been submitted as an update to Fedora 28. https://bodhi.fedoraproject.org/updates/FEDORA-2018-74fb8b257b

Comment 4 Fedora Update System 2018-08-01 18:25:30 UTC
qemu-2.11.2-2.fc28 has been pushed to the Fedora 28 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-2018-74fb8b257b

Comment 5 Fedora Update System 2018-08-24 08:03:14 UTC
qemu-2.11.2-2.fc28 has been pushed to the Fedora 28 stable repository. If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.