我們知道在SAN網路中,由於光纖交換器會有多條鏈路接入主機,所以會存在裝置多名稱現象,也就是一台儲存被識別多次,具體根據串連的鏈路情況,並且對於串連到的LUN在主機上的LINUX系統上會發生/dev/sd*每次重啟動裝置名稱變化的問題,所以對於此問題,我們可以採取兩種方式,一是高版本的linux可以通過udev來配置,將LUN裝置號固定下來,二是採用第三方的動態多重路徑軟體配置多重路徑彙總,從而固定盤符名稱,在此主要是對powerpath動態多重路徑軟體配置存在的問題做以說明。在powerpath配置安裝成功可能會存在這個問題,也就是兩台主機識別到的偽裝置名稱對應的LUN不一致,例如如下所示:
在主機DBTEST1上擷取的資訊如下:DBTest1:/home/oracle # powermt display dev=allPseudo name=emcpowerb www.2cto.com CLARiiON ID=FCNCX093300010 [Storage Group 2]Logical device ID=600601601EA02500326149A0207AE111 [LUN 10]state=alive; policy=BasicFailover; priority=0; queued-IOs=0; Owner: default=SP A, current=SP A Array failover mode: 1==============================================================================--------------- Host --------------- - Stor - -- I/O Path -- -- Stats ---### HW Path I/O Paths Interf. Mode State Q-IOs Errors============================================================================== 0 qla2xxx sde SP B1 unlic alive 0 0 0 qla2xxx sdj SP A1 unlic alive 0 0 1 qla2xxx sdk SP B0 active alive 0 0 1 qla2xxx sdo SP A0 active alive 0 0 Pseudo name=emcpoweraCLARiiON ID=FCNCX093300010 [Storage Group 2]Logical device ID=600601601EA02500F22E8FC2207AE111 [LUN 11]state=alive; policy=BasicFailover; priority=0; queued-IOs=0; Owner: default=SP A, current=SP A Array failover mode: 1==============================================================================--------------- Host --------------- - Stor - -- I/O Path -- -- Stats ---### HW Path I/O Paths Interf. Mode State Q-IOs Errors============================================================================== 0 qla2xxx sdg SP B1 unlic alive 0 0 0 qla2xxx sdl SP A1 unlic alive 0 0 1 qla2xxx sdm SP B0 active alive 0 0 1 qla2xxx sdp SP A0 active alive 0 0 Pseudo name=emcpowercCLARiiON ID=FCNCX093300010 [Storage Group 2]Logical device ID=600601601EA02500FA322E81207AE111 [LUN 1]state=alive; policy=BasicFailover; priority=0; queued-IOs=0; Owner: default=SP A, current=SP A Array failover mode: 1==============================================================================--------------- Host --------------- - Stor - -- I/O Path -- -- Stats ---### HW Path I/O Paths Interf. Mode State Q-IOs Errors============================================================================== 0 qla2xxx sdc SP B1 unlic alive 0 0 0 qla2xxx sdh SP A1 unlic alive 0 0 1 qla2xxx sdi SP B0 active alive 0 0 1 qla2xxx sdn SP A0 active alive 0 0而在主機DBTEST2上識別的資訊如下:DBTest2:~ # powermt display dev=allPseudo name=emcpowera www.2cto.com CLARiiON ID=FCNCX093300010 [Storage Group 2]Logical device ID=600601601EA02500326149A0207AE111 [LUN 10]state=alive; policy=BasicFailover; priority=0; queued-IOs=0; Owner: default=SP A, current=SP A Array failover mode: 1==============================================================================--------------- Host --------------- - Stor - -- I/O Path -- -- Stats ---### HW Path I/O Paths Interf. Mode State Q-IOs Errors============================================================================== 0 qla2xxx sde SP B1 active alive 0 0 0 qla2xxx sdk SP A1 active alive 0 0 Pseudo name=emcpowerbCLARiiON ID=FCNCX093300010 [Storage Group 2]Logical device ID=600601601EA02500F22E8FC2207AE111 [LUN 11]state=alive; policy=BasicFailover; priority=0; queued-IOs=0; Owner: default=SP A, current=SP A Array failover mode: 1==============================================================================--------------- Host --------------- - Stor - -- I/O Path -- -- Stats ---### HW Path I/O Paths Interf. Mode State Q-IOs Errors============================================================================== 0 qla2xxx www.2cto.com sdg SP B1 active alive 0 0 0 qla2xxx sdl SP A1 active alive 0 0 Pseudo name=emcpowercCLARiiON ID=FCNCX093300010 [Storage Group 2]Logical device ID=600601601EA02500FA322E81207AE111 [LUN 1]state=alive; policy=BasicFailover; priority=0; queued-IOs=0; Owner: default=SP A, current=SP A Array failover mode: 1==============================================================================--------------- Host --------------- - Stor - -- I/O Path -- -- Stats ---### HW Path I/O Paths Interf. Mode State Q-IOs Errors============================================================================== 0 qla2xxx sdc SP B1 active alive 0 0 0 qla2xxx sdi SP A1 active alive 0 0如上紅色字型顯示的,我們可以清楚的看到對於兩台主機LUN對應的情況如下:DBTEST1 DBTEST2/dev/emcpowera /dev/emcpowerb/dev/emcpowerb /dev/emcpowera/dev/emcpowerc /dev/emcpowerc本次由於安裝RAC,根據規劃,emcpowerb和emcpowerc分別為OCR disk和voting disk, 而emcpowera為datadg磁碟組 www.2cto.com 對於如問題我們可以處理的思路如下:1.採用powerpath軟體的管理命令可以將其偽裝置名稱修改為一致,具體可以參照DBTEST1的名稱,在DBTEST2上做如下修改:#emcpadm renamepseudo –s emcpowera –t emcpowerd#emcpadm renamepseudo –s emcpowerb –t emcpowera#emcpadm renamepseudo –s emcpowerd –t emcpowerb更新配置後,重啟下主機看看兩端是否還能保持一致。2.另外我們還可以採用如下方法,也就是保持偽裝置名稱不變,採用塊裝置,只需要綁定的raw裝置一致即可 DBTEST1 DBTEST2/dev/raw/raw3 /dev/emcpowera /dev/emcpowerb/dev/raw/raw2 /dev/emcpowerb /dev/emcpowera/dev/raw/raw1 /dev/emcpowerc /dev/emcpowerc這樣在RAC安裝過程中只需要在各主機對應raw裝置名稱就可以了。 作者 marvelyu