performance regression in qemu-user + proot
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
QEMU |
New
|
Undecided
|
Unassigned | ||
qemu (Ubuntu) |
New
|
Undecided
|
Unassigned |
Bug Description
To reproduce:
1. Install qemu-user-static and proot
2. Enter some arm chroot using them:
proot -0 -q qemu-arm-static -w / -r chroot/ /bin/bash
3. Run a command which normally takes a short but measurable amount of time:
cd /usr/share/doc && time grep -R hello
Result:
This is over 100 times slower on 18.04 than it was on 16.04. I am not sure if proot or qemu is causing the problem, but proot version has not changed. Also note that on 16.04 I am using the cloud repo version of qemu, which is newer than 16.04 stock, but still older than 18.04.
Although system 2 is lower spec than system 1, it should not be this much slower. No other software seems to be affected.
If required I can supply a chroot tarball. It is essentially just a Debian bootstrap though.
Logs:
System 1: i7-6700 3.4GHz, 32GB RAM, 512GB Crucial MX100 SSD, Ubuntu 16.04
qemu-arm version 2.10.1(Debian 1:2.10+
proot 5.1.0
al@al-desktop:
root@al-desktop:/# cd /usr/share/doc
root@al-
dash/copyright:
real 0m0.066s
user 0m0.040s
sys 0m0.008s
System 2: i5-5300U 2.30GHz, 8GB RAM, 256GB Crucial MX300 SSD, Ubuntu 18.04
qemu-arm version 2.11.1(Debian 1:2.11+
proot 5.1.0
al@al-thinkpad:
root@al-thinkpad:/# cd /usr/share/doc
root@al-
dash/copyright:
real 0m24.176s
user 0m0.366s
sys 0m11.352s
ProblemType: Bug
DistroRelease: Ubuntu 18.04
Package: qemu (not installed)
ProcVersionSign
Uname: Linux 4.15.0-12-generic x86_64
ApportVersion: 2.20.8-0ubuntu10
Architecture: amd64
Date: Mon Mar 19 07:13:25 2018
InstallationDate: Installed on 2018-03-18 (0 days ago)
InstallationMedia: Xubuntu 18.04 LTS "Bionic Beaver" - Alpha amd64 (20180318)
SourcePackage: qemu
UpgradeStatus: No upgrade log present (probably fresh install)
Also, I noticed this while running a script that normally takes 12 minutes. After 12 hours I killed it. It never stopped advancing or threw any errors. It was just excruciatingly slow the whole time.
That script builds chroots and can be found here: https:/ /github. com/ali1234/ rpi-ramdisk