AIX – LV partially mirrored

If a LV is partially mirrored when you isse the “lsvg -l vgname” command do following:

————————
lsvg -l rootvg

said:

0516-1147 : Warning – logical volume hd2 may be partially mirrored.

lslv -m hd2

hd2:/usr

LP PP1 PV1 PP2 PV2 PP3 PV3

0001 0134 hdisk0 0179 hdisk1

0002 0135 hdisk0 0180 hdisk1

0003 0136 hdisk0 0181 hdisk1

….

0133 0298 hdisk0 0247 hdisk1

0134 0299 hdisk0 0248 hdisk1

0135 0301 hdisk0

0136 0302 hdisk0

0137 0303 hdisk0

0138 0304 hdisk0

0139 0305 hdisk0

0140 0306 hdisk0

0141 0307 hdisk0

/usr/sbin/mklvcopy hd2 2 hdisk1

0516-1509 : VGDA corruption: physical partition info for this LV is invalid.

0516-842 : Unable to make logical partition copies for logical volume.

/usr/sbin/mklvcopy hd2 2 hdisk1

0516-1509 : VGDA corruption: physical partition info for this LV is invalid.

0516-842 : Unable to make logical partition copies for logical volume.

solved via this way:

get your LVID (lslv hd2)

LVID=00c9ae1e00004c0000000102cae30aba.5

Get the numbers of the PP’s which are wrong (lslv -m):

you need the columns “LP PP2 PV2” from lslv -m hd2

LP PP2 PV2

0001 0214 hdisk25

0002 0215 hdisk25

0003 0216 hdisk25

0004 0217 hdisk25

0005 0218 hdisk25

0006 0219 hdisk25

0007 0220 hdisk25

0008 0221 hdisk25

0009 0222 hdisk25

0010 0223 hdisk25

0011 0224 hdisk25

0012 0225 hdisk25

0013 0226 hdisk25

0014 0227 hdisk25

0015 0228 hdisk25

0016 0229 hdisk25

get your PVID (lspv hdisk25)

for example…PV IDENTIFIER: 00ccbfaf91e1da9a

now create a textfile where only the following info appears:

PVID PP# LP# (separated with blanks)

without having your PVID, here is an example with your data and my example_PVID:

00ccbfaf91e1da9a 0214 0001

00ccbfaf91e1da9a 0215 0002

00ccbfaf91e1da9a 0216 0003

00ccbfaf91e1da9a 0217 0004

00ccbfaf91e1da9a 0218 0005

00ccbfaf91e1da9a 0219 0006

00ccbfaf91e1da9a 0220 0007

00ccbfaf91e1da9a 0221 0008

00ccbfaf91e1da9a 0222 0009

00ccbfaf91e1da9a 0223 0010

00ccbfaf91e1da9a 0224 0011

00ccbfaf91e1da9a 0225 0012

00ccbfaf91e1da9a 0226 0013

00ccbfaf91e1da9a 0227 0014

00ccbfaf91e1da9a 0228 0015

00ccbfaf91e1da9a 0229 0016

save this file, then you need the number of lines in this file:

Number=`wc -l “YOUR TEXTFILE”`

lreducelv -l $LVID -s $Number “YOUR TEXTFILE”

Now the lvm deallocates all PP’s of your partially mirror.

After that, I made also the following changes (this came from the shellscript rmlvcopy):

COPYNUM=1

putlvodm -c $COPYNUM $LVID

putlvcb -c $COPYNUM hd2

THEN I was able to mirror my hd2 again…without any problems.

The
most of the help for solving this problem came from “rmlvcopy”, and the
Redbook “AIX LVM from A to Z-Troubleshooting and Commands” (Book
sg245433)

——————————

this howto was found somewhere on the web.

Advertisements
This entry was posted in aix and tagged . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

w

Connecting to %s