Centos- card configuration

Program objectives: Familiar Linux NIC
1. Modify the name card, replace the card automatically generated name
2. Create a new profile with a new network adapter card relationship
3. NIC bond mode configuration
4.NetworkManager-nmcli management network

1. Modify the default name of the NIC
configuration file name device value in the ifcfg-eth0 file names consistent with
vim /etc/udev/rules.d/70-persistent-net.rules # modify the device configuration rules file
SUBSYSTEM == "net", "? *" ACTION == "add ", DRIVERS ==, ATTR {address} == "00: 0c: 29: a3: b1: 5c", ATTR {type} == "1", KERNEL == "eth # modify the name MAC value * ", nAME =" eno16 "
take effect after reboot

2. Create a new relationship with the new card profile card
default linux virtual machine does not generate a new network card configuration files automatically after the card, manually copy the modified
dd delete UUID / HARDW configure, modify parameters ip

3. NIC bond mode configuration
Linux NIC bonding mode There are seven (0 ~ 6) bond0, bond1, bond2, bond3, bond4, bond5, bond6
bond0 (Balance-rr) Round-Robin Policy (balance swung round robin policy), you need to "Switch" is set, port group
mod = 1 (active-backup) Active-backup policy ( primary - backup policy)
MOD = 2 (balance-XOR) the XOR policy (balancing policy)
MOD. 3 = broadcast (broadcast policy)
MOD = 4 (802.3ad) IEEE 802.3ad dynamic link aggregation (IEEE 802.3ad link aggregation dynamic), configure the switch port aggregation
mod = 5 (balance-tlb) Adaptive transmit load balancing ( the adapter to transmit load balancing)
MOD =. 6 (ALB-Balance ) adaptive load balancing (adapter adaptive load balancing), the switch configuration without
common bond 0, 1, 6

4.NetworkManager-nmcli management network
nmcli general status # show the overall state of NetworkManager
nmcli connection show # Display all connection
nmcli connection show -a # show active connections
nmcli device status # Display the device list NetworkManager identified and their current status
nmcli device disconnect / connect eno16777736 # stop / start card == ifup / down

Guess you like

Origin www.cnblogs.com/kylingx/p/11616882.html