[NTLUG:Discuss] NFS & Mirrordir times
Jack Snodgrass
jack+ntlug at mylinuxguy.net
Wed Jul 16 13:59:25 CDT 2003
On Wed, 16 Jul 2003 10:46:15 -0500, David Simmons wrote:
> (if you've been following - I've got two machines connected through NFS that
> I want to backup to each other).
>
> Through a VPN link with NFS mounted drives - I've had an interesting
> experience that I was hoping someone could help/improve.
>
> I've got two (approx) 3.5 partitions that I was backing up between systems.
> Using MirrorDir - it took quite awhile to 'mirror/copy' the first. As a
> test, I created a file on the original server "test.txt" and stuck it deep
> in the directory tree - then started the mirrordir command again. Here's
> the interesting results:
>
> Time to complete the 'syncing' to find new extra file:
>
> real 521m40.055s
> user 0m1.390s
> sys 0m14.200s
>
> Now - time to complete the copying of the second 3.5G of data to create base
> copy:
>
> real 754m48.996s
> user 0m2.280s
> sys 1m40.100s
>
> Here's my mount command:
>
> mount 192.168.1.200:/var/DIRECTORY /mnt/OTHER_DIRECTORY -t nfs -o
> ro,rsize=8192,wsize=8192,noatime,sync
>
> I've included 'noatime' and increased rsize & wsizes....is the 'sync' option
> what's causing the lengthy times just to read through the directory - or is
> that 'just as fast as it goes'(tm).
>
> BTW. Am on DSL with 1.5 down/768 up
>
> Any ideas for optimization?
>
> Thanks in advance - Dave
I've not been following.... have you looked at using rsync at all? I've
used both NFS and rsync to backup stuff accross the network and most of
my test have shown rsync being faster. It might depend on the type of
data and amount, but it works better for me.
Rsync ( in theory ) copies just the changed data in a file. So... if
you have a 10meg file that 1000 bytes change in, rsync will only copy
the 1000+some-overhead-bytes instead of the hole 10meg file.
Anyway... before you pull your hair out with NFS... you might want to
look at other options.
jack
More information about the Discuss
mailing list