Jun 202013
 

I recently decided to create a LiveCD to simplify downloading and flashing Raspberry Pi images.

I started off with the GParted ISO as that is already a small distribution, plus it has everything I needed for the PiParted distribution.
GParted comes in ISO form, so the first thing we need to do is mount the ISO file to get all the files that out of it. You’ll need to be root to mount the ISO file, or use sudo.

# mkdir -p ~/isodistro/iso
# mount -o loop gparted-live-0.16.1-1-i486.iso /mnt/iso
# cp -r /mnt/iso/* ~/isodistro/iso

You should see the following files inside

EFI EFI-imgs GParted-Live-Version GPL isolinux live syslinux utils

Inside the live directory, you will see these files

filesystem.packages filesystem.squashfs initrd.img memtest vmlinuz

The one we want is filesystem.squashfs, this file is what contains the main filesystem of the distribution.

As you can probably deduce from the file extension, this file is a squash fs file system. Which means that we can easily unsquash it.

# mkdir ~/isodistro/fs
# cp ~/isodistro/iso/live/filesystem.squashfs ~/isodistro/fs/
# cd ~/isodistro/fs
# unsquashfs filesystem.squashfs

This will create the squashfs-root directory within the fs directory, and if we have a look in there…

# ls squashfs-root/
bin dev etc home initrd.img lib media mnt opt proc root run sbin selinux srv sys tmp usr var vmlinuz

Tada ! We have the root filesystem of GParted.
The startup scripts are located within etc/gparted-live/gparted-live.d if you want to modify those.
Once the modifications have been made, you will need to pack it all back up, and repack the files into the ISO file.

mksquashfs ~/isodistro/fs/squashfs-root/* ~/isodistro/fs/filesystem.squashfs -comp xz
mv ~/isodistro/fs/filesystem.squashfs ~/isodistro/iso/live/
mkisofs -o youriso.iso -b isolinux/isolinux.bin -c isolinux/boot.cat -no-emul-boot -boot-load-size 4 -boot-info-table -J -R -V youriso-live ~/isodistro/iso

That will create the ISO file for you, and hopefully you should be able to boot your newly customised GParted distribution !

Share
Apr 242013
 

Another update to PiParted

Fixed up non-appearing SD Cards
Also added a backup option, at the moment it can only backup ~4GB SD Cards as it reads it to ram for now. Your computer will also need at least 4 GB of ram to backup the SD Card.

Grab it here !

SHA1 Hash – 2fa25e4f9e9260a3612129a1b0291fca3e3fd628 PiParted-0.04.iso

Comments / feedback would be very welcome !

Share
Apr 192013
 

Just finished up with PiParted v0.03

Changes –
No longer needs 4 gigs of ram as it will uncompress and image on the fly.
Tested it on a laptop with 1.5 gigs of ram and it worked ok.

Installing from SD Card –
Works with both zip and .gz file, haven’t tested properly with .tar.gz but should still work

Also checks SHA1 hash when downloaded from the Pi site.

Incremental update really.
Download it from here
SHA1 Hash –
f91e53df56aec6cc7d1b27041e0750b0f4763bfd PiParted-0.03.iso

Share
Apr 082013
 

After some tweaking, I have improved PiParted.
Please note this is a very early testing version, so some things may break or not work properly.

Download it here !

New features –
Flash OS from zip file on SD Card:
If the SD card only has one partition, and there is one zip file on that partition, the script will use that to flash an OS on.

Reset SD Card:
This will format an SD Card back to defaults, i.e. one vfat partition.

dd will now show it’s status when it’s flashing a SD card.

I’m looking for testers, so if anyone tries this out, please give me some feedback, either on this post or in the forum thread @ http://www.raspberrypi.org/phpBB3/viewtopic.php?f=63&t=39160

Share
Apr 022013
 

After going through the forums, I recently had an idea that hopefully will make installing distros onto an SD card much easier.

A lot of issues come from people not knowing how to do it right, e.g. just dropping the img file onto an SD card.
So I’ve customised a GParted LiveCD ISO and written up a custom script to *hopefully* install a distro straight onto an SD card.
This is a very early iteration of this idea, but hopefully will develop into something useful.

At the moment, essentially what it will do is

1. Grab the list of Distros from the RPI Download page
2. Let the user select which distro he wants to install
3. Select the Disk device that he wants to install it onto
4. dd the image onto the disk device.

Later on, I’m hoping to add more functionality including –
resizing image files
resizing sd card partitions
wiping SD cards back to a normal usable (by windows) state
Installing distributions from other sites
auto-resizing of the root partition after installing a distribution

Grab the iso from here

Feedback can be left here or on the forum topic

Share