[comp.sys.apollo] disk copy

houghton@iuvax.cs.indiana.edu (Ric) (03/29/90)

   Is there anyway to do a complete diskcopy from one disk to another?
 
   It doesn't seem possible to do this with wbak/rbak, but I may be 
   missing something.

    I'm purchasing a larger disk and I'm not real excited about 
 reinstalling the operating system.  (In fact, this is going to
 side effect several of my machines because I'm going to be swapping
 several disks around.)

    Thanks for any help,

      Ric Houghton
      houghton@iuvax.cs.indiana.edu

 look ma, no .sig

rees@dabo.ifs.umich.edu (Jim Rees) (03/29/90)

In article <40087@iuvax.cs.indiana.edu>, houghton@iuvax.cs.indiana.edu
(Ric) writes:
> 
>    Is there anyway to do a complete diskcopy from one disk to another?
>  
>    It doesn't seem possible to do this with wbak/rbak, but I may be 
>    missing something.
> 

"cpt -pdt -sacl" should do it.  Or "tar A |tar A".  Maybe even cpio.  And
wbak/rbak should do it too, but I've never been able to figure out how to
use them.  Or you could do "dd if=/dev/wn0a of=/dev/wn1a" (just kidding; it
will work but it's not what you want).

You'll run into problems if you try to move a bootable volume this way.  Be
particularly careful of /sysboot.  If you accidentally delete it, I don't
know of any way to get it back.  The boot prom doesn't find it by going
through the file system, it's got the block numbers (2-11) hard-wired.
Domain_OS tries to protect you from shooting yourself but I'm not sure
whether it always succeeds -- it may be possible to remove the name even if
you can't delete the blocks.

Then there is a bunch of other stuff, like the hint file, that will confuse
the OS if you just copy it.  If you know what you're doing it's possible,
but I would strongly recommend you re-install.  It doesn't take all that long.

rimbold@apollo.HP.COM (Robert Rimbold) (03/30/90)

In article <40087@iuvax.cs.indiana.edu> houghton@iuvax.cs.indiana.edu (Ric) writes:
>
>
>   Is there anyway to do a complete diskcopy from one disk to another?
> 
>   It doesn't seem possible to do this with wbak/rbak, but I may be 
>   missing something.
>
>    I'm purchasing a larger disk and I'm not real excited about 
> reinstalling the operating system.  (In fact, this is going to
> side effect several of my machines because I'm going to be swapping
> several disks around.)

An OS can successfully be duplicated with the cpt command. I've done it before.
There are a few basic caveats to the method.

- You will have to use cpboot to locate the sysboot image correctly the
	destination system.

- When copying to systems with different hardware configurations than the
	master copy, you must make sure that all the supporting software
	exists. This includes things like type managers, diagnostics, and
	microcode.

- Re-create the pseudo terminals in /dev with the command /etc/crpty once
	the disk has been installed on a system with a different node ID
	(UIDs are encoded into the pty devices).

You will need to make sure that the master copy isn't booted while it's
being copied from (files would be locked).

I'd suggest a command line of:

/com/cpt /source /destination -sacl -pdt -l

'Rob


Disclaimer: Of course, I speak only for myself and neither HP/Apollo nor
myself support this method. Do it at your own risk, keep backups, and never
overrwrite your source disk until you're *really* sure everything works.