Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

copying between two directories on an nfs server

Tags:

file-io

nfs

If I have two directories on an nfs server, between which I would like to copy a large amount of data (in several thousand files, rather than one large block), is there any way to optimize this to be a "local" copy on the server? Does NFS do this automatically, and if not, is there an option to enable it to do so, or is there some inevitable hit on the client? sshing into the nfs server is not an option, sadly - the nfs mount is the only access I have to it.

like image 360
Martin DeMello Avatar asked Feb 10 '09 02:02

Martin DeMello


1 Answers

No, NFS doesn't do this, unfortunately. There is no provision in the protocol for the source of the copy to know anything about the destination or vice versa.

Without ssh or similar access, you can't do anything other than drag every byte across the network to the client, and send it back across the network to the server, a block at a time.

You might get some speed-up if you can use tar or dd or some other command where you can modify the block size. But I wouldn't bet on it.

like image 100
Paul Tomblin Avatar answered Dec 17 '22 07:12

Paul Tomblin