Gentoo Archives: gentoo-user

From: Volker Armin Hemmann <volkerarmin@××××××××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] backup sanity check
Date: Sat, 14 Aug 2010 10:03:33
Message-Id: 201008141107.27526.volkerarmin@googlemail.com
In Reply to: [gentoo-user] backup sanity check by Adam Carter
1 On Saturday 14 August 2010, Adam Carter wrote:
2 > This is to backup my laptop from boot cdrom - how does it look?
3 >
4 > File systems;
5 > /dev/sda1 - /boot
6 > /dev/sda2 - swap
7 > /dev/sda3 - /
8 >
9 > So to backup;
10 > 1. Get MBR (grub and partition table): dd if=/dev/sda
11 > of=/otherdisk/sda-mbr.bin bs=512 count=1
12 > 2. Get /boot: dd if=/dev/sda1 of=/otherdisk/sda1.bin
13 > 3. Get /: dd if=/dev/sda3 | gzip | dd of=/otherdisk/sda3.bin.gz
14 >
15 > Then too restore onto new disk;
16 > 1. Restore MBR: dd if=/otherdisk/sda-mbr.bin of=/dev/sda
17 > - no bs or count parameters required?
18 > 2. Restore /boot: dd if=/otherdisk/sda1.bin of=/dev/sda1
19 > 3. Restore /: dd if=/otherdisk/sda3.bin.gz | gunzip | dd of=/dev/sda3
20 > 4. Setup swap partition: mkswap /dev/sda2
21 > 5. Boot system
22 >
23 > Caveat is the the new disk must be big enough to fit sda1/2/3.
24
25 why backup mbr? installing grub takes less time then the backup and restore of
26 the mbr.
27
28 And dd for backups? Why wasting space? Why suffering from problems when the new
29 harddisk has a different size?
30 Just tar up everything.

Replies

Subject Author
Re: [gentoo-user] backup sanity check Adam Carter <adamcarter3@×××××.com>