Mounting multiple NFS shares to the same point

Tillman Hodgson tillman at seekingfire.com
Mon Feb 12 19:47:29 UTC 2007


On Mon, Feb 12, 2007 at 01:42:04PM -0600, Tillman Hodgson wrote:
> (Note that that in this case I'm backing up TO the NFS mount, and it's
> possible that the same NFS share could be mounted on the same spot
> twice, depending on how long it takes for the daily backup job to run).

Following up on my own post, I starting digging into other backup
scripts I've written over the years and ran across snippet on a FreeBSD
4.11 box:

### Perform daily backup of ~tillman
# Clean up my backup partition
# Note! We delay this by 2 hours because mount/umount cause mountd to be
# HUPed, which is not atomic and causes a moment EPERM (permissions error) if
# any other machine is currently trying to write via NFS
sleep 7200
/sbin/umount /exports/tillman.backup1/ && \
/sbin/newfs -v -U /dev/vinum/tillman.backup1 &&\
/sbin/mount /exports/tillman.backup1/ && \
/sbin/dump 0f - /exports/tillman | (cd /exports/tillman.backup1; /sbin/restore -rf - )

If that still holds true in the -current src, the second mount will
*definitely* cause me backup problems. I may have to move to keeping the
NFS export always mounted, which is not ideal.

-T


-- 
Master Tung-shan interviewed a new monk: "What's you name?" "Pen-chi," the
monk answered. "Say something more." "I won't." "Why not?" "My name is not
Pen-chi." The Master was much impressed.
	- Zen Mondo


More information about the freebsd-questions mailing list