Maragda: Running Linux from CD

An overview of one man's DIY adventure in putting Linux on a bootable CD-ROM.

The project described here is further proof that Linux is a powerful and versatile system.

My college has several trolleys that carry a computer (PC) and a VCR, and both are connected to a video projector. They have so many users that it's difficult to keep them working properly. This is especially true in the case of the computer; you can't ever be sure what software you will find on the hard disk.

I decided to use the projectors in the introductory programming course to show my students source C programs and how to run them step-by-step. I, of course, wanted to use Linux and its programming tools so that my students learn that Windows is not the only choice.

In this situation, I came to the conclusion that I needed some sort of portable Linux system, and I didn't want to use my notebook in the classroom.

My first idea was to try installing Linux on an Iomega Zip 250MB drive for parallel ports. After a few days of work I achieved it. It needs a floppy to boot the system, and the run speed is not too bad. Then I repeated the task, this time installing Linux on an IDE hard disk contained in the IDE box adapter for parallel ports. This configuration removes the limitation of 250MB disk space and speeds up the running of Linux.

From the lessons learned from these tasks, I asked myself, why not run Linux from a CD-ROM? That would be convenient and easier to use. In addition, students could use it to start learning Linux without having to install it on their computers. And so Maragda was born.

How to Use Maragda

The final product is a bootable CD-ROM, so you must configure your BIOS to boot from the CD drive. If your BIOS doesn't support this, there is a solution: a bootable floppy that will also boot Linux from the CD. In fact, a raw image of the floppy is what the CD contains to boot itself.

The Linux software on the CD is installed from the Red Hat 6.2 distribution, and I prepared two arrangements. The first one is a full installation. It contains the base system, printer support, the X Window System, the VGA16 and framebuffer X servers, GNOME (or you can edit .xinitrc and uncomment the line for the window manager you like the most), network server workstation, authoring and publishing tools (LaTeX, etc.), Emacs, development tools (make, egcs, etc.), DOS/Windows connectivity, mail, WWW and news tools, and other packages such as rhide, ssh support and the JDK 1.2.

The second arrangement, which I call Maragda Teaching, is only equipped with part of the packages of the base system and X (to use fvwm2), with the complete development tools and other tools such as gv and rhide.

Full Maragda requires at least 64MB of RAM, while Maragda Teaching (and its tools) runs with only 32MB. There's a second arrangement of full Maragda that runs with 32MB but does not include room for tools such as Emacs or Netscape, which require more memory.

In both cases, the same kernel is used. It is version 2.2.14, and it supports (among other things) the network, the framebuffer device, the loop-back device, RAM disk and initial RAM disk.


One of the problems of any system intended for portability is how to adapt to different hardware. At the very least, the mouse and video (X) must be configured, and then the passwords, network identity and others. In the case of Maragda, it should be remembered that no change survives one session because the files on the CD are read-only.

Full Maragda is configured by default to support a PS2 mouse and the framebuffer device for video with a depth of 32. Network uses the driver 3c59x (a 3Com card) with identity (

However, full Maragda has an open door that allows you to decide on the configuration yourself. Just after the main file systems are mounted, the boot process stops and asks for an ext2 formatted floppy. Every file on the floppy will be merged into the system before the programs and d<\#230>mons are started.

Which files should be on the floppy? Consider the following list as a guide:


If you know nothing about these files or other configuration files, there is still hope for you. You must continue the boot and log in as root (I hope this will always be possible). The CD will be mounted in /mnt/cdrom. In /mnt/cdrom/system/config-touch you will find two scripts. Running Touch_all will touch all the files in the system. Then run the configuration tool you need (setup, xconfigurator or control-panel in X). Finally, run Find_newer. It will find the files updated by the configuration, and it will copy them to a directory named config in the current directory. Put the files on a floppy and you are done.

The configuration of Maragda Teaching is restricted. It does not ask for a floppy, and prompts you to choose one of four configurations already on the system:

  1. PS2 mouse and frame buffer

  2. serial mouse and frame buffer

  3. PS2 mouse and vga

  4. serial mouse and vga

In future versions of Maragda, I plan to detect the environment where Maragda is booting and auto configure it.


White Paper
Linux Management with Red Hat Satellite: Measuring Business Impact and ROI

Linux has become a key foundation for supporting today's rapidly growing IT environments. Linux is being used to deploy business applications and databases, trading on its reputation as a low-cost operating environment. For many IT organizations, Linux is a mainstay for deploying Web servers and has evolved from handling basic file, print, and utility workloads to running mission-critical applications and databases, physically, virtually, and in the cloud. As Linux grows in importance in terms of value to the business, managing Linux environments to high standards of service quality — availability, security, and performance — becomes an essential requirement for business success.

Learn More

Sponsored by Red Hat

White Paper
Private PaaS for the Agile Enterprise

If you already use virtualized infrastructure, you are well on your way to leveraging the power of the cloud. Virtualization offers the promise of limitless resources, but how do you manage that scalability when your DevOps team doesn’t scale? In today’s hypercompetitive markets, fast results can make a difference between leading the pack vs. obsolescence. Organizations need more benefits from cloud computing than just raw resources. They need agility, flexibility, convenience, ROI, and control.

Stackato private Platform-as-a-Service technology from ActiveState extends your private cloud infrastructure by creating a private PaaS to provide on-demand availability, flexibility, control, and ultimately, faster time-to-market for your enterprise.

Learn More

Sponsored by ActiveState