[TriLUG] Linux Backup and Restore to totally wiped partition

Brian Henning bhenning at pineinst.com
Wed Feb 27 11:53:30 EST 2013


Oh, while we're on the dd topic, a helpful hint everyone might already know:

Sending SIGUSR1 to a dd process will cause it to spit out its progress on
stderr.  When working with images, I often run the following one-liner bash
script on a separate virtual terminal after starting dd:

$ while killall -SIGUSR1 dd; do sleep 3; done

(This assumes there's only one dd process running; otherwise, find out the
PID of your intended dd instance and use kill instead of killall)

That makes dd spit out an update every three seconds, giving me a nice warm
fuzzy that it's still working (and giving me some idea of how long the
process will take).

Cheers,
~B

-----Original Message-----
From: trilug-bounces at trilug.org [mailto:trilug-bounces at trilug.org] On Behalf
Of David Brain
Sent: Tuesday, February 26, 2013 6:29 PM
To: Triangle Linux Users Group General Discussion
Subject: Re: [TriLUG] Linux Backup and Restore to totally wiped partition

I'be used the following for imaging successfully:

dd if=/dev/sda bs=1024k | gzip -c > image.gz

Can save a bunch of space, especially if the source drive isn't full...

David
 On Feb 26, 2013 4:45 PM, "Brian" <lugmail at cheetah.dynip.com> wrote:

> On 2/26/2013 4:33 PM, Tarus Balog wrote:
>
>> Hrm, I have an external hard drive that I could use for the images. So I
>> would just boot to some linux with dd and then:
>>
>> dd if=/dev/sda of=/path/to/my/harddrive/sys1-**backup
>>
>> and then to restore
>>
>> dd if=/path/to/my/harddrive/sys1-**backup of=/dev/sda
>>
>
> Indeed!  I'd also suggest messing around with the bs= option; I find a
> block size around 1M to perform reasonably well.
>
> ~Brian
>
> --
> This message was sent to: dbrain at gmail.com <dbrain at gmail.com>
> To unsubscribe, send a blank message to trilug-leave at trilug.org from that
> address.
> TriLUG mailing list :
http://www.trilug.org/mailman/**listinfo/trilug<http://www.trilug.org/mailma
n/listinfo/trilug>
> Unsubscribe or edit options on the web  : http://www.trilug.org/mailman/**
>
options/trilug/dbrain%40gmail.**com<http://www.trilug.org/mailman/options/tr
ilug/dbrain%40gmail.com>
> TriLUG FAQ          : http://www.trilug.org/wiki/**
>
Frequently_Asked_Questions<http://www.trilug.org/wiki/Frequently_Asked_Quest
ions>
>
-- 
This message was sent to: Brian <bhenning at pineinst.com>
To unsubscribe, send a blank message to trilug-leave at trilug.org from that
address.
TriLUG mailing list : http://www.trilug.org/mailman/listinfo/trilug
Unsubscribe or edit options on the web	:
http://www.trilug.org/mailman/options/trilug/bhenning%40pineinst.com
TriLUG FAQ          : http://www.trilug.org/wiki/Frequently_Asked_Questions





More information about the TriLUG mailing list