Re: [opensuse] hard drive replacement question



James Knott wrote:
Per Jessen wrote:
David C. Rankin wrote:


Forget rsync, 'dd' is your friend here. The replacement can be as
simple as hooking your new drive up and doing "dd old new", remove
old, reboot, done! We'll call the new drive /dev/sdb for this example
and /dev/sda the old, then just hook your new driver up, then:

dd if=/dev/sda of=/dev/sdb

David, that way Bob will end up with an exact copy of his old 8Gb drive,
which is (probably) good/useful, but he'll also have no use for the
remaining gigabytes - the new drive is likely to be 160G or bigger.


I thought partitions could be enlarged. So, set up as an 8GB and then
go from there.



Yes,

The main purpose of suggesting dd, was that Bob will also get the master boot
record copied. That way he never even has to worry about sticking an install
disk in the cd drive;-)

As for the disk size thing, let's say Bob's 8G drive is partitioned as:

/dev/sda1 100M mounted as /boot
/dev/sda5 3G mounted as /
/dev/sda6 4G mounted as /home
/dev/sda7 900M swap

Let's say new drive is 500G. After dd, then Bob can just create additional
partitions out of the unused space. If / is tight because /var is getting close
to full, then just cfdisk create a new 10G extended partition /dev/sda8, mount
/dev/sda8 /mnt/tmp; cp -a /var/* /mnt/tmp; umount /mnt/tmp; rm -r /var; mount
/dev/sda8 /var.

If bob was going to upgrade to 11 or 11.1, then of course I'd just unplug the
current hard drive, install the new, install openSuSE, the plug the old hard
drive back in as a slave and then rsync -a or cp -a all the data from /old /new


--
David C. Rankin, J.D.,P.E.
Rankin Law Firm, PLLC
510 Ochiltree Street
Nacogdoches, Texas 75961
Telephone: (936) 715-9333
Facsimile: (936) 715-9339
www.rankinlawfirm.com
--
To unsubscribe, e-mail: opensuse+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse+help@xxxxxxxxxxxx



Relevant Pages

  • Re: [opensuse] complex confusing partition problem
    ... Another install you forgot about, ... only one 10.2 was installed on hdb. ... the hdb disk and renamed it sdc. ... One thing that helps is to have all partitions "labeled". ...
    (SuSE)
  • Re: Replace SCSI Drive
    ... from there you can manipulate other hard drives attached to the machine. ... It should 'just work' but watch out that you keep disk devices ... vi-a) Write a BSD partition table into the slice, then set up your required FreeBSD partitions: ... items under the 'Custom Install' to achieve the desired result. ...
    (freebsd-questions)
  • Re: [opensuse] complex confusing partition problem
    ... copy over some of my stuff from the 10.2 install. ... disk and renamed it sdc. ... Some of your old partitions have labels, but not the new ones in the new disk. ... I renamed the good 10.2 to plain "SUSE" for clarity ...
    (SuSE)
  • Re: 9.0-RELEASE amd64 Bricked My Hard Drive
    ... Newer pc's have bios that use gpart format disk partition layouts so for FreeBSD to be compatible with new PC hardware, Bsdinstall defaults to using the gpart format disk partition layouts. ... Bsdinstall provides no automatic way to create format partitions. ... then on same disk pc install 8.2 and reboot. ...
    (freebsd-questions)
  • Re: non-repairable clusters and unneeded partitions
    ... Will the partitions also transfer to the new HDD using that software? ... CDs to install the computer to its original state on a new HDD. ... A disk without partitions is useless. ...
    (microsoft.public.windowsxp.general)