Switching to to xz -0 from pxz increases compressed raspi2 image size
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
livecd-rootfs (Ubuntu) |
Fix Released
|
Undecided
|
Balint Reczey | ||
Xenial |
Invalid
|
Undecided
|
Balint Reczey |
Bug Description
[Impact]
* Switching from xz -0 to xz (-6) for compression raspi2 image.
[Test Case]
* To test the change install updated livecd-rootfs on armhf and create images setting the following environment variables: ARCH=armhf SUBARCH=raspi2 PROJECT=ubuntu-cpc.
Notice that the xz-compressed rapi2 image is still created with xz's default (-6) compression.
[Regression Potential]
* In case of this change causes regression it would manifest itself as failing build for raspi2, failing build for ubuntu-cpc images or using other compression for raspi2 images than xz -6.
[Original Bug Report Text]
Switching from pxz to xz -0 in LP: #1701132 made the downloadable raspi2 image bigger, ~360MB which is a notable size increase from the original ~250MB while decreasing time the needed for compressing it.
The bigger compressed image is currently downloadable for Artful:
http://
Zesty's image is 232MB:
http://
To find the proper trade-off I ran compression tests on Xenial (xz ignores -T4 there):
https:/
...
rbalint@
-rw-rw-r-- 1 rbalint rbalint 254621780 Nov 16 00:03 ubuntu-
...
-0 -T4 81.56 73.64 1.46 4820 29.27 25.82 0.09 2252 329984
-1 -T4 103.68 95.14 1.67 10800 24.41 22.86 0.12 3180 298060
-2 -T4 134.05 126.22 1.76 18480 22.06 21.65 0.13 4232 286276
-3 -T4 170.57 162.72 1.72 33812 21.62 20.94 0.12 6188 275036
-4 -T4 322.15 317.83 2.10 50284 21.55 21.05 0.07 6136 258684
-5 -T4 407.15 399.93 1.92 97656 21.85 20.50 0.12 10412 247320
-6 -T4 478.64 473.32 1.95 97660 21.92 20.34 0.09 10348 245772
-7 -T4 493.97 485.52 1.99 191692 20.66 20.01 0.08 18548 240192
-8 -T4 512.28 506.08 2.20 380096 22.03 19.58 0.11 34888 229740
-9 -T4 652.71 559.20 4.78 691076 20.57 19.15 0.08 67700 224496
...
The tests on Bionic are still running.
Generating the raspi2 image is not part of autopkgtests at the moment, but may be periodically tested internally often and I can't tell the number of downloads either thus I'm asking for help to pick the proper compression setting for xz.
Looking at the Xenial numbers I believe -3 would result reasonably fast builds with a tolerable increase in size compared to xz -6's results.
Related branches
- Steve Langasek: Approve
-
Diff: 31 lines (+7/-2)2 files modifieddebian/changelog (+6/-1)
live-build/ubuntu-cpc/hooks/040-qcow2-image.binary (+1/-1)
- Steve Langasek: Approve
- Balint Reczey: Abstain
- Dimitri John Ledkov (community): Approve (lgtm)
- Adam Conrad: Pending requested
-
Diff: 191 lines (+36/-21)9 files modifieddebian/changelog (+10/-0)
debian/control (+25/-1)
live-build/ubuntu-cpc/functions (+0/-6)
live-build/ubuntu-cpc/hooks/032-disk-image.binary (+0/-2)
live-build/ubuntu-cpc/hooks/032-root-squashfs.binary (+0/-2)
live-build/ubuntu-cpc/hooks/033-disk-image-uefi.binary (+0/-3)
live-build/ubuntu-cpc/hooks/034-disk-image-ppc64el.binary (+0/-1)
live-build/ubuntu-cpc/hooks/040-qcow2-image.binary (+1/-3)
live-build/ubuntu-cpc/hooks/042-vagrant.binary (+0/-3)
Changed in livecd-rootfs (Ubuntu): | |
status: | New → Triaged |
assignee: | nobody → Balint Reczey (rbalint) |
Changed in livecd-rootfs (Ubuntu Xenial): | |
status: | New → In Progress |
assignee: | nobody → Balint Reczey (rbalint) |
description: | updated |
tags: | added: id-59ff10e7eddaf8d676d43eb3 |
Compr. Threads Wall.t User.t Sys.t Res.t Wall.t User.t Sys.t Res.t Size(kB)
-0 -T1 77.68 68.78 1.10 4916 25.04 23.07 0.14 2516 365040
-1 -T1 100.05 89.72 1.24 11020 21.79 20.07 0.09 3360 322660
-2 -T1 127.23 118.40 1.31 18760 20.88 19.12 0.08 4292 309644
-3 -T1 165.56 160.31 1.30 34060 20.28 18.62 0.10 6388 302344
-4 -T1 257.81 252.85 1.26 50688 19.54 18.20 0.07 6364 284368
-5 -T1 322.24 318.51 1.41 97724 19.51 17.95 0.09 10576 272192
-6 -T1 374.25 366.92 1.39 97568 19.28 17.92 0.11 10664 270496
-7 -T1 389.19 385.40 1.44 191940 18.11 17.61 0.14 18664 266972
-8 -T1 405.00 400.37 1.73 380276 17.41 17.01 0.10 35028 258024
-9 -T1 486.82 436.84 3.08 690076 16.81 16.24 0.13 67888 251436
-0 -T4 37.83 93.87 1.32 25000 24.91 23.35 0.10 2652 368880
-1 -T4 45.74 138.40 1.59 72108 22.46 20.58 0.10 3304 330744
-2 -T4 56.26 175.05 1.86 126880 20.49 19.52 0.10 4440 315876
-3 -T4 68.22 240.02 1.93 235104 20.29 18.84 0.16 6360 307180
-4 -T4 94.85 348.37 2.52 300212 20.71 19.62 0.11 6488 289376
-5 -T4 118.08 435.77 2.88 556820 19.67 18.34 0.13 10580 276576
-6 -T4 133.11 495.87 2.37 556876 18.85 18.30 0.12 10468 274912
...
With -T4 -7 the Bionic VM with 1GB RAM which I tested the combinations in started swapping but probably we would not want to pick a better compression. If so I'll add the missing results.