EMC HPUX

From My Admin Page
Jump to: navigation, search
Adding EMC drives to HP

Adding storage : 
Using Navisphere:
1) Lauch Navisphere
2) Right Click on the (Clariion) icon and choose 'Bind LUN...'
3) Choose Raid Group and LUN name to create, and disk size, then LUN created
4) Under hostname, right click on hostname in Storage Groups, choose 'Properties'.
5) Click on 'Select LUNs...'
6) Choose 'Unassigned LUNs for Storage Group' that were created, 
    then click the right arrow to move them to 'Selected LUNs'.
7) Now, on HP host, verify new luns with 'ioscan -fnC disk'. If not there, do 'insf -e' (to create 'special
    devices') or 'insf -C disk' (create new /dev/dsk/ entries) or run pvlist script below.
	** Note : Drive won't show up until EMC done processing (i.e. navisphere is blue) **

Now, on HP host:
1) Create a new volume group
	mkdir /dev/<vgname>			<- Make directory for volume group
	ls -l /dev/*/group 		 	<- shows existing volume groups and node#
	mknod /dev/<vgname>/group c 64 0xnn0000	<- where NN is 00-99 unique from other group files
2) Add disks (do an 'ioscan -fnC disk' - if no show 'insf -e') with pvcreate and vgcreate
	pvcreate /dev/rdsk/c*t*d* 		<- for only one of the two of disk sets
	vgcreate -e <max_pe> <vgname> /dev/dsk/<c*t*d*> /dev/dsk/<c*t*d*>  <- both connections.
      -- max_pe default is 1016, range is 1-65535. Max_Pe means 'maximum Physical Extents' per PV 
      -- 1pe=4kb. So 10238pe=40G. Max_pe is per PV (disk). 25595pe=100G, max pe [65535] is 256GB.
       	vgdisplay <vgname> | grep 'Free PE'		<- to find the number of extents free for next step.
3) lvcreate {-l | -L} <# extents> /dev/<vgname> 	<- Make logical volume (-l is extents, -L is mb)
4) mkfs -F vxfs /dev/<vgname>/<lvol#>		<- Format partition
5) Edit /etc/fstab to add partition

------------------------------------------------------------------------------------------------------------------
Adding additional Space :
1) pvcreate /dev/rdsk/<c*t*d*> 			<- for only one of the two of disk sets
2) vgextend /dev/<vgname> /dev/dsk/<c*t*d*> /dev/dsk/<c*t*d*>	<- Both in set
3) To find out total available space :
	vgdisplay -v <vgname> | grep 'Total PE' 	<-(use largest number - wil be total avail)
       -- Note - vgdisplay will show you also 'Max PE per PV' which is defined in step #2 in previous
         section. If the new disk you added is larger then this, you can only allocate what this value is.
4) lvextend -l  <Total PE> /dev/<vgname>/<lvol#>  	<- Total extents, not additional
5) Unmount Partition to do the next part :
6) extendfs -F vxfs /dev/<vgname>/<rlvol#>
7) Remount partition
------------------------------------------------------------------------------------------------------------------

Removing a disk from a group : vgremove <vgname> /dev/dsk/<c*t*d*>

------------------------------------------------------------------------------------------------------------------
script pvlist :
#!/bin/ksh
 for i in `ls /dev/dsk/c[6-8]*`;do
        echo '$i -> \c'
        pvdisplay $i | grep -i 'vg name'
        done