[lorax] how to decrease squashfs.img size, it increase more than install size

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

 




hi guys. I want to build a cutom liveos by lorax.
my first liveos , dracut miss 'livenet' module, so it can **NOT** boot under PXE
boot failed message:

    dracut: FATAL: Don't Know how to handle 'root=live:http://...squashfs.img'

first create command:

    livemedia-creator --no-virt --make-iso --ks=centos7.liveos.ks.cfg

After I add 'dracut-network' package in centos7.liveos.ks.cfg '%package' section,
the second create liveos with 'livenet' module can boot from PXE successfully:

    livemedia-creator --dracut-arg="--no-hostonly" --no-virt --make-iso --ks=centos7.liveos.ks.cfg

But squashfs.img size increased was larger than the size initramfs.img increased.
I hope to slim 'squashfs.img' size, so it could boot from PXE speedily.
I mount the squashfs.img compare the different size of these two liveos,
the different size was **only** at initramfs.img

install size was increase on 11M, but squashfs.img increase 50M :

    # df -h
    ...
    /dev/loop1      296M  296M     0 100% /mnt/1        <-- squashfs.img size
    /dev/loop2       21G  817M   20G   4% /media/1      <-- install size
    ...
    /dev/loop3      346M  346M     0 100% /mnt/2        <-- squashfs.img size
    /dev/loop4       21G  828M   20G   4% /media/2      <-- install size

'du -sh' show it under '/boot' direcory.

    # du -sh /media/1/*|sort -rh
    748M    /media/1/usr
    31M     /media/1/boot                               <-- initramfs.img without livenet
    22M     /media/1/var
    9.6M    /media/1/etc
    3.2M    /media/1/opt
    143K    /media/1/root
    12K     /media/1/lost+found
    11K     /media/1/tmp
    1.0K    /media/1/sys
    1.0K    /media/1/srv
    1.0K    /media/1/run
    1.0K    /media/1/proc
    1.0K    /media/1/mnt
    1.0K    /media/1/media
    1.0K    /media/1/home
    1.0K    /media/1/dev
    0       /media/1/sbin
    0       /media/1/lib64
    0       /media/1/lib
    0       /media/1/bin

    # du -sh /media/2/*|sort -rh
    748M    /media/2/usr
    42M     /media/2/boot                               <-- nohostonly initramfs.img with livenet
    22M     /media/2/var
    9.6M    /media/2/etc
    3.2M    /media/2/opt
    143K    /media/2/root
    12K     /media/2/lost+found
    11K     /media/2/tmp
    1.0K    /media/2/sys
    1.0K    /media/2/srv
    1.0K    /media/2/run
    1.0K    /media/2/proc
    1.0K    /media/2/mnt
    1.0K    /media/2/media
    1.0K    /media/2/home
    1.0K    /media/2/dev
    0       /media/2/sbin
    0       /media/2/lib64
    0       /media/2/lib
    0       /media/2/bin

increase SIZE was at initramfs.img:

    -rw-r--r-- 1 root root  34M | 2014-07-17 22:58:56 | initramfs-3.10.0-123.4.2.el7.x86_64.img
    -rw-r--r-- 1 root root  23M | 2014-07-17 20:28:49 | initramfs-3.10.0-123.4.2.el7.x86_64.img

    /media/1/boot:
    total 31M
    drwxr-xr-x 2 root root 1.0K | 2014-07-17 20:27:43 | grub
    drwxr-xr-x 3 root root 1.0K | 2014-07-17 20:27:47 | grub2
    -rw-r--r-- 1 root root 174K | 2014-06-10 16:16:36 | elf-memtest86+-4.20
    -rw-r--r-- 1 root root 173K | 2014-06-10 16:16:36 | memtest86+-4.20
    -rw-r--r-- 1 root root 224K | 2014-07-01 00:20:49 | symvers-3.10.0-123.4.2.el7.x86_64.gz
    -rw-r--r-- 1 root root  23M | 2014-07-17 20:28:49 | initramfs-3.10.0-123.4.2.el7.x86_64.img
    -rw-r--r-- 1 root root 120K | 2014-07-01 00:18:32 | config-3.10.0-123.4.2.el7.x86_64
    -rw------- 1 root root 2.8M | 2014-07-01 00:18:32 | System.map-3.10.0-123.4.2.el7.x86_64
    -rwxr-xr-x 1 root root 4.7M | 2014-07-01 00:18:33 | vmlinuz-3.10.0-123.4.2.el7.x86_64

    /media/2/boot:
    total 42M
    drwxr-xr-x 2 root root 1.0K | 2014-07-17 22:57:34 | grub
    drwxr-xr-x 3 root root 1.0K | 2014-07-17 22:57:38 | grub2
    -rw-r--r-- 1 root root 174K | 2014-06-10 16:16:36 | elf-memtest86+-4.20
    -rw-r--r-- 1 root root 173K | 2014-06-10 16:16:36 | memtest86+-4.20
    -rw-r--r-- 1 root root 224K | 2014-07-01 00:20:49 | symvers-3.10.0-123.4.2.el7.x86_64.gz
    -rw-r--r-- 1 root root  34M | 2014-07-17 22:58:56 | initramfs-3.10.0-123.4.2.el7.x86_64.img
    -rw-r--r-- 1 root root 120K | 2014-07-01 00:18:32 | config-3.10.0-123.4.2.el7.x86_64
    -rw------- 1 root root 2.8M | 2014-07-01 00:18:32 | System.map-3.10.0-123.4.2.el7.x86_64
    -rwxr-xr-x 1 root root 4.7M | 2014-07-01 00:18:33 | vmlinuz-3.10.0-123.4.2.el7.x86_64


_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list

[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux