Skip to content

Reduce space and archive size requirements

Dalton Durst requested to merge reduce-space-use into master

These changes make our rootfs building process a little more modular and a little more efficient. Each commit is worthwhile to have in history. I will rebase and merge.

I've packaged linux-firmware-rtlwifi, which is far smaller than the entire linux-firmware package. We don't need all of linux-firmware. We don't even need the entire rtlwifi directory. It's only useful on 8723cs-using Pine64 devices anyway, but the size is now negligible enough to provide it on all Pine64 devices. This saves about 500MB.

I've also packaged linux-firmware-pine64-rtl8723-bt correctly. It no longer needs to be provided in this repository.

Removing linux-image-dbg saved another 600MB.

I've moved the common post-processing tasks between all image builds to a 'polish.yaml' file. Good for not repeating ourselves. This file also deletes the apt package archives before shipping the rootfs. Saves about 30MB.

Overall, this reduces our gzip image archives by about 100MB. But then I disabled gzipping.

I found that using xz -1 only takes 1.5x the CPU time of pigz while producing archives that are at least 100MB smaller without a noticeable difference in decompression time. The gains after that diminish rapidly, but 100MB less per rootfs download will certainly make our server provider happy.

All of the time and space benchmarks for compression were done after the 1100MB rootfs size reduction. So, overall, this will reduce our compressed PinePhone image by 200MB (100MB as a gzip archive, then a further 100MB by replacing gzip with xz).

Please only approve this and allow me to merge. I need to change our Jenkins jobs to run 'xz' so we don't have people downloading 4GB image files.

Edited by Dalton Durst

Merge request reports