Unix disk copy using dd ?

Andy Piercy andy.piercy at gmail.com
Fri May 4 03:39:48 CDT 2007


So basically you can only use dd to copy to a disk of the same size.

OK so here is the real issue:

I have a faulty Unis system disk that is 142 Mb, it had the sticky bumpers
issue, now repaired but I want to copy the OS and apps to a second
replacement disk, this is a 442 Mb drive.

There seems to be a bug with the standalone floppies in that the restore
program will not restore dump tapes created and verified in single user
mode. bummer!

I only have the Unix OS distribution floppies and not the applications.

So can I rebuild a working disk by..

1) Use the floppies to build a new operating system on to the 442Mb drive.

2) Mount the faulty 144 Mb drive with all of the apps etc.

3) Copy using cp, tar, cpio, all of the contents from the faulty drive to
the new drive and over write
all of the os, will this work? Unix should be in memory so maybe the system
wont crash? (would cp -r be the best command here)

4) Remake the root \Unix file from all of the newly copied data / files

5) Reboot the system..... and hope!

Any ideas on this approach?

Or I could create a second partition and copy the files from the faulty
drive to the it? and copy over the contents, but basically the same as above
because the app files are all over the file system.....

Or how about creating a complete cpio disk image to cart tape?

Ta,

Andy.








On 03/05/07, Dave McGuire <mcguire at neurotica.com> wrote:
>
> On May 3, 2007, at 4:23 PM, Doc Shipley wrote:
> >>> dd also seems to have some implementation-specifics
> >>> baked into it. On Solaris I was completely unable to
> >>> transfer a raw VMS disk image from one drive to
> >>> another (identical) one using dd; however the same
> >>> transfer worked correctly under Linux.
> >>   This is not dd, but the disk device drivers underlying OS.
> >
> >   More specifically, it's the Solaris volume manager, isn't it?  I
> > forget the specific incantation, but it is possible to tell Solaris
> > "Forget aboit" and treat a disk as a raw resource.
>
>   Nope, nothing at all to do with the volume manager.  All it does
> is deal with things like automatically mounting filesystems when they
> come up, such as when a CDROM is inserted.
>
>   The issue concerns partitioning and where "data" starts on the
> disk...and most importantly, whether or not that data includes the
> block containing the partition table.  Traditionally, the "c"
> partition on a Unix system means "the whole disk" but unfortunately
> (from what I've seen) that doesn't include the block containing the
> partition table on some systems.
>
> >   It's probably a good thing for most users/workloads, but mostly
> > Sun's volume manager just irritates me.
>
>   Same here.  Edit /etc/vold.conf to make it ignore the stuff you
> want it to.
>
>            -Dave
>
> --
> Dave McGuire
> Port Charlotte, FL
>
>
>


More information about the cctalk mailing list