For added functionality Parted Magic can use bundles (.sqfm, a newer, more memory-efficient format) and packages (.txz/.tgz – a Slackware compatible format).
For even more functionality one can use .txz packages for Slackware 15.x, either from Slackware’s own or its community repositories.
You can also used .deb packages, but Parted Magic will not make any attempt to resolve the dependencies.
Note: There is no guarantee that these “foreign” packages will install or run correctly.
When booting Parted Magic will install any bundles and/or packages it finds in the /pmagic/pmodules directory.
If you run Parted Magic from a USB stick just copy the bundle(s) and package(s) to that directory. This is the easiest way for adding programs to Parted Magic.
If you run Parted Magic from a CD the ISO must be remastered and reburnt – see our How to remaster the iso file page for details.
If you run Parted Magic via PXE the ISO must be remastered – see our How to remaster the iso file page for details.
For a one-off install of a bundle download it to e.g. /tmp and issue:
pmagic_load_sqfm -l /tmp/thebundle.sqfm
The same command can be used to load an optional bundle. E.g.:
mount /dev/sr0
pmagic_load_sqfm [-d|l] /media/sr0/pmagic/optional/thebundle.sqfm
Where -d (default) indicates that the bundle must be copied to memory before loading it, and -l (live) that the bundle must be loaded from the media directly (thus locking the media). If neither -d nor -l is stated the mode Parted Magic is running in (default or live) will be taken.
For a one-off install of a package download it to e.g. /tmp and issue:
installpkg /tmp/thepackage.txz
Parted Magic when booting will also run any scripts it finds in the/pmagic/pmodules/scripts directory.
Making your own bundle or package.
Parted Magic is a Linux OS, so you can’t use Windows programs. As a bundle or package as mentioned above in a sense just decompresses into the ”/” directory it is really easy to create a bundle or package yourself. For this adding programs example we will make a bundle for the foobar program:
mkdir -p foobar/squashfs-root
cd foobar/squashfs-root
mkdir etc
cp /etc/foobar.conf etc
mkdir -p usr/bin
cp /usr/bin/foobar usr/bin
cd ..
mksquashfs squashfs-root/ ../foobar.sqfm -comp xz -b 1M -noappend
The above CLI commands create a directory structure that resembles the “real” one, copy the “real” /etc/foobar.conf and /usr/bin/foobar files into that structure and create the bundle. Of course you can also use GUI tools to create the directory structure and to copy the files.
Note: The bundle must be created from within the root of the directory structure.
To review a bundle just mount it, e.g.:
mount -t squashfs -r /path/to/mybundle.sqfm /mnt
To maintain a bundle unsquash it, apply your changes and squash it again. E.g.:
mkdir mybundle
cd mybundle
unsquashfs /path/to/mybundle.sqfm
< your changes >
mksquashfs squashfs-root /path/to/mybundle.sqfm -comp xz -b 1M -noappend
To create a .txz package issue the following commands:
mkdir foobar
cd foobar
mkdir etc
cp /etc/foobar.conf etc
mkdir -p usr/bin
cp /usr/bin/foobar usr/bin
tar cvJf ../foobar.txz *
To review a .txz package e.g. right click on it in the file manager and choose open with the Archive Manager.
To maintain a .txz package just untar it, apply your changes and tar it again. E.g:
mkdir mypackage
cd mypackage
tar xpf /path/to/mypackage.txz
< your changes >
tar cvJf /path/to/mypackage.txz *
