檢視LUN對應的HBA 檢視HBA的WWN資訊

2021-07-13 02:05:47 字數 3685 閱讀 3397

首先檢視多路徑裝置:

[root@elt1 block]# multipath -ll

mpathe (3600c0ff00026402cf4cf5d5601000000) dm-1 dothill,dh3000

size=47g features='0' hwhandler='0' wp=rw

|-+- policy='round-robin 0' prio=1 status=enabled

| `- 3:0:0:0 sdb 8:16  active ready running

`-+- policy='round-robin 0' prio=1 status=active

`- 4:0:0:0 sdi 8:128 active ready running

mpathd (3600c0ff00026402cf5cf5d5601000000) dm-0 dothill,dh3000

size=47g features='0' hwhandler='0' wp=rw

|-+- policy='round-robin 0' prio=1 status=enabled

| `- 3:0:0:1 sdc 8:32  active ready running

`-+- policy='round-robin 0' prio=1 status=active

`- 4:0:0:1 sdj 8:144 active ready running

mpathc (3600c0ff00026402cdbc95d5601000000) dm-4 dothill,dh3000

size=1.8t features='0' hwhandler='0' wp=rw

|-+- policy='round-robin 0' prio=1 status=enabled

| `- 3:0:0:2 sdd 8:48  active ready running

`-+- policy='round-robin 0' prio=1 status=active

`- 4:0:0:2 sdk 8:160 active ready running

mpathb (3600c0ff00026402cdbc95d5602000000) dm-3 dothill,dh3000

size=1.8t features='0' hwhandler='0' wp=rw

|-+- policy='round-robin 0' prio=1 status=enabled

| `- 3:0:0:3 sde 8:64  active ready running

`-+- policy='round-robin 0' prio=1 status=active

`- 4:0:0:3 sdl 8:176 active ready running

mpathh (3600c0ff00026402ce0c95d5604000000) dm-6 dothill,dh3000

size=1.8t features='0' hwhandler='0' wp=rw

|-+- policy='round-robin 0' prio=1 status=enabled

| `- 3:0:0:6 sdh 8:112 active ready running

`-+- policy='round-robin 0' prio=1 status=active

`- 4:0:0:6 sdo 8:224 active ready running

mpathg (3600c0ff00026402ce0c95d5603000000) dm-5 dothill,dh3000

size=1.8t features='0' hwhandler='0' wp=rw

|-+- policy='round-robin 0' prio=1 status=enabled

| `- 3:0:0:5 sdg 8:96  active ready running

`-+- policy='round-robin 0' prio=1 status=active

`- 4:0:0:5 sdn 8:208 active ready running

mpathf (3600c0ff00026402cdcc95d5601000000) dm-2 dothill,dh3000

size=1.8t features='0' hwhandler='0' wp=rw

|-+- policy='round-robin 0' prio=1 status=enabled

| `- 3:0:0:4 sdf 8:80  active ready running

`-+- policy='round-robin 0' prio=1 status=active

`- 4:0:0:4 sdm 8:192 active ready running

[root@elt1 block]# 

那麼如何檢視某個裝置經過哪個hba卡呢?例如檢視mpathf下的sdf和sdm是經過哪個hba卡訪問儲存的呢?

[root@elt1 block]# cd /sys/block

[root@elt1 block]# ls -l

[root@elt1 block]# ls -l|grep -e "sdh|sdo"

lrwxrwxrwx 1 root root 0 jun  1 10:09 sdh -> ../devices/pci0000:40/0000:40:02.0/0000:41:00.0/host3/rport-3:0-0/target3:0:0/3:0:0:6/block/sdh

lrwxrwxrwx 1 root root 0 jun  2 21:19 sdo -> ../devices/pci0000:40/0000:40:03.0/0000:51:00.0/host4/rport-4:0-0/target4:0:0/4:0:0:6/block/sdo

[root@elt1 block]# 

再檢視host3和host4的wwpn號:

[root@elt1 block]# cd /sys/class/fc_host/

[root@elt1 fc_host]# ls

host1  host2  host3  host4

[root@elt1 fc_host]# 

[root@elt1 fc_host]# cd host3

[root@elt1 host3]# ls

device        issue_lip        npiv_vports_inuse  port_state  speed       supported_classes  system_hostname  vport_create

dev_loss_tmo  max_npiv_vports  port_id            port_type   statistics  supported_speeds   tgtid_bind_type  vport_delete

fabric_name   node_name        port_name          power       subsystem   symbolic_name      uevent

[root@elt1 host3]# cat port_name

0x21000024ff0f597b

[root@elt1 host3]# cat node_name

0x20000024ff0f597b

[root@elt1 host3]# 

linux AS4 檢視HBA卡號WWN號

linux as4 檢視hba卡號wwn號 方法一 root dbhyfp qla2 cd proc scsi qla2 root dbhyfp qla2 ls 0 1 root dbhyfp qla2 grep scsi 0 scsi qla0 port 5 5006048c52a801e7 50...

linux centos 檢視程序對應的埠號

常見引數 a all 顯示所有選項,預設不顯示listen相關 t tcp 僅顯示tcp相關選項 u udp 僅顯示udp相關選項 n 拒絕顯示別名,能顯示數字的全部轉化成數字。l 僅列出有在 listen 監聽 的服務狀態 p 顯示建立相關鏈結的程式名 r 顯示路由資訊,路由表 e 顯示擴充套件資...

Mac檢視localhost對應的ip位址

很多時候,我們都輸入過這樣的 http localhost 8080 很熟悉吧!訪問tomcat或者訪問jenkins等web網頁時經常用到,那麼我們經常使用的這個localhost是什麼?字面意思是 本地主機,其代表的就是這台計算機,是給迴路網路介面的標準主機名,對應的ip位址為127.0.0.1...