Operating System - HP-UX
1833882 Members
2156 Online
110063 Solutions
New Discussion

Re: where from here: /dev/root

 
Bojan Andjelkovic
Occasional Contributor

where from here: /dev/root

Hi everybody, please I do need some directions and explanations , what is happen and why.

Scenario:
after primary boot disk failure, the disk replacement and re-mirroring, the box couldn't boot from primary.
So, secondary disk has been used to enter ISL
and from there into lvm maintenance mode:

ISL> hpux -lq -lm
Now bdf looks like:
Filesystem kbytes used avail %used Mounted on
/dev/root 143360 42129 96798 30% /
/dev/vg00/lvol1 83733 29220 46139 39% /stand

Now box is running, apps and dbs are up.
What would be recommended action from here ( /dev/root ) back to normal ?

Thanks,
Bojan
7 REPLIES 7
Massimo Bianchi
Honored Contributor

Re: where from here: /dev/root

/dev/vg00/lvol is mounted as /dev/root when you startup in maintenance mode (hpux -lm ...)


to get the thing straight back, just


rm /etc/mnttab
mount -p
bdf

it only an apparent issue, all is right.

Massimo

Michael Steele_2
Honored Contributor

Re: where from here: /dev/root

Never, ever, ever go above single user mode when using LVM maintenance mode:

ISL> hpux -lq -lm

NEVER!

Very likely that your O/S file systems became corrupt.

REBOOT! And come up to run level three normally:

# set_boot -p 0/0.#.# (* HW path of alternate boot disk *)

-or- single user mode without LVM maintenance and then init 3!
Support Fatherhood - Stop Family Law
Bojan Andjelkovic
Occasional Contributor

Re: where from here: /dev/root

Thanks Michael and Massimo,

So, it would be dangerous to proceed with
re-mirroring right now,
once the box is back to init 3 normally,
as you suggested, re-mirroring can be done again, am I correct ?

Thx,
Bojan

Paulo A G Fessel
Trusted Contributor

Re: where from here: /dev/root

Probably, you re-created your primary volume without making it really bootable.

To make the primary disk bootable, never forget these steps:

1. pvcreate -B /dev/rdsk/
2. vgextend /dev/vg00 /dev/dsk/
3. mkboot /dev/dsk/
4. mkboot -a "hpux -lq" /dev/rdsk/
5. lvextend -m 1 /dev/vg00/lvol1 /dev/dsk/
6. lvlnboot -R

If you have forgot one of these steps, then I fear you'll have to recreate and remirror the primary disk.

HTH
Paulo Fessel
L'employé propose, le boss dispose.
Todd McDaniel_1
Honored Contributor

Re: where from here: /dev/root

Paulo,

Your step about mirroring should be -m 0 b/c it is his Primary disk that is bad currently...

However, he shouldnt need to worry about the mirror if he vgsync after making the disk bootable...

Here is what I did once on a bad mirrored root disk that failed.

lvreduce -m 0 /dev/vg00/dump /dev/dsk/c4t6d0
lvreduce -m 0 /dev/vg00/var /dev/dsk/c4t6d0
lvreduce -m 0 /dev/vg00/stand /dev/dsk/c4t6d0
lvreduce -m 0 /dev/vg00/root /dev/dsk/c4t6d0
lvreduce -m 0 /dev/vg00/opt /dev/dsk/c4t6d0
lvreduce -m 0 /dev/vg00/usr /dev/dsk/c4t6d0
lvreduce -m 0 /dev/vg00/swap dev/dsk/c4t6d0

vgreduce /dev/vg00 /dev/dsk/c4t6d0

pvcreate -B /dev/rdsk/c4t6d0

vgextend /dev/vg00 /dev/dsk/c4t6d0

mkboot /dev/rdsk/c4t6d0

mkboot -a "hpux -lq" /dev/rdsk/c4t6d0

lifcp /dev/dsk/c4t6d0:AUTO

mkboot -b updatediaglif -p ISL -p AUTO -p HPUX -p LABEL /dev/rdsk/c4t6d0

mkboot -b /usr/sbin/diag/lif/updatediaglif -p ISL -p AUTO -p HPUX -p LABEL /dev/rdsk/c4t6d0

vgcfgrestore -n /dev/vg00 /dev/rdsk/c4t6d0

vgchange -a y /dev/vg00

vgsync /dev/vg00
Unix, the other white meat.
Paulo A G Fessel
Trusted Contributor

Re: where from here: /dev/root

Todd

These are the steps to be taken AFTER the disk has been replaced.

Cheers,
Paulo
L'employé propose, le boss dispose.
Kent Ostby
Honored Contributor

Re: where from here: /dev/root

Bojan --

All that the entry of /dev/root means in your bdf is that at sometime you booted into -lm.

It does not indicate corruption of any type and can be easily fixed once you do a clean reboot to multi-user mode.

All you will need to do is to clear the mnttab.

If you want to make a backup, then do:

cd /etc
cp mnttab mnttab.bojan
rm mnttab
mount -a

This will clear up the /dev/root line.

Best regards,

Kent M. Ostby

PS with regards to booting -lm then going up, while it is not recommended, I havent seen any huge problems with it.

I suggest that any changes you have made in that mode are fine. Just do a clean reboot to make sure that it will all come up fine the next time.

Best regards,

Kent M. Ostby
"Well, actually, she is a rocket scientist" -- Steve Martin in "Roxanne"