From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fee84,6f6a1245ad443fb3 X-Google-Attributes: gidfee84,public From: Knut Vietze Subject: Re: Booting another kernel Date: 1997/12/05 Message-ID: <3487F330.FF6@theory.phy.tu-dresden.de>#1/1 X-Deja-AN: 295449638 References: <34868DDC.19E8@boat.bt.com> Organization: MPI fuer Physik komplexer Systeme Dresden Newsgroups: comp.unix.osf.osf1 Pete Beglan wrote: > > An interesting question has been posed to me regarding the Digital Unix > boxes running V3.2G that I administer. > > At one of our remote sites a developer managed to rm * from / as root!! > > My normal getout would be to rebuild the OS with a minimal config (1/2 > hr) and restore from backup (1Hr - we are using advfs). > > However since only the root partition has gone I am being asked to boot > from another kernel and then run vrestore of / > > :-) I don't think it is possible but I agreed to give it a shot. > Ok, at least it *should* be possible. > I have tried: > > set boot_flags /usr/sys/node/vmunix This will work ONLY if /usr is a simple directory, not a filesystem. The boot loader (osf_boot) and the kernel (vmunix) MUST reside on the same physical unit (partition). > > then boot > > the machine failed in the boot sequence saying that it couldn't find > osf_boot Sure. It's been nuked by rm /* > > Any ideas...... > Yep. In the above case (a simple rm) the bootblocks on the partition should have been left undisturbed. Only the bootloader and kernel (amongst others of course) are gone, but they are plain files. Suggestion: Boot the machine from where you want (network using mop, CD-ROM, tape or whatever, providing a kernel which supports at least the hardware of your machine neccessary for restores), stick into maintenance mode (if you're booting from an installation media), mount the nuked root partion to anywhere you want and cp the bootloader (osf_boot) and kernel to the partition. (Alternatively you can remove the concerning hard disk and mount it on another machine). If no bootloader is to be found (for instance on CD-ROM), mount the original /usr partition (if any) and try to cp /usr/sys/bin/sboot (should be the unstripped version of the bootloader) to /osf_boot. Reboot and restore the rest. If no -r switch was present at the crucial operation there should be only a few files and/or symlinks to be restored. > Regards > > Pete Beglan :-)) Hope this gives a hint. If you try, please mail/post a statement if this worked. I'm glad not to had to test it yet ;-) Knut -- +----------------------------------------------+ | Knut Vietze, vietze@theory.phy.tu-dresden.de | | vietze@iws.fhg.de | | | | No RISC - No Fun ! | +----------------------------------------------+