Assigning a New Disk From VIO to Lpar in AIX

Embed Size (px)

Citation preview

  • 7/22/2019 Assigning a New Disk From VIO to Lpar in AIX

    1/9

    Assigning a new disk from a VIO to LPAR

    August 11, 2010

    Wipro ConfidentialPage 1 of 9

    Assigning a new disk from a VIO to LPAR

    Author Narasimha Raju Bitla

    Version 1.0

    Date of Creation 11/08/2010

    Wipro Email [email protected]

  • 7/22/2019 Assigning a New Disk From VIO to Lpar in AIX

    2/9

    Assigning a new disk from a VIO to LPAR

    August 11, 2010

    Wipro ConfidentialPage 2 of 9

    Change History:

    Revision Date Author Comments

    1.0 11/08/2010 Narasimha Raju

    Bitla

    Initial creation

    1.1

    1.2

    1.3

    1.4

  • 7/22/2019 Assigning a New Disk From VIO to Lpar in AIX

    3/9

    Assigning a new disk from a VIO to LPAR

    August 11, 2010

    Wipro ConfidentialPage 3 of 9

    VIO Document for assigning disk from VIO server to LPAR .

    ============================================

    Q&A

    =====

    When we have to follow this procedure?

    When assigning new disk to LPAR.

    How to find it the LPAR server?

    No direct method. But we can find by lsdev -Cc adapter | fsc.

    It shows the fcs list is not LPAR.

    How to find the HMC from the LPAR?

    lsrsrc "IBM.ManagementServer" shows the IP address. nslookup the ip shows the hmc name.

    If two LPAR "A" and LPAR "B" are cluster from different set of VIO servers, How can i requst the disk

    from BSO?

    Provide the VIOS WWN number of the LPAR "A" and LPAR "B" and make the note that PVID should be same,

    as normal VIO disk requst. No need to mention the servers are cluster.

    ===============================================================

    Scan the new disk as per the normal disk scan

    lspv > /tmp/lspv.old

  • 7/22/2019 Assigning a New Disk From VIO to Lpar in AIX

    4/9

    Assigning a new disk from a VIO to LPAR

    August 11, 2010

    Wipro ConfidentialPage 4 of 9

    cfgmgr

    lspv > /tmp/lspv.newdiff /tmp/lspv.old /tmp/lspv.new

    Make a note of LUN number from the following command

    powermt display dev=

    Assign the pvid

    chdev -l -a pv=yes

    chdev -l hdiskpower14 -a pv=yes

    Assign the PVID to the disk in another VIO server

    chdev -l -a pv=yes

    chdev -l hdiskpower14 -a pv=yes

    Confirm the both the PVID are same

    lspv | grep

    lspv | grep -i hdiskpower14

    Note:- Not to continue, if the PVID are differ.

    Now we have to change some attrubute of the new disk

    Chage the reserve lock to "No"

  • 7/22/2019 Assigning a New Disk From VIO to Lpar in AIX

    5/9

    Assigning a new disk from a VIO to LPAR

    August 11, 2010

    Wipro ConfidentialPage 5 of 9

    chdev -l -a reserve_lock=no

    chdev -l hdiskpower14 -a reserve_lock=no

    Change the max_coalesce to 0x40000

    chdev -l hdiskpower14 -a max_coalesce=0x40000

    Find the vhost # for the LPAR

    lsmap -all

    Note:- Run this command form the padmin restricted shell

    The above commend list all the vhost and the devices

    Check for the your LPAR server name.

    For example the output like this

    --------------- -------------------------------------------- ------------------

    vhost1 U9133.55A.066DBAH-V21-C11 0x00000001

    VTD v1-dpr201-9b4

    Status Available

    LUN 0x8100000000000000

    Backing device hdiskpower0

    Physloc U787B.001.DNWG93R-P1-C2-T1-L1

    VTD v1-dpr201-9ba

    Status Available

  • 7/22/2019 Assigning a New Disk From VIO to Lpar in AIX

    6/9

    Assigning a new disk from a VIO to LPAR

    August 11, 2010

    Wipro ConfidentialPage 6 of 9

    LUN 0x8200000000000000

    Backing device hdiskpower3Physloc U787B.001.DNWG93R-P1-C2-T1-L4

    VTD v1-dpr201-9c0

    Status Available

    LUN 0x8300000000000000

    Backing device hdiskpower6

    Physloc U787B.001.DNWG93R-P1-C2-T1-L7

    Here the dpr201is the partical LPAR name and the 8c3 is the lun number. In the top we find the vhost number.

    Note:- Run the following form the restricted shell

    To assign the disk from VIO to LPAR

    Here I am assigning disk from vioax109 /vioax110 to LPAR (dpravax201c)

    mkvdev -vdev hdiskpower14 -vadapter vhost1 -dev v1-dpr201-8c3

    mkvdev -vdev hdiskpower14 -vadapter vhost1 -dev v1-dpr201-8c3

    Login to the LPAR (dpravax201c)

    Check the current available disk

    (root@dpravax201c)/> lspv

    hdisk0 0006002dd75aa646 rootvg active

    hdisk1 0006002dd75b8b46 appsvg active

  • 7/22/2019 Assigning a New Disk From VIO to Lpar in AIX

    7/9

    Assigning a new disk from a VIO to LPAR

    August 11, 2010

    Wipro ConfidentialPage 7 of 9

    hdisk2 0006002dd753c8d5 web_vg active

    hdisk3 0006002dd7593694 i2_vg activehdisk4 0006002dd7566e61 i2_vg active

    To configure the new disk

    cfgmgr

    Check the availability of new disk

    (root@dpravax201c)/> lspv

    hdisk0 0006002dd75aa646 rootvg active

    hdisk1 0006002dd75b8b46 appsvg active

    hdisk2 0006002dd753c8d5 web_vg active

    hdisk3 0006002dd7593694 i2_vg active

    hdisk4 0006002dd7566e61 i2_vg active

    hdisk5 0006002d0a278162 None

    Note:-The new disk PVID should matches with the PVID in the VIO servers

    lspv | grep hdisk5

    hdisk5 0006002d0a278162 None

    Change the disk attribute

    Change the hcheck_interval=60

    chdev -l hdisk5 -a hcheck_interval=60

  • 7/22/2019 Assigning a New Disk From VIO to Lpar in AIX

    8/9

    Assigning a new disk from a VIO to LPAR

    August 11, 2010

    Wipro ConfidentialPage 8 of 9

    Set the path priority

    chpath -l hdisk5 -p vscsi0 -a priority=2

    Add the disk to VG

    extendvg

    extendvg i2_vg hdisk5

    Extend the file system

    chfs -a size=+

    chfs -a size=+50G /apps/i2

    NOTE:-

    Some time you may got the error while try to increase the Filesystem

    (root@dpravax201c)/> chfs -a size=+50G /apps/i2

    0516-787 extendlv: Maximum allocation for logical volume i2_lv

    is 512.

    The error stating that the Max Logical volume allocation is 512. So we need to increase the max LV allocation

    to 1024 with the following command. Then try increasing the Filesystem. It will work.

    chlv -x 1024

    chlv -x 1024 i2_lv

    Then run chfs to increase the Filesystem

  • 7/22/2019 Assigning a New Disk From VIO to Lpar in AIX

    9/9

    Assigning a new disk from a VIO to LPAR

    August 11, 2010

    Wipro ConfidentialPage 9 of 9

    chfs -a size=+50G /apps/i2

    ==============================END==============================