[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: dd or cp over network: should I use scp?



On Thu, 2011-02-24 at 13:41 +0100, Sjoerd Hardeman wrote:
> Dotan Cohen schreef:
> > I need to dd or cp my laptop's harddrive over the LAN. For a reason
> > that I'd rather not get into I cannot remove the drive from the
> > laptop.
> > 
> > Should I just use scp to copy over the LAN? Something like this?
> > scp -r / root@178.63.65.136:/
> I would use rsync, as it allows compression
> 
> rsync -aAXxPz / root@178.63.65.136:/
> where -a preserves permissions, modification times etc
> -A preserves acls
> -X preserves xattrs
> -x keeps you in one filesystem (so you won't copy /dev etc.)
> -P keeps partial copied files for faster stop-and-proceed, and shows a 
> progress bar
> -z compresses the data stream
> 
> This should give you an identical copy. Good luck!

What about hardlinks? I've always stuck to dd because I'm not confident
rsync will give me an exact enough copy to completely restore the
original from. 

-- 
Tixy               ()  The ASCII Ribbon Campaign (www.asciiribbon.org)
                   /\  Against HTML e-mail and proprietary attachments



Reply to: