l i n u x - u s e r s - g r o u p - o f - d a v i s
Next Meeting:
July 7: Social gathering
Next Installfest:
Latest News:
Jun. 14: June LUGOD meeting cancelled
Page last updated:
2007 Feb 10 19:09

The following is an archive of a post made to our 'vox-tech mailing list' by one of its subscribers.

Report this post as spam:

(Enter your email address)
Re: [vox-tech] Mirrored drive setup for backup
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [vox-tech] Mirrored drive setup for backup

Dylan Beaudette wrote:
I am looking into some methods of keeping some of our labs shared data in a slightly safer disk setup. Currently there are two single 300Gb SATA drives
For home use where reliability and simplicity often over uptime I often suggest using rsync to copy a disk to a second disk. So you get 2 snapshots
of your files.

So with a backup to a second disk:
* simple
* Protects against "oops, I didn't mean to delete or overwrite that"
* if your primary disk dies you crash, and you have to boot the second
drive to get going again
* You could lose the data since the last backup.

Mirrors on the other hand..
* Somewhat less simple (modules, initrd, monitoring RAID status, etc)
* does not protect against "oops, I didn't mean to delete or overwrite that"
* Survives a disk failure sometimes
* Doesn't lose data since last backup.

So basically is it more likely that you accidentally delete or overwrite
something or more likely that you have a disk death? Is having 2 versions
of all files more of an advantage then having your machine stay up when
a disk dies?

in this machine. I am thinking about installing another set of mirrored 300Gb drives and using this mirrored setup to hold all of the shared data. This would give me two single drives for operations which require instant access (i have heard that a mirrored setup is not as fast as a single drive), and
Depends, hardware RAIDs are often slower or at least no faster than a single
disk. Software RAIDs usually scale pretty well, but keep in mind disk performance is tricky. On writes to a mirror both sides have to do a write
so don't expect any speedup (hardware or software). On reads even in ideal
conditions often there is no gain as well. Not because of RAID limitations
just that read N bytes, skip N bytes, read N bytes.... isn't necessarily
faster than read N bytes, read N bytes, read N bytes....

Basically seeks are expensive, and hard drives have a special case (higher
performance) for seeking to an adjacent track.

the mirrored array for redundancy. This machine is running Debian/Unstable, and has a Tyan Thunder K8WE motherboard. It looks like this board supports up to 4 SATA drives, along with RAID 0, 1, 0+1, and 'JBOD' .
I'd recommend JBOD, especially since some day you might want to migrate or
recover those drives on different hardware and finding another k8we might
be hard. Not to mention learning to use software raid is more valuable
than learning the ins/outs, errors, and strange attributes of a given
set of command line (if available), web (if available), and BIOS (if available) configuration peculiarities of a specific hardware config.

Not to mention software raid is usually faster.

Another machine in this lab only supports RAID level 0 for the SATA connectors. Is there a workable software RAID strategy for mirroring disks in linux or will I need to purchase a new hard disk controller?
Software RAID is supported by most if not all linux distributions, and
usually in the installer.

Would this type of setup be either possible or worthwhile for a simple safeguard against hardware failure? If not, are there other options which would be better suited for this task?
Depends, mirror or 2 copies via a backup both have their place.

> Using the software raid option 'md' driver -- would it be possible to add a
> mirrored disk without re-building the system?

Yes, but not for the faint of heart. It depends on the particulars, but in
general you can change the kernel/initab/modules to load the md driver and
the raid1 driver. Then create a RAID using your existing partition and a failed partition, then use mdadm to add the second disk/partition. Of course
you need to edit /etc/fstab to see the new /dev/md0. This is pretty
easy for a /data partition, but making a raid out of your boot partition
is a bit trickier and if you have an issue you could end up with an unbootable

I'd certainly recommend backing up your files before trying any major filesystem reconfiguration.
vox-tech mailing list

LUGOD Group on LinkedIn
Sign up for LUGOD event announcements
Your email address:
LUGOD Group on Facebook
'Like' LUGOD on Facebook:

Hosting provided by:
Sunset Systems
Sunset Systems offers preconfigured Linux systems, remote system administration and custom software development.

LUGOD: Linux Users' Group of Davis
PO Box 2082, Davis, CA 95617
Contact Us

LUGOD is a 501(c)7 non-profit organization
based in Davis, California
and serving the Sacramento area.
"Linux" is a trademark of Linus Torvalds.

Sponsored in part by:
EDGE Tech Corp.
For donating some give-aways for our meetings.