Billix: a Sysadmin's Swiss Army Knife
Does anyone remember Linuxcare? Founded in 1998, Linuxcare was a company that provided support services for Linux users in corporate environments. I remember seeing Linuxcare at the first ever LinuxWorld conference in San Jose, and the thing I took away from that LinuxWorld was the Linuxcare Bootable Business Card (BBC). The BBC was a 50MB cut-down Linux distribution that fit on a business-card-size compact disc. I used that distribution to recover and repair quite a few machines, until the advent of Knoppix. I always loved the portability of that little CD though, and I missed it greatly until I stumbled across Damn Small Linux (DSL) one day.
After reading through the DSL Web site, I discovered that it was possible to run DSL off of a bootable USB key, and that old love for the Bootable Business Card was rekindled in a new way. It wasn't until I had a conversation with fellow sysadmin Kyle Rankin about the PXE boot environment he'd implemented, that I realized it might be possible to set up a USB key to do more than merely boot a recovery environment. Before long, I had added the CentOS and Ubuntu netinstalls to my little USB key. Not long after that, I was mentioning this in my favorite IRC channel, and one of the fellows in there suggested I put the code on SourceForge and call it Billix. I'd had a couple beers by then and thought it sounded like a great idea. In that instant, Billix was born.
Billix is an aggregation of many different tools that can be useful to system administrators, all compressed down to fit within a 256MB bootable USB thumbdrive. The 256MB size is not an arbitrary number; rather, it was chosen because USB thumbdrives are very inexpensive at that size (many companies now give them away as advertising gimmicks). This allows me to have many Billix keys lying around, just waiting to be used. Because the keys are cheap or free, I don't feel bad about leaving one in a server for a day or two. If your USB drive is larger than 256MB, you still can use it for its designed purpose—storing files. Billix doesn't hamper normal use of the USB drive in any way. There also is an ISO distribution of Billix if you want to burn a CD of it, but I feel it's not nearly as convenient as having it on a USB key.
The current Billix distribution (0.21 at the time of this writing) includes the following tools:
Damn Small Linux 4.2.5
Ubuntu 8.04 LTS netinstall
Ubuntu 7.10 netinstall
Ubuntu 6.06 LTS netinstall
Fedora 8 netinstall
CentOS 5.1 netinstall
CentOS 4.6 netinstall
Debian Etch netinstall
Debian Sarge netinstall
Memtest86 memory-checking utility
Ntpwd Windows password changing utility
DBAN disk wiper utility
So, with one USB key, a system administrator can recover or repair a machine, install one of eight different Linux distributions, test the memory in a system, get into a Windows machine with a lost password or wipe the disks of a machine before repurpose or disposal. In order to install any of the netinstall-based Linux distributions, a working Internet connection with DHCP is required, as the netinstall downloads the installation bits for each distribution on the fly from Internet-based mirrors.
Hopefully, you're excited to check out Billix. You simply can download the ISO version and burn it to a CD to get started, but the full utility of Billix really shines when you install it on a USB disk. Before you install it on a USB disk, you need to meet the following prerequisites:
256MB or greater USB drive with FAT- or FAT32-based filesystem.
Internet connection with DHCP (for netinstalls only, not required for DSL, Windows password removal or disk wiping with DBAN).
install-mbr (part of the mbr package on Ubuntu or Debian, needed for some USB drives).
syslinux (from the syslinux package on Ubuntu or Debian, required to create the bootsector on the USB drive).
Your system must be capable of booting from USB devices (most have this ability if they're made after 2005).
To install the USB-based version of Billix, first check your drive. If that drive has the U3 Windows software on it, you may want to remove it to unlock all of the drive's capacity (see the Resources section for U3 removal utilities, which are typically Windows-based). Next, if your USB drive has data on it, back up the data. I cannot stress this enough. You will be making adjustments to the partition table of the USB drive, so backing up any data that already is on the key is critical. Download the latest version of Billix from the Sourceforge.net project page to your computer. Once the download is complete, untar the contents of the tarball to the root directory of your USB drive.
Now that the contents of the tarball are on your USB drive, you need to install a Master Boot Record (MBR) on the drive and set a bootsector on the drive. The Master Boot Record needs to be set up on the USB drive first. Issue a install-mbr -p1 <device> (where <device> is your USB drive, such as /dev/sdb). Warning: make sure that you get the device of the USB drive correct, or you run the risk of messing up the MBR on your system's boot device. The -p1 option tells install-mbr to set the first partition as active (that's the one that will contain the bootsector).
Next, the bootsector needs to be installed within the first partition. Run syslinux -s <device/partition> (where <device/partition> is the device and partition of the USB drive, such as /dev/sdb1). Warning: much like installing the MBR, installing the bootsector can be a dangerous operation if you run it on the wrong device, so take care and double-check your command line before pressing the Enter key.
At this point, your USB drive can be unmounted safely, and you can test it out by booting from the USB drive. Once your system successfully boots from the USB drive, you should see a menu similar to the one shown in Figure 1. Simply choose the number for what you want to boot, run or install, and that distribution will spring into action. If you don't select a number, Damn Small Linux will boot automatically after 30 seconds.
Bill Childers is the Virtual Editor for Linux Journal. No one really knows what that means.
- [<Megashare>] Watch Mrs Brown's Boys Movie Online Full Movie HD 2014
- Considering Legacy UNIX/Linux Issues
- Cluetrain at Fifteen
- Memory Ordering in Modern Microprocessors, Part I
- New Products
- Python Scripts as a Replacement for Bash Utility Scripts
- RSS Feeds
- Getting Good Vibrations with Linux
- Tech Tip: Really Simple HTTP Server with Python
- Readers' Choice Awards 2013