DragonFly users List (threaded) for 2009-07
DragonFly BSD
DragonFly users List (threaded) for 2009-07
[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: Siju George <sgeorge.ml@xxxxxxxxx>
Date: Wed, 22 Jul 2009 19:09:34 +0530

On Tue, Jul 21, 2009 at 10:19 PM, Matthew
Dillon<dillon@apollo.backplane.com> wrote:
>    lockf gets an exclusive lock on the specified lock file and runs
>    the specified program while holding the lock.  So if you run lockf
>    wieth the same lock file 50 times in parallel, the programs you run
>    via that lockf are run sequentially, one at a time, and not in parallel.
>

Thanks a million Matt for the detailed reply.

So I created 3 files in /root/adm

1) .lockfile

2) # cat /root/adm/hms
hammer mirror-stream /Backup1/Data /Backup2/Data

3) # cat /root/adm/hmc
hammer synctid /Backup1/Data
hammer mirror-copy /Backup1/Data /Backup2/Data

and in /etc/rc.local I put this entry.

(cd /root/adm; /usr/bin/lockf -k -t 0 .lockfile ./hms) &

Then I put this entry in the crontab for root

10 1 * * * (cd /root/adm; /usr/bin/lockf -k -t 0 .lockfile ./hms) &

and I put this in the /etc/rc.shutdown

(cd /root/adm; /usr/bin/lockf -k -t 0 .lockfile ./hmc)

Will this do the trick ? :-)

Thanks again

--Siju



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