Creating a custom Linux LiveCD With PCLinuxOS

630

Author: Dmitri Popov

LiveCD Linux distributions offer a great way to learn Linux, troubleshoot computer problems, and share Linux with others. Now, with PCLinuxOS, creating a custom LiveCD that meets the exact needs of your family, friends or coworkers has become so easy that almost anyone can do it — once you know a few simple tricks we’ll cover in less than 1500 words, along with a couple of screenshots.The mklivecd tool, which is used to create a LiveCD Linux, can also be
used with Mandrakelinux. However, PCLinuxOS has a couple of advantages
that make it better suited for a LiveCD Linux project. First off,
PCLinuxOS comes with mklivecd already installed and configured, so you
don’t have to spend time doing it yourself. Second, the Synaptic package manager
that comes as part of PCLinuxOS offers an easier and more fool-proof way of adding and removing
software than RPM-based systems. Finally, PCLinuxOS comes on a single CD and offers only a small set of programs by default, which makes it less
time-consuming to remove unwanted software packages.

The process of creating your own PCLinuxOS-based LiveCD (also known as remastering) consists of three major steps: 1) installing the system on your computer, 2) customising the installed system by tweaking its settings and installing/removing software packages, 3) creating an ISO image.

Start by downloading the most recent release of PCLinuxOS from one of the mirrors listed on its Web site. Burn the downloaded ISO image to CD, and you’re ready to begin the process.

Installing PCLinuxOS

For the sake of simplicity let’s assume that you will use the computer’s entire hard disk for PCLinuxOS. Before you can boot your computer using the newly created PCLinuxOS, you have to make sure that your PC’s CD-ROM drive is set as the first boot device. Usually this can be done by changing settings in BIOS, and the exact steps depend on your computer model and BIOS version. Once this is done, you are ready to boot PCLinuxOS. Start your computer and insert the PCLinuxOS CD in the CD drive.

During the boot you will be asked to log in either as guest or root. Log in as root using root as both user name and password. When the system is finished booting, double-click on the Livecd-Installer shortcut on the Desktop to launch the Livecd-Installer tool.

Before you can proceed with the installation, you have to partition the hard disk using the Disk Partitioner tool. Although the Disk Partitioner button says that this tool is for advanced users, it’s actually quite easy to use. Press the button to launch it.

The hda tab contains a graphical presentation of your hard disk. If the disk contains any partitions it’s a good idea to delete them beforehand. Simply click on the partition(s) and press the Delete button in the Choose action section. When the disk has been ‘cleaned,’ you can start partitioning it. PCLinuxOS requires two partitions: one for the swap file (swap partition) and one for the system itself (root partition). Let’s start with creating the swap partition. Click on the bar representing the empty hard disk, press the Create button, select the Linux swap from the Filesystem type list, and use the slider to set the partition’s size to around 2GB. Click OK. Format the created partition by pressing the Format button.

To create a root partition, click on the empty space on the hard disk bar, press the Create button, select Journalised FS: ext3 from the Filesystem type list, and use the slider to set the partition’s size. Click OK. When prompted select the Move files to the new partition option, and click OK. The properly partitioned hard disk should look like the one in figure 1. Press Done to save the changes (choose Yes when prompted to save the /etc/fstab modifications) and quit the Disk Partitioner.

Figure 1 — click to enlarge
Figure 2 — click to enlarge

In the PCLinuxOS Installer click the “Next” button, and make sure that the dialogue window looks like the one in figure 2. Press Next, check the settings, and press Next again. At this point the PCLinuxOS Installer proceeds with the installation of the system on your hard disk. Make yourself a cup of tea and watch the progress bars.

When the installation is complete, click “Next” and select where to install the bootloader (the Master boot record of the drive is a good bet). If you want to enable logging, then press Activate. This will keep logs of system messages and errors for troubleshooting purposes. Finally, add a new root password, delete the guest account and create a new user account. If you want to reboot the system immediately after the installation is complete, select the Yes, reboot my system automatically now option. Press Finish when done.

Customising PCLinuxOS

When the system is installed and you have rebooted your computer, you are ready to customise PCLinuxOS. As with any Linux distribution, you can customise virtually every aspect of PCLinuxOS, and your options are limited only by your imagination and level of expertise. On the most basic level you can easily modify the look of your system. This can be done through the KDE Control Center, which allows you to change the background picture, windows appearance, overall theme, splash screen and Screen Saver among other things.

Changing the default theme can really make your own version of PCLinuxOS stand out. KDE-Look.org provides a wealth of background pictures, icons and themes for you to try. (If you are looking for an especially nice-looking theme, you might also want to try Nuvola.)

To install the theme, download it, launch KDE Control Center, go to the LookNFeel > Theme Manager, and press the Install New Theme button. Select the downloaded tar.gz file, and press “OK.” This will install the new theme, and you can activate it by pressing the “Apply” button.

If you want to take your customisation a step further, you can update your system and install/remove software packages. PCLinuxOS comes with APT — one of the best package management tools available for GNU/Linux. The first thing you need to do is to update the list of available packages. Launch Konsole, become root using the su command, and run the apt-get update command. Then you can upgrade your system using the apt-get dist-upgrade command.

Tip: APT HOWTO will help you to get the most out of this package management tool.

You can also use APT to install and remove software packages. However, PCLinuxOS also includes Synaptic — a graphical front-end to APT, which makes it even easier to manage software. Using Synaptic is easy. To launch it choose “Configuration > Packaging > Synaptic Software Manager” from the “Penguin” menu.

When you start Synaptic for the first time, it prompts you to update the package information. Press the Reload button to perform the update. All software packages are neatly organised in categories, making it easier to locate the applications you want to install or remove. You can, for example, view the packages by category (the Sections button) or by their status (the Status button). You can also search for a particular package by clicking on the Search button. When you’ve located the desired application, right-click on it and choose the Mark for Installation option to install it, or Mark for Removal to uninstall it. To commit changes click on the Apply icon in the main toolbar, and Synaptic will take care of the rest.

Creating an ISO image

When you are satisfied with the changes and customisations, you are ready to create an ISO image. This is probably the easiest part of the remastering process. All you have to do is to launch Konsole, become root, and enter mklivecd livecd.iso, where livecd.iso is the name of the final ISO image. There is, of course much more to it. You can run the mklivecd tool using a number of options, which gives you more control over the remastering process. For example, using the --nofile or --nodir option you can exclude particular files or directories from the final image, while various boot options allow you to specify how your remastered PCLinuxOS boots. For example, using the --keyboard option you can specify the default keyboard layout, and the --resolution option allows you to define the default screen resolution. You can easily access the full list of option using the mklivecd --help command.

Dmitri Popov is a freelance writer whose articles have appeared in Russian, British, and Danish computer magazines.

Category:

  • Linux