OT: cloning (copying) a HD over a network...
Ed K.
ed at hp.uab.edu
Sat Apr 9 03:24:52 UTC 2005
On Fri, 8 Apr 2005, Kim Lux wrote:
> The hard drive is full on our server. I can ssh into it from my
> workstation. I've got a formatted drive mounted on my workstation ready
> to receive the server files.
>
> How do I easily copy the server files to the workstation drive over our
> network ? Keep in mind that I need to preserve the file ownership,
> permissions and dates.
>
> If I had the new hard drive mounted on the server, I would use:
>
> cp -aR /olddrive /newdrive >> logfile
>
> I've tried using scp, but I cannot force it to preserve the file
> attributes.
>
> I've tried using sftp, but I don't think it is recursive and I can't
> force it to preserve attributes.
>
> I'm trying to use tar, but I can't figure out how to make it work across
> a network. FWIW, I have sshd enabled on the server, but not on the
> workstation. I don't have nfs enabled on the server. Can I do this
> without enabling it ?
>
> Any hints would be appreciated.
>
> --
> Kim Lux, Diesel Research Inc.
>
If encryption is not the issue - but speed is, use tar and mbuffer
http://www.rcs.ei.tum.de/~maierkom/privat/software/mbuffer/
on source computer:
tar -cf - / |mbuffer -m 50M -O {dest. ip}:{port}
and on dest computer:
mbuffer -m 50M -I {src. ip}:{port} | tar -xf -
and watch the files fly. This is how I normally move 20G of files from
computer to computer.
ed
More information about the users
mailing list