From: ray on
FWIW - I wouldn't use 'dd' for that. I'd rather use something like
partimage - I did that when I replaced the hard drive on my laptop with a
larger one.

On Sat, 26 Jun 2010 15:17:03 -0500, Ohmster wrote:

> I want to try and upgrade from Fedora 12 to Fedora 13 to see if my
> problems with compiz will go away. I am sure a clean install will do and
> I will probably do that anyway, but I want to backup my entire root
> drive to a 2nd IDE disk in the same computer. Here are the disk stats.
> Can someone please give me a working dd command line with proper
> switches to basicly copy the entire disk to the other disk completly so
> that I can either copy it back or pluck from it later on? Thank you.
>
> I am not that good with dd and need to get this done today so I can try
> to install Fedora 13 this weekend, it is the only time I have to do
> this.
>
> My boot system is on /dev/sda, that is the big 400Gb disk. /dev/sdb is
> the smaller IDE 2nd drive that contains my previous OS before this one.
> Thank you.
>
> [ohmster(a)ohmster ~]$ df -h
> Filesystem Size Used Avail Use% Mounted on
> /dev/mapper/vg_ohmster-lv_root
> 364G 78G 268G 23% /
> tmpfs 755M 164K 755M 1% /dev/shm /dev/sda1
> 194M 105M 79M 58% /boot /dev/mapper/VolGroupOld-LogVolOld00
> 179G 77G 93G 46% /mnt/old_sys
>
>
> Device Boot Start End Blocks Id System
> /dev/sda1 * 1 26 204800 83 Linux Partition
> 1 does not end on cylinder boundary. /dev/sda2 26
> 48641 390504001 8e Linux LVM
>
> Device Boot Start End Blocks Id System
> /dev/sdb1 * 1 13 104391 83 Linux /dev/sdb2
> 14 24321 195254010 8e Linux LVM

From: Mike Jones on
Responding to Ohmster:

> I want to try and upgrade from Fedora 12 to Fedora 13 to see if my
> problems with compiz will go away. I am sure a clean install will do and
> I will probably do that anyway, but I want to backup my entire root
> drive to a 2nd IDE disk in the same computer. Here are the disk stats.
> Can someone please give me a working dd command line with proper
> switches to basicly copy the entire disk to the other disk completly so
> that I can either copy it back or pluck from it later on? Thank you.
>
> I am not that good with dd and need to get this done today so I can try
> to install Fedora 13 this weekend, it is the only time I have to do
> this.
>
> My boot system is on /dev/sda, that is the big 400Gb disk. /dev/sdb is
> the smaller IDE 2nd drive that contains my previous OS before this one.
> Thank you.
>
> [ohmster(a)ohmster ~]$ df -h
> Filesystem Size Used Avail Use% Mounted on
> /dev/mapper/vg_ohmster-lv_root
> 364G 78G 268G 23% /
> tmpfs 755M 164K 755M 1% /dev/shm /dev/sda1
> 194M 105M 79M 58% /boot /dev/mapper/VolGroupOld-LogVolOld00
> 179G 77G 93G 46% /mnt/old_sys
>
>
> Device Boot Start End Blocks Id System
> /dev/sda1 * 1 26 204800 83 Linux Partition
> 1 does not end on cylinder boundary. /dev/sda2 26
> 48641 390504001 8e Linux LVM
>
> Device Boot Start End Blocks Id System
> /dev/sdb1 * 1 13 104391 83 Linux /dev/sdb2
> 14 24321 195254010 8e Linux LVM


Start something else (Slack install disk?)...

and then...

Mount source and target partitions somewhere, and then...

cp -a /mnt/source/* /mnt/target

Tadah!

--
*=( http://www.thedailymash.co.uk/
*=( For all your UK news needs.
From: mjt on
On Sat, 26 Jun 2010 15:17:03 -0500
Ohmster <root(a)dev.nul.invalid> wrote:

> I want to try and upgrade from Fedora 12 to Fedora 13 to see if my problems
> with compiz will go away. I am sure a clean install will do and I will
> probably do that anyway, but I want to backup my entire root drive to a 2nd
> IDE disk in the same computer.

Use partimage: http://www.partimage.org/Download

"Using partimage from a livecd is the easiest way to use it. If your
system needs to be restored, running partimage from the hard disk is
not possible. The best livecd for Partimage is SystemRescueCd because
it's created by a member of the partimage project, and this CDRom
contains a lot of great recovery software."

--
If you want your spouse to listen and pay strict attention to every
word you say, talk in your sleep.
<<< Remove YOURSHOES to email me >>>

From: mjt on
On Sun, 27 Jun 2010 21:38:31 -0500
Ohmster <root(a)dev.nul.invalid> wrote:

> > Use partimage: http://www.partimage.org/Download
> >
> > "Using partimage from a livecd is the easiest way to use it. If your
> > system needs to be restored, running partimage from the hard disk is
> > not possible. The best livecd for Partimage is SystemRescueCd because
> > it's created by a member of the partimage project, and this CDRom
> > contains a lot of great recovery software."
[snipped]

> So am I better now with cp - a for this or still partimage? If so, quick
> rundown on how partimage works please as I am not familiar with it but am
> not a total n00b either. Thnx.

Where I was going with "partimage" was for you to download the
SystemRescueCd (iso) and burn it to a CD ... subsequently, you could
boot up the (bootable SystemRescueCd) CD and use it to back up the
partition(s) ... after all, that *was* your original request.

The downside of "dd" is that it will consume as much disk space at the
destination as it does from the source, because it's a byte-by-byte copy.

Please read through the main page: http://www.partimage.org/Main_Page

PartImage is include on SystemRescueCd

SystemRescueCd: http://www.sysresccd.org/Main_Page

--
Going to church does not make a person religious, nor does going to
school make a person educated, any more than going to a garage makes a
person a car.
<<< Remove YOURSHOES to email me >>>

From: Mike Jones on
Responding to Ohmster:

> unruh <unruh(a)wormhole.physics.ubc.ca> wrote in
> news:slrni2oqu0.av8.unruh(a)wormhole.physics.ubc.ca:
>
>
>> Or use rsync to the 200G disk, assuming you will never have more than
>> 200G on the large disk. That way you need only transfer what has
>> changed. You could set it up to be a dropin. transfer the files, and
>> then run lilo/grub so it can boot from that disk. If your main disk
>> fails just boot from the backup and you are back in business. (You will
>> need to change /etc/fstab to refelect the location of the partitions on
>> the new drive rather than the old. )
>>
>>
> Both great ideas.
>
> Can someone give me a tar.tgz command line to backup entire system disk
> ($ooGb nowhere near full) to 200Gb disk? And then a restore command to
> put it all back, like this:
>
> tar.gz the whole 400g disk and store the contents and a restore script
> on the 200g disk
>
> the resore script will partition the new drive and install the files
> from the tar and then run lilo or grub etc to install the boot sector
>
> And the install to 200Gb disk I can handle. This system is working for
> all I need done right now and need a way to put it all back in case I
> have to. Only reason I am wiping to install fresh is because the FC13
> upgrade left so much FC12 stuff on the disk that yum update won't even
> work anymore.
>
> Thnx.


Just like "cp -a /mnt/source/* /mnt/target" clones things, you can
replace cp with "tar"...

#> tar -clpvzf /path/to/clone.tar.gz /mnt/source

....then

#> tar -xpvf /path/to/clone.tar.gz -C /mnt/target

....to restore the clone somewhere.

#> man tar

....is your next stop.

NOTE: If you drop a cloned OS onto a different partition, don't forget to
update /etc/fstab to match it's new home.

TIP: Search "partimage" and "rescuecd"

HINT: Get Slackware!

--
*=( http://www.thedailymash.co.uk/
*=( For all your UK news needs.