DragonFly users List (threaded) for 2009-06
DragonFly BSD
DragonFly users List (threaded) for 2009-06
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

Re: dragonfly- UFS + HAMMER + mirroring setup designed instead of RAID - Is this OK?


From: Matthew Dillon <dillon@xxxxxxxxxxxxxxxxxxxx>
Date: Thu, 25 Jun 2009 08:25:27 -0700 (PDT)

    It seems reasonable.  You probably don't have to use the mirroring
    feature to backup the backup since they are local disks but it is
    fun to play with.

    If you use mirror-stream instead of mirror-copy you can control the
    bandwidth used by the mirroring operation (so as not to interfere with
    other things happening on the machine) and it will run continuously. 
    So for example this will limit the mirroring bandwidth to 5 MBytes/sec:

	hammer -b5m mirror-stream masterpfs slavepfs

    mirror-stream only exits if the connection is lost so it is still a
    good idea to check-start it with cron.  I usually use lockf for that
    and a simple script.  Also make sure it isn't being verbose when run
    from cron or poor cron will be collecting a very large temporary mail
    file.

    10 1 * * *      (cd ~/adm; /usr/bin/lockf -k -t 0 .lockmirror ./do_mirror 1)


:#hammer pfs-slave /Backup2/Data shared-uuid=7f37a084-6188-11de-958a-535400123456
:#hammer pfs-status /Backup2/Data

    On the PFS's, the convention is to create them in <basefs>/pfs/NAME and
    then use null mounts to put them where you actually want them.  e.g.:

	hammer pfs-slave /Backup2/pfs/Data
	mkdir /Backup2/Data
	mount_null /Backup2/pfs/Data /Backup2/Data

    In /etc/fstab a null mount looks something like this:

	# Device        Mountpoint      FStype  Options         Dump    Pass#
	/pfs/home       /home           null    rw              0       0
	/pfs/usr.obj    /usr/obj        null    rw              0       0

    null mounts aren't quite as useful for PFS slaves since a null mount
    will lock-in the slave TID instead of tracking it.  In that case a
    second softlink might be reasonable instead of using a NULL mount.

    In anycase, if redundancy is that important to you for the backup box
    then I recommend a combination of a SATA SSD (SATA-based solid state
    flash drive) and two hard drives.  Put the main system on the SSD and
    only use the hard drives for the two HAMMER filesystems.

    If the motherboard supports AHCI you probably also want to use the
    AHCI disk driver, which is new in the master branch.  The NATA driver
    cannot do NCQ.  The drives will be recognized as da0, da1, da2, etc...
    instead of adX.  Also, the AHCI driver can handle hot-plug (though you
    still need to be sure to umount the filesystem(s) before removing the
    HD).  In that case the SSD would be the machine's internal drive and
    you would use hot-plug hard disks as two external ESATA drives in an
    enclosure, or something on that order.

					-Matt
					Matthew Dillon 
					<dillon@backplane.com>



[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]