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?
:After reading the man page for 'lockf' I did not get how to implement
:it actually. Are '.lockmirror' and 'do_mirror' scripts? If so Please
:can I get to see them?
:
:thanks
:
:--Siju
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.
I use -k because there's no point deleting the lock file, and I use
-t 0 to cause lockf to abort (exit) if the lock cannot immediately
be acquired, to avoid building up lockf commands from cron if something
takes extra long to run (or in the case of a mirror-stream, that the
previous mirror-stream is still running).
.lockmirror is just the lock file created by lockf. It's empty. It
is only used for locking.
My little do_mirror script does my batch mirroring operation... my
cpdup/rdist/whatever. That is the script that my lockf command runs
while holding the lock on the lock file.
-Matt
Matthew Dillon
<dillon@backplane.com>
[
Date Prev][
Date Next]
[
Thread Prev][
Thread Next]
[
Date Index][
Thread Index]