Operating System - HP-UX
1829636 Members
1784 Online
109992 Solutions
New Discussion

Re: how to check mirror status and procedure of remirror ?

 
SOLVED
Go to solution
Shah Gaurang B.
Frequent Advisor

how to check mirror status and procedure of remirror ?

1)i have two scsi normal (not hotswap) mirored harddisk in hp-ux . Now i would like to check whether mirroring is ok or not ? so what are the command to observer of mirroring

2) what are the procedure if one mirrored harddisk failed than to do remirrored with new harddisk and put it in previous position .
5 REPLIES 5
Sยภเl Kย๓คг
Respected Contributor
Solution

Re: how to check mirror status and procedure of remirror ?

Hi,

Mirroring in HPUX happens in lvol level. You need to use
#lvdisplay to check wether the LV has a mirror copy or not.


Eg1 :lvdisplay /dev/vg00/lvol1
--- Logical volumes ---
LV Name /dev/vg00/lvol1
VG Name /dev/vg00
LV Permission read/write
LV Status available/syncd
Mirror copies 1
Consistency Recovery MWC
Schedule parallel
LV Size (Mbytes) 304
Current LE 38
Allocated PE 76
Stripes 0
Stripe Size (Kbytes) 0
Bad block off
Allocation strict/contiguous
IO Timeout (Seconds) default

Eg2: lvdisplay /dev/vg00/lvol1
--- Logical volumes ---
LV Name /dev/vg00/lvol1
VG Name /dev/vg00
LV Permission read/write
LV Status available/stale
Mirror copies 1
Consistency Recovery MWC
Schedule parallel
LV Size (Mbytes) 304
Current LE 38
Allocated PE 76
Stripes 0
Stripe Size (Kbytes) 0
Bad block off
Allocation strict/contiguous
IO Timeout (Seconds) default

Eg2: lvdisplay /dev/vg_sbi_exim_db/eximsbi_CTRL_02.ctl
--- Logical volumes ---
LV Name /dev/vg_sbi_exim_db/eximsbi_CTRL_02.ctl
VG Name /dev/vg_sbi_exim_db
LV Permission read/write
LV Status available/syncd
Mirror copies 0
Consistency Recovery MWC
Schedule striped
LV Size (Mbytes) 320
Current LE 40
Allocated PE 40
Stripes 8
Stripe Size (Kbytes) 4096
Bad block on
Allocation strict
IO Timeout (Seconds) default

First Example show that the LV is mirrored and all disks in that LV are available, wherein second example, this LV is a mirrored one, but some PEs are not in sync. So you need to use the #lvdisplay -v to identify which all are the LVs' not in sync and check vgdispaly -v for which disk are unavailable.

Third example shows an which is not mirrored.

Regards,
Sunil
Your imagination is the preview of your life's coming attractions
Sยภเl Kย๓คг
Respected Contributor

Re: how to check mirror status and procedure of remirror ?


Hi,

Sorry in my previous post Eg3 is the last example, which i have mentioned by mistake as eg2.

To remirror failed mirror disk.


1. lvreduce -m 0 (needs to be done for all LVs which belongs to the failed disk)
2. vgreduce
3. Replace the disk, ioscan -fnC disk, insf
4. pvcreate the new disk
5. vgextend
6. lvextend -m 1 ( do it for all lvols in that VG)

The lvdisplay -v to verify the mirror consistancy

regards,
Sunil
Your imagination is the preview of your life's coming attractions
Sivakumar TS
Honored Contributor

Re: how to check mirror status and procedure of remirror ?


Dear Shah,

Try this,

#lvdisplay -v | grep stale

If this doesnt display any stale extents then you can be happy...the mirror is OK. You can use this as a scrpit.

With Regards,

Siva.
Nothing is Impossible !
Devender Khatana
Honored Contributor

Re: how to check mirror status and procedure of remirror ?

Hi,

Hereis a good white paper on replacing disks of any kind configured using LVM.

http://www.docs.hp.com/en/5991-1236/When_Good_Disks_Go_Bad.pdf

I also appreciate your choice of preparing your self in advance for the happenings.

HTH,
Devender
Impossible itself mentions "I m possible"
Sujeesh T
Occasional Contributor

Re: how to check mirror status and procedure of remirror ?

Hi

For checking the progress of synchronization u can use the following command

# lvdisplay -v $(find /dev/vgXY -type b) | grep stale | wc -l

regds
Sujeesh