[arch-releng] [PATCH 1/1] mkfs: limit size of ext4 block group descriptor table

Gerardo Exequiel Pozzi vmlinuz386 at gmail.com
Fri Aug 22 13:39:30 EDT 2014


On 08/22/2014 09:59 AM, Christian Hesse wrote:
> From: Christian Hesse <mail at eworm.de>
> 
> The ext4 filesystems are create with a fixed size of 32GB. After mkfs
> the empty filesystem already has a disk usage of about 4.3MB.
> Limiting the size of ext4 block group descriptor table reduces this
> to just 312KB.
> ---
>  archiso/mkarchiso | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/archiso/mkarchiso b/archiso/mkarchiso
> index 2de026e..8c3bfbf 100755
> --- a/archiso/mkarchiso
> +++ b/archiso/mkarchiso
> @@ -205,7 +205,7 @@ _mkairootfs () {
>      if [[ ${quiet} == "y" ]]; then
>          _qflag="-q"
>      fi
> -    mkfs.ext4 ${_qflag} -O ^has_journal -E lazy_itable_init=0 -m 0 -F "${work_dir}/airootfs.img"
> +    mkfs.ext4 ${_qflag} -O ^has_journal -E lazy_itable_init=0,resize=33G -m 0 -F "${work_dir}/airootfs.img"
>      tune2fs -c 0 -i 0 "${work_dir}/airootfs.img" &> /dev/null
>      _msg_info "Done!"
>      _mount_airootfs
> 

Nice point. But I guess, should be better to disable it at all using
^resize_inode (304K, haha ;))

> -    mkfs.ext4 ${_qflag} -O ^has_journal -E lazy_itable_init=0 -m 0 -F
"${work_dir}/airootfs.img"
> +    mkfs.ext4 ${_qflag} -O ^has_journal,^resize_inode -E
lazy_itable_init=0 -m 0 -F "${work_dir}/airootfs.img"


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 473 bytes
Desc: OpenPGP digital signature
URL: <http://mailman.archlinux.org/pipermail/arch-releng/attachments/20140822/937dac18/attachment.asc>


More information about the arch-releng mailing list