[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: XZ compression for the initramfs



On Wed, Jan 6, 2016 at 6:22 AM, Martin Michlmayr <tbm@cyrius.com> wrote:
> * Roger Shimizu <rogershimizu@gmail.com> [2016-01-06 01:01]:
>> I suggest it's better to inform the following in NEWS:
>
> The note I was going to add to release-notes would be QNAP specific
> (not Orion) since they only have 4 MB flash for the ramdisk.
>
> But if initramfs-tools implements the "auto" option Ben mentioned,
> this would be a good addition for initramfs-tools/NEWS (unless it
> defaults to gzip if RAM is smaller than X MB.)

Yes, well understood.
I found previous email wasn't CC Ben and Ian, so I add them to TO/CC
for this email.

>Ben

If you implement auto for COMPRESS in initramfs-tools, please consider
to add the following to NEWS:
- Using "xz" as compression method can extremely reduce the size of
initrd image, but it may takes around 2x time compared to zip. For
arm/orion5x it usually takes 2 minutes to create (update-initramfs).
- For device with 128M memory or even less, it's necessary to set up
environment variable XZ_DEFAULTS to limit the memory usage while
creating initrd. For example, below two setting is confirmed working
on system with 64M and 128M memory respectively:
  * export XZ_DEFAULTS="--memlimit=40MiB"
  * export XZ_DEFAULTS="--memlimit=80MiB"
You can also append the XZ_DEFAULTS setting to ~/.bashrc for your convenience.

Thank you!

Cheers,
Roger


Reply to: