溫馨提示×

您好,登錄后才能下訂單哦!

密碼登錄×
登錄注冊(cè)×
其他方式登錄
點(diǎn)擊 登錄注冊(cè) 即表示同意《億速云用戶服務(wù)條款》

AIX刪除多余的默認(rèn)網(wǎng)關(guān)

發(fā)布時(shí)間:2020-03-04 05:14:58 來(lái)源:網(wǎng)絡(luò) 閱讀:1692 作者:客居天涯 欄目:系統(tǒng)運(yùn)維

AIX刪除多余的默認(rèn)網(wǎng)關(guān)

系統(tǒng)環(huán)境:

操作系統(tǒng):AIX 5.3.8

Oracle:  Oracle 10gR2

案例分析:

   在AIX系統(tǒng)上有多個(gè)默認(rèn)網(wǎng)關(guān),在安裝RAC時(shí),導(dǎo)致網(wǎng)絡(luò)環(huán)境檢測(cè)錯(cuò)誤,無(wú)法安裝RAC.

AIX刪除多余的默認(rèn)網(wǎng)關(guān)


AIX刪除多余的默認(rèn)網(wǎng)關(guān)


AIX刪除多余的默認(rèn)網(wǎng)關(guān)

   通過(guò)smit和route delete刪除,系統(tǒng)在重啟后又回到原來(lái)的狀態(tài)!


解決方案:

1、查看當(dāng)前默認(rèn)網(wǎng)關(guān)

[root@aix230:/]#netstat -nr

Routing tables
Destination        Gateway           Flags   Refs     Use  If   Exp  Groups
Route tree for Protocol Family 2 (Internet):
default            192.168.8.1       UG        0         0 en0      -      -   
default            10.10.10.1            UG        0         0 en1      -      - 
default            10.10.10.1          UG        0         0 en1      -      - 
10.10.10.0         10.10.10.230      UHSb      0         0 en1      -      -   =>
10.10.10/24        10.10.10.230      U         0         1 en1      -      -   
10.10.10.230       127.0.0.1         UGHS      0         1 lo0      -      -   
10.10.10.255       10.10.10.230      UHSb      0         4 en1      -      -   
127/8              127.0.0.1         U        13       247 lo0      -      -   
192.168.8.0        192.168.8.230     UHSb      0         0 en0      -      -   =>
192.168.8/24       192.168.8.230     U         4        42 en0      -      -   
192.168.8.230      127.0.0.1         UGHS      0         1 lo0      -      -   
192.168.8.255      192.168.8.230     UHSb      0         4 en0      -      -   
Route tree for Protocol Family 24 (Internet v6):
::1                ::1               UH        0         0 lo0      -      -

2、查看ODM信息

[root@aix230:/]#lsattr -El inet0

authm         65536                          Authentication Methods              True

bootup_option no                             Use BSD-style Network Configuration True

gateway                                      Gateway                             True

hostname      aix230                         Host Name                           True

rout6                                        IPv6 Route                          True

route         net,-hopcount,0,,0,192.168.8.1 Route                               True

route         net,-hopcount,0,,0,10.10.10.1  Route                               True

route         net,-hopcount,2,,0,10.10.10.1  Route                               True

[root@aix230:/]#odmget -q "name=inet0" CuAt

CuAt:
        name = "inet0"
        attribute = "hostname"
        value = "aix230"
        type = "R"
        generic = "DU"
        rep = "s"
        nls_index = 24
CuAt:
        name = "inet0"
        attribute = "route"
        value = "net,-hopcount,0,,0,10.10.10.1"
        type = "R"
        generic = "DU"
        rep = "s"
        nls_index = 0
CuAt:
        name = "inet0"
        attribute = "route"
        value = "net,-hopcount,0,,0,192.168.8.1"
        type = "R"
        generic = "DU"
        rep = "s"
        nls_index = 0
CuAt:
        name = "inet0"
        attribute = "route"
        value = "net,-hopcount,2,,0,10.10.10.1"
        type = "R"
        generic = "DU"
        rep = "s"
        nls_index = 0

3、逐條刪除沒用的默認(rèn)路由

[root@aix230:/]#chdev -l inet0 -a delroute="net,-hopcount,2,,0,10.10.10.1"

inet0 changed

4.確認(rèn)生效

[root@aix230:/]#odmget -q "name=inet0" CuAt


CuAt:
        name = "inet0"
        attribute = "hostname"
        value = "aix230"
        type = "R"
        generic = "DU"
        rep = "s"
        nls_index = 24
CuAt:
        name = "inet0"
        attribute = "route"
        value = "net,-hopcount,0,,0,192.168.8.1"
        type = "R"
        generic = "DU"
        rep = "s"
        nls_index = 0

[root@aix230:/]#netstat -nr

Routing tables
Destination        Gateway           Flags   Refs     Use  If   Exp  Groups
Route tree for Protocol Family 2 (Internet):
default            192.168.8.1       UG        0         0 en0      -      -   
10.10.10.0         10.10.10.230      UHSb      0         0 en1      -      -   =>
10.10.10/24        10.10.10.230      U         0         1 en1      -      -   
10.10.10.230       127.0.0.1         UGHS      0         1 lo0      -      -   
10.10.10.255       10.10.10.230      UHSb      0         4 en1      -      -   
127/8              127.0.0.1         U        13       247 lo0      -      -   
192.168.8.0        192.168.8.230     UHSb      0         0 en0      -      -   =>
192.168.8/24       192.168.8.230     U         4        42 en0      -      -   
192.168.8.230      127.0.0.1         UGHS      0         1 lo0      -      -   
192.168.8.255      192.168.8.230     UHSb      0         4 en0      -      -   
Route tree for Protocol Family 24 (Internet v6):
::1                ::1               UH        0         0 lo0      -      -

@系統(tǒng)在重啟后,不再出現(xiàn)多個(gè)default gw的現(xiàn)象,至此,問題得到解決!

向AI問一下細(xì)節(jié)

免責(zé)聲明:本站發(fā)布的內(nèi)容(圖片、視頻和文字)以原創(chuàng)、轉(zhuǎn)載和分享為主,文章觀點(diǎn)不代表本網(wǎng)站立場(chǎng),如果涉及侵權(quán)請(qǐng)聯(lián)系站長(zhǎng)郵箱:is@yisu.com進(jìn)行舉報(bào),并提供相關(guān)證據(jù),一經(jīng)查實(shí),將立刻刪除涉嫌侵權(quán)內(nèi)容。

AI