Live CD/DVD customization tool
Friday, 04. October 2019 04:46 PM UTC
Table of Contents
Customized ISOs for personal use are fine. If you want to share your customization with others, whether for free or for purchase, you'll have to rename it; remove all distro specific artwork, branding, and other identity elements; and you can't confuse your intended users about the customization being associated in any way with the base distro.
You're free to use the softwares without renaming those, as they are licensed under GPL. But otherwise, it will be your own creation and no longer you base distros'.
The name and identity elements of a distro are trademarked and copyrighted. Unless you have approval from appropriate authorization you can't use those (identity elements and name).
This is a simple command line tool to customize live cd/dvd of Debian, Archlinux, Ubuntu family, Linux Mint and some of their derivatives. It does not require that the host system and the target system be the same, i.e you can modify debian live cd sitting on ubuntu or archlinux, or modify archlinux live cd sitting on ubuntu and so on.
It gives you a chroot environment for modification and creates the modified iso image. You need to do all the customizations on your own, JLIVECD itself does not do any modifications.
It is developed with the help of the documentation found on:
This tool is intended primarily for personal use.
Please read through the Additional info section before you start with a Ubuntu or Linux Mint ISO for the first time.
It works as project basis. For a JLIVECD project, you need to use your base ISO only once to extract it and deploy the project. After that, you can keep changing things and building and testing ISOs built on those changes.
It works with both global and local configuration files. Using config files, you can skip prompts that need answers from user input. Local (project wise) config is prioritized over global config.
Global configuration file:
Local configuration file:
config.conf file in your project directory.
Install requirements with the following command in debian like systems:
and the following command in Archlinux:
sudo apt-get install squashfs-tools genisoimage syslinux syslinux-utils rsync xterm
sudo pacman -S squashfs-tools cdrkit syslinux rsync xterm dosfstools
install.sh file in terminal:
chmod +x ./install.sh sudo ./install.sh
JLstart as root in a terminal or run it from
Hints are given on the go, follow them to successfully create a customized live cd/dvd.
~$ sudo JLstart [sudo] password for user: **************** JLIVECD****************** *Tips: * 1. Paths must be absolute. (~ allowed) * 2. Inputs are literal * 3. Do not use NTFS partition ****************************************** === Is this a new project: (y/n)?: ...............................
It prompts for OSMODE (debian, ubuntu or archlinux) for new projects and saves it in project specific .config file so that next time it doesn't require you to specify the OS again. Make sure you don't change it in the .config file.
If you want to run JLIVECD in specific OSMODE, there's three option for you:
||Ubuntu mode (for Ubuntu family & Linux Mint)|
||Debian mode (Debian family)|
||Archlinux mode (Archlinux family)|
Note If you run JLIVECD in a specific OSMODE and it doesn't match with what's in .config file, it will throw error and exit.
Examples of running JLIVECD in specific OSMODE:
sudo JLstart -ub #ubuntu sudo JLstart -db #debian sudo JLstart -al #archlinux
In your project directory, you will find some default files/directories. Don't change their names.
The directories are:
pkgfiles are kept here. See the cache management section for more details.
edit: This is the root filesystem (i.e
/) for the live system (chroot system). Any change you make here will appear in the finalized ISO.
extracted: This is where the original ISO is extracted. You can change several things here, like Diskname, release, date, splash screen, etc.
mnt: A directory used only for mounting ISO image.
mydir: A directory with 777 permission. This directory is moved inside
edit/during chroot, thus in chroot it will be available as
/mydir. Use this directory to store/install packages and files that you need to store for future but do not want to include them in the ISO.
The files are:
.config: configuration of the corresponding project i.e
DISKNAMEand some other defaults (for internal use)
config.conf: Configuration managed by user. This is essentially a bash script and thus you can make intelligent use of it and set dynamic options. Any non-empty value set to a variable (option) will bypass its input prompt.
"~/some folder"are different. If you want spaces then give it as it is:
y/ntype prompts unless specified otherwise.
sudo JLopt -rnin another terminal in your main system. This may happen if you start JLIVECD before connecting your pc to the internet.
JLopt -t timeout_value. "timeout_value" should be replaced with your desired time in seconds. Ex: for 12 seconds timeout:
JLopt -t 12
mate-terminalproperly. For mate DE, install
sudo apt-get install xterm).
JLopt -t1 actual-terminal-command. To change the secondary default terminal:
JLopt -t2 actual-terminal-command. For Ex.
JLopt -t1 gnome-terminal
enter base iso path: ~/Downloads/x. As there is only one file that matches 'x in my Downloads folder is
xubuntu-14.04.1-x64.iso, it will take that file as the input.
pacman -Scc). JLIVECD cleans
pacmancache after backing up the
pkgfiles to reduce future downloads. If you do clean manually, the
pkgcache will not be available anymore and you will have to redownload the same packages again when installing/reinstalling next time around.
.debfiles in edit/var/cache/apt/archives folder (or
pkgfiles in edit/var/cache/pacman/pkg/) so that they don't get downloaded again in the software installation process.
pkgfiles from edit/var/cache/apt/archives manually and you shouldn't (not even with package manager cache clean program unless you want it that way for disk space constraint).
pkgfiles in debcache folder too, but in that case you need to run JLIVECD after you have finished copying files to this folder.
Customization related documents can be found on JLIVECD github wiki.
By default JLIVECD creates hybrid image. You can either use tools like
unetbootin or something like
dd to create the bootable USB. If you want to use
dd, be careful about mistyping and what you are doing. For example, you could end up wiping your hard disk if you mistype
/dev/sda. For this, I have another script (chibu) that checks the validity of the usb device and makes sure it's a USB device not something else like a partition on your hard drive. After cheking validity it runs a
dd command to create the bootable USB.
Note: chibu or dd will destory existing data on the USB
chibu, it's like this:
sudo chibu iso_path /dev/sdx
/dev/sdx1etc..) is your usb device, (x is a letter)
You can find the device id with:
look for the usb device in the output of the above command.
sudo fdisk -l
unetbootinmay not have its boot flag set. Check with
gpartedand set the boot flag if not set.
unetbootinmay fail to boot with its first default boot option, choose
unetbootindoesn't work, try
unetbootinwon't work for archlinux, use
1.In Linux Mint 17 XFCE there's a bug. To fix this edit
/usr/sbin/invoke-rc.d file (in chroot) as:
exit 100 with
exit 0 at line
421, then apply upgrade. after upgrading revert this modification (must).
2.In Linux Mint 17 xfce, if you install nautilus then it will set gnome-session as default session and if gnome desktop is not installed then no desktop window will show up in live session. change the link
/usr/bin/x-session-manager to point to
3.In xubuntu 14.04.1 there's another bug: Can't open /scripts/casper-functions" error) to fix this, run this code in chroot:
ln -s /usr/share/initramfs-tools/scripts /scripts
Follow the following link for bug report:
4.In Ubuntu 14.04 Gnome LTS you might encounter two more bugs:
One should be solved by editing:
/var/lib/dpkg/info/whoopsie.prerm /var/lib/dpkg/info/libpam-systemd\:amd64.prerm /var/lib/dpkg/info/libpam-systemd\:amd64.postinst
exit $? to
exit 0 in the invoke-rc.d lines)
Other one should be solved by editing:
find the following and comment out the if and fi line:
if [ -e /boot/grub/grub.cfg ]; then #exec update-grub fi
Revert these changes before exiting the chroot.
Follow the following link for bug report for more details:
5.You may encounter another bug:
Ubiquity installer, hang/freeze on harddisk detection. This bug can be solved by editing the file
edit/usr/share/applications/ubiquity-gtkui.desktop and changing the section
sh -c 'ubiquity gtk_ui'
sh -c 'sudo ubiquity gtk_ui'y