GNOME Partition Editor
Custom Search

Add packages in GParted live

GParted Live is a small bootable GNU/Linux distribution for x86 machine based on Debian live. If you want to add packages in GParted live, you can follow this:
//NOTE// Due to the changes in Debian Sid repository are very frequent, the following method might need to be adjusted according to the changes.

  1. You need a GNU/Linux system as a working environment to do this. Here we use Debian Jessie as the working environment. First we need to install squashfs-tools if it's not installed:

    $ sudo apt-get update; sudo apt-get install squashfs-tools

  2. Download the GParted live zip format file which you intend to add packages, e.g., GParted live version 0.28.1-1, then uncompress it and extract the filesystem.squashfs

    $ mkdir ~/zip-tmp ~/squashfs-tmp
    $ unzip gparted-live-0.28.1-1-i686-pae.zip -d ~/zip-tmp
    $ cp ~/zip-tmp/live/filesystem.squashfs ~/squashfs-tmp
    $ cd ~/squashfs-tmp; sudo unsquashfs filesystem.squashfs
    (it will extract filesystem.squashfs to directory "squashfs-root" )

  3. Assume the package you intend to add exists in Debian repository, e.g., firefox-esr, then we can do it by:

    $ sudo mount --bind /proc squashfs-root/proc/
    $ sudo mount --bind /sys squashfs-root/sys/
    $ sudo mount --bind /dev squashfs-root/dev/
    $ sudo chroot squashfs-root/
    $ echo "nameserver 8.8.8.8" > /etc/resolv.conf
    (It will write the nameserver for the chroot environment. You can use your desired namer server)
    $ apt-get update; apt-get install firefox-esr
    $ exit

  4. Rebuild the new filesystem.squashfs and replace the original one ,then rebuild GParted live zip file with a XZ-compressed filesystem.squashfs:

    $ sudo mksquashfs squashfs-root filesystem.squashfs.new -b 1024k -comp xz -Xbcj x86 -e boot
    $ sudo cp filesystem.squashfs.new ~/zip-tmp/live/filesystem.squashfs
    $ cd ~/zip-tmp ; sudo zip -r ../gparted-live.new.zip ./*

    Now you have gparted-live.new.zip with firefox-esr included.

  5. If you want to convert zip file to iso file, you can make it by:

    $ cd ~/zip-tmp/
    $ genisoimage -A 'GParted live CD' -f -r -hide-rr-moved -hide-joliet-trans-tbl -J -l -allow-limited-size -b syslinux/isolinux.bin -c syslinux/boot.cat -no-emul-boot -boot-load-size 4 -boot-info-table -eltorito-alt-boot -efi-boot EFI/images/efiboot.img -no-emul-boot ./ > /tmp/gparted-live.iso
Documentation   FAQ   Forum   Bugs   Features   Screenshots   Articles   Contact

Get GParted at SourceForge.net. Fast, secure and Free
	Open Source software downloads Valid HTML 4.01! Correct CSS! Privacy policy