November 18

Linux: Bonding – Generic with mode 0

nano /etc/modprobe.d/bond1.conf
alias bond0 bonding
options bond0 mode=0 miimon=100

nano /etc/sysconfig/network-scripts/ifcfg-bond0
DEVICE=bond0
IPADDR=192.168.0.4
NETMASK=255.255.255.0
NETWORK=192.168.0.0
BROADCAST=192.168.0.255
ONBOOT=yes
BOOTPROTO=none
TYPE=Bond
BONDING_MASTER=yes
PREFIX=24
DEFROUTE=yes
NAME="Bond bond0"
BONDING_OPTS="mode=active-backup miimon=0 arp_ip_target=192.168.0.2 arp_interval=1000"
LAST_CONNECT=1530826407
NM_CONTROLLED=no

nano /etc/sysconfig/network-scripts/ifcfg-bond1
DEVICE=bond1
TYPE=Bond
BONDING_MASTER=yes
NAME=bond1
ONBOOT=yes
BONDING_OPTS="mode=4 miimon=100"
NM_CONTROLLED=no

Force a failover
ifenslave -c bond0 nic-id

Look at bonding state
cat /proc/net/bonding/bond0
Category: Linux | Comments Off on Linux: Bonding – Generic with mode 0
November 18

Linux: Network Connection Speed information

1. ifconfig (to find ethernet card name)
p5p1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 192.168.1.10  netmask 255.255.255.0  broadcast 192.168.1.255
        inet6 fe80::c15d:1159:3654:2fc6  prefixlen 64  scopeid 0x20<link>
        ether 00:0a:f7:a4:13:18  txqueuelen 1000  (Ethernet)
        RX packets 349930173  bytes 29236710276 (27.2 GiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 1149185442  bytes 16287580311793 (15.7 TiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

2. dmesg | grep p5p1
[   14.659351] IPv6: ADDRCONF(NETDEV_UP): p5p1: link is not ready
[   14.697067] bnxt_en 0000:05:00.0 p5p1: NIC Link is Up, 10000 Mbps full duplex, Flow control: none
[   14.697072] bnxt_en 0000:05:00.0 p5p1: EEE is not active

3.ethtool p5p1
Settings for p5p1:
	Supported ports: [ TP ]
	Supported link modes:   1000baseT/Full 
	                        10000baseT/Full 
	Supported pause frame use: Symmetric Receive-only
	Supports auto-negotiation: Yes
	Supported FEC modes: Not reported
	Advertised link modes:  1000baseT/Full 
	                        10000baseT/Full 
	Advertised pause frame use: Symmetric
	Advertised auto-negotiation: Yes
	Advertised FEC modes: Not reported
	Speed: 10000Mb/s
	Duplex: Full
	Port: Twisted Pair
	PHYAD: 12
	Transceiver: internal
	Auto-negotiation: on
	MDI-X: Unknown
	Supports Wake-on: d
	Wake-on: d
	Current message level: 0x00000000 (0)
			       
	Link detected: yes
Category: Linux | Comments Off on Linux: Network Connection Speed information