Jump to content

[arch-announce] Moving to Zstandard images by default on mkinitcpio


Recommended Posts

securitybreach
Posted
Quote

As linux-lts moved to the 5.10 version, all official kernels of Arch Linux now support zstd compressed initramfs images, so mkinitcpio is switching to zstd compressed images by default with version 30,
which is currently on [testing].

If, for any reason, you are using a kernel version prior to 5.9, make sure to change mkinitcpio.conf COMPRESSION to use one of the compressors supported, like gzip, otherwise you **will not** be able to
boot images generated by mkinitcpio.


https://www.archlinux.org/news/moving-to-zstandard-images-by-default-on-mkinitcpio/

Posted

Well mkinitcpio.conf tells you that gzip is the default compression program used already.

 

Quote

# COMPRESSION
# Use this to compress the initramfs image. By default, gzip compression
# is used.

 

I made zstd the tool to use though,

 

# COMPRESSION
# Use this to compress the initramfs image. By default, gzip compression
# is used. Use 'cat' to create an uncompressed image.
#COMPRESSION="gzip"
#COMPRESSION="bzip2"
#COMPRESSION="lzma"
#COMPRESSION="xz"
#COMPRESSION="lzop"
#COMPRESSION="lz4"
 COMPRESSION="zstd"

# COMPRESSION_OPTIONS
# Additional options for the compressor
#COMPRESSION_OPTIONS=()

 

are there any extra COMPRESSION OPTIONS needed ? 😎

securitybreach
Posted

That is because you were already at version 5.10.x

securitybreach
Posted
1 hour ago, abarbarian said:

I made zstd the tool to use though,

 

Any reason why?

Posted (edited)
22 hours ago, securitybreach said:

 

Any reason why?

 

Well packages are made with zstd now and it is apparently very fast.

 

https://archlinux.org/news/now-using-zstandard-instead-of-xz-for-package-compression/

 

Quote

zstd and xz trade blows in their compression ratio. Recompressing all packages to zstd with our options yields a total ~0.8% increase in package size on all of our packages combined, but the decompression time for all packages saw a ~1300% speedup

 

Arch Linux plans to use zstd as the default compression method  by ddos · March 25, 2019

 

Quote

Over the past few weeks, Arch Linux maintainers have compared different compression algorithms and eventually plan to use zstd instead of the default compression algorithm in devtools.

 

Quote

 

After a series of tests, the Arch team concluded that:

the benefits of `zstd -c -T0 -18 -` over `xz -c -z -` are:
– Massive speed gain in compression
– Massive speed gain in decompression
– Stable, reproducible multithreading
The speed gain in decompression substantially increases pacman’s package installation speed.

While the trade-offs would be:
– Minimal increase in compressed package size
– Increase in memory usage during compression

The required changeset is, i think:
PKGEXT=’.pkg.tar.zst’
COMPRESSZST=(zstd -c -T0 -18 -)

 

 

So with zstd already being used and now this mkinitcpio I thought why not.

 

I wondered if I could put something like ( -T0 -19) in here,


 

# COMPRESSION_OPTIONS
# Additional options for the compressor
#COMPRESSION_OPTIONS=()
COMPRESSION_OPTIONS=(-T0 -19)

 

to get the fastest possible result. 😎

 

Edited by abarbarian

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...