Networking Group Network Teaming

Source: Internet
Author: User

Network Group Team: is the aggregation of multiple network cards to achieve fault tolerance and improve throughput

1 Creating a Network Group interface

NMCLI connection Add type team con-name teamname ifname intname [config JSON]

TEAMNAME Specifies the connection name, inname specifies the interface name,

JSON specifies the runner method in the format: ' {' runner ': {' name ': ' Method '} '

METHOD can be broadcast, Roundrobin, Activebackup, LoadBalance, LACP

(1) Create a network interface group TEAM0

[[email protected] ~]# NMCLI connection Add type team con-name TEAM0 ifname team0 config ' {"runner": {"name": "LoadBalance"} }‘

Connection ' Team0 ' (e70483a1-2688-4eb2-9466-8e732360291d) successfully added.

(2) Configuring IP addresses for network group TEAM0

[Email protected] ~]# NMCLI connection modify TEAM0 ipv4.method manual ipv4.addresses 200.200.200.200/24 gw4 200.200.200. 1

2 Creating the Port Interface (SLAVE)

This is the configuration file that is a member of the Build Team team.

Note: This configuration file and the NIC configuration file are independent of each other.

NMCLI connection Add type Team-slave con-name slavename ifname inname Master Teamname

SLAVENAME Specifies the connection name, Intname specifies the network interface name (equivalent to specifying the NIC name to join the network group), Teamnmae specifies the network group to which it belongs.

If the connection name is not specified, the default is Team-slave-iface

Create an interface group

Here you use ENS34, ens38 two NIC

[Email protected] ~]# nmcli connection add con-name team0-ens34 type Team-slave ifname ens34 master Team0

Connection ' team0-ens34 ' (A481FB6D-BF61-413D-A2C7-289966BEE1A7) successfully added.

[Email protected] ~]# nmcli connection add con-name team0-ens38 type Team-slave ifname ens38 master Team0

Connection ' team0-ens38 ' (758d0eba-1625-46b2-b539-1d853a45be6b) successfully added.

3 Enabling Network groups

Enable Network group: NMCLI connection up Team0

Enable group member: NMCLI connection up Slavename

[Email protected] ~]# NMCLI connection up Team0

Connection successfully activated (master waiting for slaves) (D-bus active path:/org/freedesktop/networkmanager/ ACTIVECONNECTION/20)

[Email protected] ~]# NMCLI connection up team0-ens34

Connection successfully activated (D-bus active path:/ORG/FREEDESKTOP/NETWORKMANAGER/ACTIVECONNECTION/23)

[Email protected] ~]# NMCLI connection up team0-ens38

Connection successfully activated (D-bus active path:/ORG/FREEDESKTOP/NETWORKMANAGER/ACTIVECONNECTION/24)

4 Viewing Network Group status

Teamdctl Teamname State

[Email protected] ~]# Teamdctl TEAM0 State

Setup

Runner:loadbalance

Ports

Ens34

Link watches:

Link Summary:up

INSTANCE[LINK_WATCH_0]:

Name:ethtool

Link:up

Down count:0

Ens38

Link watches:

Link Summary:up

INSTANCE[LINK_WATCH_0]:

Name:ethtool

Link:up

Down count:0

5 Network Group configuration file

(1) Master configuration file

[Email protected] ~]# CAT/ETC/SYSCONFIG/NETWORK-SCRIPTS/IFCFG-TEAM0

Device=team0

team_config= "{\" Runner\ ": {\" name\ ": \" Loadbalance\ "}}"

Bootproto=none

Defroute=yes

Ipv4_failure_fatal=no

Name=team0

uuid=e70483a1-2688-4eb2-9466-8e732360291d

Onboot=yes

Devicetype=team

ipaddr=200.200.200.200

Prefix=24

gateway=200.200.200.1

(2) Group member (SLAVE) configuration file

[Email protected] ~]# cat/etc/sysconfig/network-scripts/ifcfg-team0-ens34

Name=team0-ens34

Uuid=a481fb6d-bf61-413d-a2c7-289966bee1a7

Device=ens34

Onboot=yes

Team_master=team0

Devicetype=teamport

6 Deleting a network group

(1) Disconnect

[Email protected] ~]# NMCLI connection down Team0

Connection ' TEAM0 ' successfully deactivated (d-bus active path:/ORG/FREEDESKTOP/NETWORKMANAGER/ACTIVECONNECTION/7)

View under Status

[Email protected] ~]# Teamdctl TEAM0 State

Device "Team0" does not exist

[Email protected] ~]# NMCLI connection Show

NAME UUID TYPE DEVICE

Ens33 be9d1f2f-20e0-4282-9cb5-0da4c8b0fc7c 802-3-ethernet Ens33

Virbr0 8b1532d4-d99b-4201-8163-44d733302230 Bridge VIRBR0

TEAM0 e70483a1-2688-4eb2-9466-8e732360291d Team--

TEAM0-ENS34 a481fb6d-bf61-413d-a2c7-289966bee1a7 802-3-ethernet--

TEAM0-ENS38 758d0eba-1625-46b2-b539-1d853a45be6b 802-3-ethernet--

You can see that the success has been closed

(2) Delete team Group members

[Email protected] ~]# NMCLI Connection Delete team0-ens34

Connection ' team0-ens34 ' (A481FB6D-BF61-413D-A2C7-289966BEE1A7) successfully deleted.

[Email protected] ~]# NMCLI Connection Delete team0-ens38

Connection ' team0-ens38 ' (758d0eba-1625-46b2-b539-1d853a45be6b) successfully deleted.

(3) Delete team Group

[Email protected] ~]# NMCLI Connection Delete Team0

Connection ' Team0 ' (e70483a1-2688-4eb2-9466-8e732360291d) successfully deleted.

Take a look

[Email protected] ~]# NMCLI connection Show

NAME UUID TYPE DEVICE

Ens33 be9d1f2f-20e0-4282-9cb5-0da4c8b0fc7c 802-3-ethernet Ens33

Virbr0 8b1532d4-d99b-4201-8163-44d733302230 Bridge VIRBR0

You have not seen TEAM0 related content, indicating that the deletion was successful

Networking Group Network Teaming

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.