Translate

Wednesday, 13 August 2014

Importing a new Volume Group

Accidentally importing a disk that has a root volume group can have disasterous results on your AIX system because it renames the logical-volumes required to boot your system, therefore you should know something  about a disk or disks before you attempt to import them.

Here are some handy LVM commands that help you to see what is on a disk(s) without importing:

List the maximum number of logical volumes allowed in the VG
# lqueryvg -p PVname -N

Show the PP size ?
# lqueryvg -p PVname -s

Show the number of free PPs in the VG
# lqueryvg -p PVname -F

Show the current number of LVs in the VG
# lqueryvg -p PVname -n

List the current number of PVs in the VG
# lqueryvg -p PVname -c

Display the total number of VGDAs for the VG
# lqueryvg -p PVname -D

List each LVID, LV name, state for each logical volume
# lqueryvg -p PVname -l

List each PVID, number of VGDAs and state for each PV in the VG
# lqueryvg -p PVname -P

List all the attributes with tags for the vG
# lqueryvg -p PVname -At

Show a physical volume' VGID
# lqueryvg -p PVname -v

Move a physical partition
# lmigratepp -g VGID -p old_PVID -n old_PPNum -P new_PVID -N new_PPNum

Retrive the VG name for a particular LV from ODM
# getlvodm -b LVID

Retrive all configured PVs from ODM
# getlvodm -C

Retrive the major number for a VGID from ODM
# getlvodm -d VGID

Retrive the logical volume allocation characteristics for a LVID from ODM
# getlvodm -c LVID

Retrive the free configured PVs from ODM
# getlvodm -F

Retrive the strip size for a LVID from ODM
# getlvodm -F LVID

Retrive the PV name for a PVID from ODM
# getlvodm -g PVID

Retrive all VG names from the ODM
# getlvodm -h

Retrive the VGID for a PVID from ODM
# getlvodm -j PVID

Retrive the LVs and LVIDs for a VG name or VGID from ODM
# getlvodm -L VGDescriptor

Retrive the LVID/LV Name for a LV Name or LVID from ODM
# getlvodm -l LVDescriptor

Retrive the mount point for a LVID from ODM
# getlvodm -m LVID

Retrive the stripe width for a LVID from ODM
# getlvodm -N LVID

Retrive the PVID/PN name for a PV name or PVID from ODM
# getlvodm -p PVDesciptor

Retrive the PV names, PVIDs and VGs of all configured PVs from ODM
# getlvodm -P

Retrive the relocatable flag for a LVID from ODM
# getlvodm -r LVID

Retrive the VG state for a VG from ODM
# getlvodm -s VGDescriptor

Retrive the timestamp for a VG from ODM
# getlvodm -T VGDescriptor

Retrive the VG name for a VGID from ODM
# getlvodm -t VGID

Retrive the auto-on value for a VG name or VGID from ODM
# getlvodm -v VGDesciptor

Retrive the VGID for a vG name
# getlvodm -v VGDesciptor

Retrive the PV names and PVIDs for a VG from ODM
# getlvodm -w VGDesciptor

How to retrive the LV type for a LVID from ODM
# getlvodm -y LVID

How to retrive the concurrent capable flag for a VG from ODM
# getlvodm -X VGDescriptor

How to retrive the auto-on concurrent flag for a VG from ODM
# getlvodm -x VGDescriptor

Display the contents of LVCB
# getlvcb -A LVName

List the number of copies of a LV from LVCB
# getlvcb -c LVName

List the file system name of a LV from LVCB
# getlvcb -f LVName

List the label of a LV from LVCB
# getlvcb -L LVName
Display the type of the file system from LVCB
# getlvcb -t LVName

Display the upper limit from LVCB
# getlvcb -u LVName

No comments:

Post a Comment