SourceFiles.org - Use the Source, Luke
Home | Register | News | Forums | Guide | MyLinks | Bookmark

Related Sites

Latest News
  General News
  Reviews
  Press Releases
  Software
  Hardware
  Security
  Tutorials
  Off Topic


Back to files

multicd
Introduction

I wanted to backup my entire Linux system. I wanted to do it by making direct copies of the files (no archiving or compression), so if I just wanted to look at one of the files on one of the CDs, I could. This also makes it very easy to restore from backups. Backing up my entire Linux system takes more than one CD, so I was running the du command on a bunch of directories to see what would fit on which CD. This was very tedious and time consuming, so I wrote multicd to do this work for me. Description

multicd has a fairly large number of options. It can be configured to run in a variety of ways. Here are some of the more interesting features:

multicd can run in an interactive or non-interactive mode.

  • Interactive mode assumes that you will be burning more than one disc. You tell multicd which files to backup, and it will prompt you to insert a disc each time it is ready to burn a new one.
  • Non-interactive mode copies the files to an image file, and then burns just a single CD. It assumes you have left a CD in your burner. This is useful if you want to call multicd from a script or a cron job.

multicd can be configured to run in a multi-threaded mode. If your machine can handle it, you can burn one CD image while another image is having the next set of files copied to it. This option can be disabled on slower machines. Since non-interactive mode burns only one CD, multi-threading is only used in interactive mode. When running with this feature enabled, it's best to redirect stderr somewhere. I send the output of cdrecord, along with some other status information, to stderr. When cdrecord is running in the background at the same time as the main process, their output will overlap. I usually do something like:

multicd 2> err
and then in another terminal I do:
tail -f err
so that I can watch the progress of cdrecord.

Selecting which files to backup is simple and powerful. For example, you can tell it to backup / (everything), but have it exclude certain sub directories like /tmp /dev /mnt /usr/tmp /proc, etc. It only backs up regular files, directories, and symlinks. All other files are automatically skipped. Also, if there is a problem reading a file because of permissions or whatever, it is automatically skipped. A warning is printed to standard error whenever a file is skipped.

multicd can be configured to run in a mode where it simply creates a series of image files, without burning anything to discs. Some people find this useful if they want to burn the CDs later.

This was developed on Linux, but should run fine on any Unix-like system. Configuration

The documentation in the sample config file that's in the package explains all of the options that are available. multicd can get configuration information from any of three places:

  • The global configuration file: /etc/multicdrc
  • A per-user configuration file called .multicdrc, located in the user's home directory.
  • From the command line.

Values are read from all three of these locations. If the same value is specified in more than one location, then values from the ~/.multicdrc will override values from the global file, and command line options will override both of the other two. Prerequisites

  • A Unix-like operating system.
  • The cdrecord program.
  • Perl, version 5 or newer.


Other Sites

Discussion Groups
  Beginners
  Distributions
  Networking / Security
  Software
  PDAs

About | FAQ | Privacy | Awards | Contact
Comments to the webmaster are welcome.
Copyright 2006 Sourcefiles.org All rights reserved.