Use an etherchannel to bind an Eni to an AIX 5l instance)

Source: Internet
Author: User
Tags pings
Author: Piner (Reprinted with the source: ixdba.com) Permanent Link:Http://www.ixdba.com/html/y2007/m06/118-aix-5l-etherchannel.html

In the AIX operating system, you can configure multiple etherchannels (NIC binding ). Before AIX 5.2, we can only select the active/active etherchannel mode or the active/standby etherchannel mode to bind the NIC. Therefore, the new Nic backup mode is introduced in AIX 5.2. You can specify a backup Nic for the entire etherchannel. When the entire etherchannel fails, this NIC will automatically replace the etherchannel function. This is very different from the etherchannel Nic backup mode before AIX 5.2. Therefore, a more complex Nic binding mode can appear after 5.2.

An etherchannel can contain two to eight NICs, and multiple etherchannels can be configured in an AIX operating system. But remember that each etherchannel is a new Ethernet interface. You may need to use the no command to adjust the value of the ifsize parameter to ensure that the total number of Ethernet cards and etherchannels does not exceed the ifsize, the default value of ifsize is 8.

You can use any Nic supported by the AIX system to form an etherchannel. However, the NIC of the same channel of the etherchannel must be connected to a switch that supports the etherchannel. The secondary channel can be connected to another switch, which is used for the failure of the master channel. All the member NICs of etherchannel should be set to the same speed and working mode, such as 1000 megabits full duplex. The IP address cannot be configured for the NIC to be used as an etherchannel member. If the IP address is already configured, you must delete these configurations before configuring the etherchannel.

After aix5.2, let's look at three typical configuration methods.

1. dual-channel or multi-channel active mode. In this mode, all network adapters are active, that is, each network adapter is in the active state. They have a single IP address and a MAC address, however, the destination of all NICs must be on the same vswitch, and the corresponding port of the vswitch must also be bound.

The biggest advantage of this is that when one of the network adapters fails or one of the network adapters fails, it does not affect the work of the entire network. Only when all network adapter channels fail, the network is invalid. In addition, you can increase the network bandwidth when multiple NICs work at the same time. However, note that the default network adapter is allocated based on the IP address of the target machine, if there is only one target machine, the default setting is not suitable. In this mode, the biggest problem is that all NICs must be bound to the same vswitch and cannot prevent the failure of the target vswitch.

2. Active/standby mode. In this mode, a NIC is connected to the primary switch and a NIC is connected to the standby switch. When the active channel fails, it is automatically switched to the standby channel, when the primary channel returns to normal, it is automatically switched to the primary channel (whether to switch back here is configurable ). The biggest benefit of this method is to prevent switch faults.

3. Compound configuration, which combines the advantages of the above two methods. For example, in an environment with three NICs, We can configure two NICs into a dual active mode to increase network bandwidth and network reliability. The other Nic is used as a backup mode, when connected to another vswitch, the current two NICs are invalid, or the switch connected to the first two NICS is invalid, switch to the backup Nic.

Next, we will introduce the detailed steps:

If you want to bind or unbind, you can use the Smit etherchannel. To bind ent1 and ent2 :.

# Chdev-l EN1-A netaddr = "-a netmask ="

# Chdev-l EN2-A netaddr = "-a netmask ="

# Chdev-l EN1-a state = 'detach'

# Chdev-l EN2-a state = 'detach'

Note: The preceding commands are necessary. The sub-network card must first cancel the existing IP address and be in the detach status. Note that if you connect to the host through EN1 or EN2, perform the preceding operations, your network may be interrupted immediately. Therefore, we recommend that you use another network adapter or HMC to complete the above operations. Then, we start binding

# Smit etherchannel

Select

Add an etherchannel/link Aggregation

Select the NIC

Etherchannel/link aggregation adapters ent1, ent2

Press enter to execute:

    Command: OK            stdout: yes           stderr: no    Before command completion, additional instructions may appear below.    ent4 Available

At last, a message is displayed, indicating that the new ENI is a usable one. You can use lsattr to view its attributes or lsdev-CC adapter to view all Nic attributes.

# Lsattr-El ent4

    adapter_names   ent1,ent2      EtherChannel Adapters                     True    alt_addr        0x000000000000 Alternate EtherChannel Address            True    auto_recovery   yes            Enable automatic recovery after failover  True    backup_adapter  NONE           Adapter used when whole channel fails     True    hash_mode       default        Determines how outgoing adapter is chosen True    mode            standard       EtherChannel mode of operation            True    netaddr                        Address to ping                           True    num_retries     3              Times to retry ping before failing        True    retry_time      1              Wait time (in seconds) between pings      True    use_alt_addr    no             Enable Alternate EtherChannel Address     True    use_jumbo_frame no             Enable Gigabit Ethernet Jumbo Frames      True

In this way, the bound Nic is a dual-path, that is to say, both NICs are active. Note that the switch must be used together to connect two NICs and set the network switch, you can contact your system administrator.

We can also set a backup Nic, which is usually not active and in the standby take over status. If a problem occurs in the primary channel, switch to the standby channel. In this case, you can connect to two different switches for switch redundancy.

The backup Nic is the backup_adapter above. You can use

# Smit chgethch

Or

# Smit etherchannel

Select

Change/show characteristics of an etherchannel/link Aggregation

Then select

Add backup adapter. If you have added a back-up Nic to bind the NIC, the following differences apply:

# Lsattr-El ent4

    adapter_names   ent1,ent2      EtherChannel Adapters                     True    alt_addr        0x000000000000 Alternate EtherChannel Address            True    auto_recovery   yes            Enable automatic recovery after failover  True    backup_adapter  ent3           Adapter used when whole channel fails     True    hash_mode       default        Determines how outgoing adapter is chosen True    mode            standard       EtherChannel mode of operation            True    netaddr                        Address to ping                           True    num_retries     3              Times to retry ping before failing        True    retry_time      1              Wait time (in seconds) between pings      True    use_alt_addr    no             Enable Alternate EtherChannel Address     True    use_jumbo_frame no             Enable Gigabit Ethernet Jumbo Frames      True

You can also view the network adapter's working status through netstat-V, for example:

# Netstat-V ent4

    ETHERNET STATISTICS (ent4) :    Device Type: EtherChannel    Hardware Address: 00:14:5e:b7:26:88    ......    Number of adapters: 3    Active channel: primary channel    Operating mode: Standard mode    Hash mode: Destination IP address    ......    ETHERNET STATISTICS (ent1) :    Link Status : Up    Media Speed Selected: Auto negotiation    Media Speed Running: 1000 Mbps Full Duplex    ......    ETHERNET STATISTICS (ent2) :    Link Status : Up    Media Speed Selected: Auto negotiation    Media Speed Running: 1000 Mbps Full Duplex    ......    Backup adapter - ent3:    ======================    Link Status : Up    Media Speed Selected: Auto negotiation    Media Speed Running: 1000 Mbps Full Duplex    ......

If you want to cancel the binding, perform the same operation.

# Smit etherchannel

Select

Remove an etherchannel/link Aggregation

Select the NIC you want to cancel, as shown in ent4 above, press enter to execute

    Command: OK            stdout: yes           stderr: no    Before command completion, additional instructions may appear below.    ent4 deleted

If the preceding result is displayed, the binding is canceled successfully. The successful result can be obtained by comparing lsdev-CC adapter.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.