1834058 Members
2470 Online
110063 Solutions
New Discussion

Mirror Disk

 
SOLVED
Go to solution
augusto cossa
Frequent Advisor

Mirror Disk

Good Day all,

Here any one who know the command that can be used to see the mirrored disk.?

Thanks
Augusto
7 REPLIES 7
Andy Monks
Honored Contributor

Re: Mirror Disk

You probably want to start with :-

vgchange, lvdisplay and pvdisplay
Andy Monks
Honored Contributor

Re: Mirror Disk

You probably want to start with :-

vgdisplay, lvdisplay and pvdisplay
Andreas Voss
Honored Contributor
Solution

Re: Mirror Disk

Hi,

with lvdisplay you can see if a lvol is mirrored:
lvsdisplay /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 <<<< look here <<<<
Consistency Recovery MWC
Schedule parallel
LV Size (Mbytes) 48
Current LE 12
Allocated PE 24
Stripes 0
Stripe Size (Kbytes) 0
Bad block off
Allocation strict/contiguous
IO Timeout (Seconds) default

To see where the origs and mirrors are stored use lvdisplay -v.
lvdisplay -v /dev/vg01/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) 48
Current LE 12
Allocated PE 24
Stripes 0
Stripe Size (Kbytes) 0
Bad block off
Allocation strict/contiguous
IO Timeout (Seconds) default

--- Distribution of logical volume ---
PV Name LE on PV PE on PV
/dev/dsk/c1t6d0 12 12
/dev/dsk/c1t5d0 12 12

--- Logical extents ---
LE PV1 PE1 Status 1 PV2 PE2 Status 2
0000 /dev/dsk/c1t6d0 0000 current /dev/dsk/c1t5d0 0000 current
0001 /dev/dsk/c1t6d0 0001 current /dev/dsk/c1t5d0 0001 current
0002 /dev/dsk/c1t6d0 0002 current /dev/dsk/c1t5d0 0002 current
0003 /dev/dsk/c1t6d0 0003 current /dev/dsk/c1t5d0 0003 current
0004 /dev/dsk/c1t6d0 0004 current /dev/dsk/c1t5d0 0004 current
0005 /dev/dsk/c1t6d0 0005 current /dev/dsk/c1t5d0 0005 current
0006 /dev/dsk/c1t6d0 0006 current /dev/dsk/c1t5d0 0006 current
0007 /dev/dsk/c1t6d0 0007 current /dev/dsk/c1t5d0 0007 current
0008 /dev/dsk/c1t6d0 0008 current /dev/dsk/c1t5d0 0008 current
0009 /dev/dsk/c1t6d0 0009 current /dev/dsk/c1t5d0 0009 current
0010 /dev/dsk/c1t6d0 0010 current /dev/dsk/c1t5d0 0010 current
0011 /dev/dsk/c1t6d0 0011 current /dev/dsk/c1t5d0 0011 current

As in the above example you can see that data is stored on /dev/dsk/c1t6d0 and the mirrors on /dev/dsk/c1t5d0

For viewing all LVM infos i've put you a script at attachment.

Regards
augusto cossa
Frequent Advisor

Re: Mirror Disk

Andy,

My server is actualy mirrored but to prove to any one without going to the computer room and see the disks, I would like to issue one command which will display the information regarding all disks and saying what disk is mirroring what.

For example:

Suppose I have 3 disk that are mirrored by other 3, so:

disk 01 mirrored by disk 04

Thanks
James R. Ferguson
Acclaimed Contributor

Re: Mirror Disk

Hi:

# lvdisplay /dev/vg??/lvol?

Among other things this tells you the state of the logical volume -- available/stale or available/syncd, etc. along with the number of mirrors (0,1,2).

# vgdisplay -v /dev/vg??

Including the '-v' option allows you to see the logical volume status such as available/state or available/syncd AND ALSO the physical volume status of the mirrors.

# pvdisplay -v /dev/dsk/c?t?d?

Including the '-v' option allows you to see additional information such as free/used/stale extent status.

# lvlnboot

I'm adding this one since the creation of a mirrored boot disk requires some extra steps. lvlnboot is a quick check to make sure your mirrored root disk is truly bootable.

For a good guide to creating mirror disk, see the System Administration Tasks manual. Of course, read the man pages for the above commands too! Good luck.

...JRF...
Andreas Voss
Honored Contributor

Re: Mirror Disk

Hi,

try my script with -v option.
This gives a brief of what lvols are stored/mirrored on what disks.

Regards
박수정
Advisor

Re: Mirror Disk

Hi!

Use lvlnboot, vgdisplay, pvdisplay,
lvdisplay command


1. #lvlnboot -v
2. #vgdisplay -v vg00
3. #lvdisplay -v /dev/vg00/lvol3