Etherchannel环境下更换网卡

更新时间:2023-11-04 06:14:01 阅读量: 综合文库 文档下载

说明:文章内容仅供预览,部分内容可能不全。下载后的文档,内容与下面显示的完全一致。下载之前请确认下面内容是否您想要的,是否完整无缺。

Etherchannel环境下更换网卡

环境:

AIX OSLevel:5304CSP

Etherchannel配置模式:标准,backup模式。

此处Etherchanel的虚拟网卡为ent4,物理主网卡为ent2,物理备网卡为ent3

步骤:

1. 使用命令entstat -d ent4查看当前Etherchannel状态 查看当前Etherchannel网卡的状态,例如:

# entstat -d ent4 | egrep -e \ETHERNET STATISTICS (ent4) : Active channel: primary channel ETHERNET STATISTICS (ent2) : Link Status : Up

Media Speed Selected: 100 Mbps Full Duplex Media Speed Running: 100 Mbps Full Duplex ETHERNET STATISTICS (ent3) : Link Status : Down

Media Speed Selected: 100 Mbps Full Duplex Media Speed Running: Unknown

注意当前“Active channel”是Primary Channel还是Secondary Channel 查看ent2和ent3的link status是Up还是Down

2. 如果需要更换的是主网卡ent2,而当前“Active Channel”仍是Primary Channel,则当前ent2上还有网络流量,需要首先进行链路的主备网卡切换,确保需要更换的主网卡ent2上没有网络流量

# /usr/lib/methods/ethchan_config -f ent4

更换主网卡ent2:

1.从etherchannel删除主网卡

/usr/lib/methods/ethchan_config -d ent4 ent2 2.删除并热插拔主网卡

3.添加主网卡到etherchannel

/usr/lib/methods/ethchan_config -a ent4 ent2

3. 如果需要更换的是备网卡ent3,而当前“Active Channel”是Secondary Channel,则当前ent3上还有网络流量,需要首先进行链路的主备网卡切换,确保需要更换的备网卡ent3上没有网络流量

# /usr/lib/methods/ethchan_config -f ent4

更换备网卡ent3:

1.从etherchannel删除备网卡

/usr/lib/methods/ethchan_config -d ent4 ent3 2.删除并热插拔备网卡

3.添加备网卡到etherchannel

/usr/lib/methods/ethchan_config -a -b ent4 ent3 完!

附录 ethchan_config命令说明 man ethchan_config

Commands Reference, Volume 2, d - h

ethchan_config Command

Purpose

Adds adapters to an EtherChannel or removes adapters from an EtherChannel.

Syntax

ethchan_config { -a [ -b ] | -d } EtherChannel Adapter

ethchan_config -c EtherChannel Attribute NewValue

ethchan_config -f EtherChannel

Description

This command adds adapters to an EtherChannel or removes adapters from an EtherChannel. This command can also be used to

modify EtherChannel attributes. These additions, deletions or modifications can take place even if the EtherChannel's

interface is currently configured; that is, it is not necessary to detach the EtherChannel's interface to add or remove

adapters or modify most EtherChannel attributes.

Flags

-a

Adds the specified Adapter to the specified EtherChannel. If the adapter must be added as a backup adapter, the -b flag must be specified. -b

Specifies that the Adapter is being added as a backup adapter. This flag is only valid when used with the -a flag. -c

Changes the specified Attribute of the specified EtherChannel attribute to the specified NewValue. -d

Deletes the specified Adapter from the specified EtherChannel. The -b flag should not be used with the -d flag. -f

Forces a failover of the specified EtherChannel. Note that the failover will only actually occur if the adapter in the

idle channel is up: if the adapter in the idle channel is down, the EtherChannel will keep operating on the active one

and no failover will take place.

Parameters

Adapter

Specifies the adapter to add or delete. Attribute

Specifies an attribute of the specified EtherChannel. EtherChannel

Specifies the EtherChannel. NewValue

Specifies the new value for the specified attribute of the specified EtherChannel.

Exit Status 0

The command completed successfully. >0

An error occurred.

Examples

1 To add the adapter ent0 as the backup adapter in the EtherChannel called ent7, type:

/usr/lib/methods/ethchan_config -a -b ent7 ent0

2 To change the address to ping attribute of an EtherChannel called ent7 to 10.10.10.10, type:

/usr/lib/methods/ethchan_config -c ent7 netaddr 10.10.10.10

3 To force a failover of an EtherChannel called ent7 from the currently active channel to the idle channel, type:

/usr/lib/methods/ethchan_config -f ent7

Restrictions

The use of the use_jumbo_frame attribute cannot be modified by this command. Attempting to do so will print out an error message.

Location

/usr/lib/methods

AIX33:/>

本文来源:https://www.bwwdw.com/article/8xw2.html

Top