Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
rb:linuxsan [08/07/2019 10:46]
andrew [HP Storage]
rb:linuxsan [20/08/2019 13:58] (current)
andrew [USB drives and multipath]
Line 33: Line 33:
  
  
 +==== RHEL6 ====
 +  [root@satellite02 ~]# cat /​sys/​class/​fc_host/​host*/​port_name
 +  0x500110a00019a1c8
 +  0x500110a00019a1ca
  
 ===== Multipath info ====== ===== Multipath info ======
Line 89: Line 93:
   ​   ​
   ​   ​
 +
 +===== Parameters =====
 +
 +in /​etc/​modprobe.conf:​-
 +
 +  alias scsi_hostadapter1 qla2xxx_conf
 +  alias scsi_hostadapter2 qla2xxx
 +  options qla2xxx ​ ql2xmaxqdepth=16 qlport_down_retry=10 ql2xloginretrycount=30 ​
 +
 +These settings are more aggressive in failing quickly, this allows multipath to adjust sooner to lost paths.
 +
 +  options qla2xxx ql2xfailover=0 ql2xioctltimeout=10 ql2xprocessnotready=0 ql2xloginretrycount=3 ql2xsuspendcount=3 ql2xretrycount=2 ​ lport_down_retry=1
 +  options lpfc lpfc_lun_queue_depth=16 lpfc_nodev_tmo=30 lpfc_discovery_threads=32
 +
 +
 +
 +in /​etc/​multipath.conf (for EVA 8400):-
 +
 +  defaults {
 +  udev_dir /​dev
 +  polling_interval 10
 +  selector "​round-robin 0"
 +  path_grouping_policy failover
 +  getuid_callout "/​sbin/​scsi_id -g -u -s /​block/​%n"​
 +  prio_callout "/​bin/​true"​
 +  path_checker tur
 +  rr_min_io 100
 +  rr_weight ​      ​ uniform
 +  failback immediate
 +  no_path_retry 12
 +  user_friendly_names yes
 +  bindings_file "/​var/​lib/​multipath/​bindings"​
 +  }
 +  ​
 +  blacklist {
 +  devnode "​^(ram|raw|loop|fd|md|dm-|sr|scd|st)[0-9]*"​
 +  devnode "​^hd[a-z][[0-9]*]"​
 +  devnode "​^cciss!c[0-9]d[0-9]*"​
 +  }
 +  ​
 +  devices {
 +  ​
 +  device {
 +  vendor "​HP|COMPAQ"​
 +        product "​HSV1[01]1 \(C\)COMPAQ|HSV2[01]0|HSV300|HSV4[50]0"​
 +  path_grouping_policy group_by_prio
 +          getuid_callout "/​sbin/​scsi_id -g -u -s /​block/​%n"​
 +          path_checker tur
 +          path_selector "​round-robin 0"
 +          prio_callout "/​sbin/​mpath_prio_alua /​dev/​%n"​
 +          rr_weight uniform
 +          failback immediate
 +  hardware_handler "​0"​
 +          no_path_retry 18
 +  rr_min_io 100
 +         }
 +  }
 +  # End device
 +  ​
 +  multipaths {
 +  ​
 +          multipath {
 +          wwid 36001438005def5bf00006000004e0000
 +          alias HSV450_FRA_001
 +          }
 +  ​
 +          multipath {
 +          wwid 36001438005def5bf00006000004a0000
 +          alias HSV450_arch_001
 +          }
 +
 +
 +
 +===== USB drives and multipath =====
 +
 +No USB drives should be added by multipath. However, multipath can add a USB drive into it's configuration,​ if it detects a new drive.
 +
 +To check if multipath has added a USB drive, it is possible to check by running:
 +
 +<​file>​
 +# mount /dev/sda1 /​mnt/​ext_hdd ​
 +mount: /dev/sda1 already mounted or /​mnt/​ext_hdd busy
 +
 +
 +sudo /​sbin/​multipath -l
 +/dev/sda1: UUID="​da85426e-cffc-4d13-8d7f-64549e7ca0ce"​ SEC_TYPE="​ext2"​ TYPE="​ext3" ​
 +HSV450_log01_arch (36001438005dec6e40000500000060000) dm-6 HP,HSV450
 +[size=500G][features=1 queue_if_no_path][hwhandler=0][rw]
 +\_ round-robin 0 [prio=200][active]
 + \_ 0:0:0:1 sda 8:0   ​[active][ready]
 + \_ 0:0:1:1 sdb 8:16  [active][ready]
 + \_ 1:0:0:1 sdd 8:48  [active][ready]
 + \_ 1:0:1:1 sde 8:64  [active][ready]
 +\_ round-robin 0 [prio=40][enabled]
 + \_ 0:0:2:1 sdc 8:32  [active][ready]
 + \_ 0:0:3:1 sdf 8:80  [active][ready]
 + \_ 1:0:2:1 sdg 8:96  [active][ready]
 + \_ 1:0:3:1 sdh 8:112 [active][ready]
 +
 +</​file>​
 +
 +If the USB drive is found in multipath, then the device should be blacklisted in /​etc/​multipath.conf.
 +
 +An example is below:
 +
 +<​file>​
 +
 +blacklist {
 +        devnode ​        "​^(ram|raw|loop|fd|md|dm-|sr|scd|st)[0-9]*"​
 +        devnode ​        "​^hd[a-z][[0-9]*]"​
 +        devnode ​        "​^cciss!c[0-9]d[0-9]*"​
 +        wwid            "​da85426e-cffc-4d13-8d7f-64549e7ca0ce"​
 +}
 +
 +</​file>​
 +
 +multipath has to be flushed for the new configuration to take place. ​ This is done via:
 +
 +<​file>​
 +# multipath -F
 +# service multipath restart
 +</​file>​
 +
 +
 +
 +
 +
 +====== Linux SAN - removing LUNS ======
 +
 +===== Overall Sequence to remove a LUN =====
 +
 +  - Ensure LUN required to be removed is not mounted anywhere.
 +  - Remove WWID stanza from multipath.conf.
 +  - Run multipath -F to flush unused LUNS from config.
 +  - Unpresent LUN from server on gy-asp-sma01 web interface or cli.
 +  - Delete LUN (if required).
 +  - If appropriate,​ remove zone config from SAN.
 +
 +===== Check if LUN is mounted =====
 +
 +Look in ''/​etc/​multipath.conf''​ and record the wwid and alias name for the unwanted LUN. This LUN will appear as ''/​dev/​mapper/​$ALIAS'',​ run the ''​mount''​ command and check that the LUN is not mounted. If it is mounted, it must be unmounted before you can proceed. Also check if the LUN is refered to in ''/​etc/​fstab''​. This will also require editing to remove the LUN so as not to cause any problems next reboot. It may be good practice to delete the mount point if it is not in use any more.
 +
 +
 +===== Edit multipath.conf =====
 +
 +Edit ''/​etc/​multipath.conf''​ and remove the config relating to the LUN to be removed. ​
 +Run ''​multipath''​ to rescan LUNS, this will ensure config is up to date. ''​multipath -ll''​ will still show the paths to the LUN to be deleted:-
 +
 +  netbackup (3600508b4001052920000e00003fe0000)
 +  [size=10 GB][features="​1 queue_if_no_path"​][hwhandler="​0"​]
 +  \_ round-robin 0 [prio=200][active]
 +   \_ 0:0:0:25 sda  8:0     ​[active][ready]
 +   \_ 0:0:1:25 sdb  8:16    [active][ready]
 +   \_ 1:0:0:25 sdco 69:​192 ​ [active][ready]
 +   \_ 1:0:1:25 sdcp 69:​208 ​ [active][ready]
 +  \_ round-robin 0 [prio=40][enabled]
 +   \_ 1:0:2:25 sdcq 69:​224 ​ [active][ready]
 +   \_ 1:0:3:25 sdcr 69:​240 ​ [active][ready]
 +   \_ 0:0:2:25 sdc  8:32    [active][ready]
 +   \_ 0:0:3:25 sdd  8:48    [active][ready]
 +
 +Run ''​multipath -F''​ to flush unused paths from the config, this will show the maps in use, any not in use will be flushed silently:-
 +
 +  [root@db01 ~]# multipath -F
 +  HSV450_P_vote1:​ map in use
 +  HSV450_P_RGS_OCFS2_rman:​ map in use
 +  HSV450_P_RGSPROD_Data_0003:​ map in use
 +  HSV450_P_RGSPROD_Data_0002:​ map in use
 +  HSV450_P_RGSPROD_Data_0001:​ map in use
 +
 +Running ''​multipath -ll''​ should not show the paths to the LUN to be deleted anymore.
 +
 +
 +===== Unpresent and delete LUN on SMA01 =====
 +
 +Either in the GUI (https://​sma01:​2372/​Login) or CLI, unpresent the LUN from the host. The CLI differs from the GUI in the terminology it uses for doing the same things. In the GUI, you "​unpresent"​ a vdisk from a host, but in the sssu CLI, you "​delete a LUN", note:- **not delete a vdisk.**
 +
 +From http://​h30499.www3.hp.com/​t5/​Storage-Area-Networks-SAN/​SSSU-unpresent-VDISK-from-given-SAN/​td-p/​3927720 :-
 +You "​DELETE"​ the LUNS. __NOT__ DELETE VDISKS, but DELETE LUNS.
 +
 +
 +  Array01> ls lun
 +  ​
 +  LUNs available on this Cell:
 +  ....edited....
 +    \Hosts\Database server\Production\db01\25
 +  ​
 +  Array01> delete LUN "​\Hosts\Database server\Production\db01\25"​
 +  Array01> ls vdisk
 +  ​
 +  Vdisks available on this Cell:
 +  ....edited....
 +    \Virtual Disks\Oracle\RGS_Prod\vDskDB01_Netbackup\ACTIVE
 +  ​
 +  Array01> delete vdisk "​\Virtual Disks\Oracle\RGS_Prod\vDskDB01_Netbackup\ACTIVE"​
 +
 +
 +===== Remove Zoning on SAN ===== 
 +
 +See Documentation elsewhere.
 +
 +
 +
  
 ====== Re-Scan Fibre devices ====== ====== Re-Scan Fibre devices ======

rb/linuxsan.1562579208.txt.gz ยท Last modified: 08/07/2019 10:46 by andrew