Linux Backup with USB MIrror Reprise

If you read my previous blog entry you will probably have found I got a few things wrong. One was pretty basic and I have to wonder what I was thinking when I wrote it, the other was a little more convoluted and I'm having to rethink some of the approach.

The basic one I've fixed in the post, so if you come to it late you probably didn't get tripped up by it. I had said that fifth field in /etc/fstab was related to auto mounting the file system. It isn't. It has never been. I should know better, as I've been administering UNIX and UNIX-like systems for more than 25 years and in all that time it has meant exactly the same thing, the backup cycle pass. In case you are interested the way to stop a file system from being auto mounted is to add the noauto flag to the fourth field.

Now onto the more problematic issue. It seems that there is a chicken-and-egg situation, at least with Fedora 7 (on which this test was based). The problem is that the md (RAID) device isn't detected at startup, and the LVM device mapper runs but doesn't find the physical volume we created, so the file system check (which runs before mounting) fails, putting the system into maintenance mode.

If your system is in this mode, my apologies, but you can enter the root password and edit /etc/fstab and comment out the offending file system line. When you exit the maintenance shell the system should reboot into a sane state.

As far as I can see there are a couple of things we can probably do, I guess the easiest is to:

  1. Set the fsck pass field to 0 to stop the system checking on startup
  2. Set the options field to defaults,noauto to stop it from being auto-mounted
  3. Change from an logical volume to a standard filesystem directly on the md device
  4. Edit /etc/rc.local to mount the filesystem after the md subsystem has started

I am going to explore other options though, like making sure the md support is available in the initrd (the initial filesystem available to the boot process to load drivers and tools required before the root filesystem is loaded), and perhaps not using the entire disk for RAID (which required mdadm to use its config file to find the devices) but instead use a Linux RAID autodetect partition on each drive so that the boot process has a hint that the md subsystem is needed early in the boot process.

I won't have a chance to test these latter options today, but will keep you posted on the outcome of my attempts to delve the depths of the RAID options within Linux.

No feedback yet


Form is loading...