Q: - What is network bonding in
Linux and steps to configure network bonding ?
Network interface card (NIC) bonding (also referred to as NIC teaming) is the bonding together of two or more physical NICs so that they appear as one logical device. This allows for improvement in network performance by increasing the link speed beyond the limits of one single NIC and increasing the redundancy for higher availability. For example, you can use two 1-gigabit NICs bonded together to establish a 2-gigabit connection to a central file server.
Network interface card (NIC) bonding (also referred to as NIC teaming) is the bonding together of two or more physical NICs so that they appear as one logical device. This allows for improvement in network performance by increasing the link speed beyond the limits of one single NIC and increasing the redundancy for higher availability. For example, you can use two 1-gigabit NICs bonded together to establish a 2-gigabit connection to a central file server.
When bonded together, two or more
physical NICs can be assigned one IP address. And they will represent the same
MAC address. If one of the NICs fails, the IP address remains accessible
because it is bound to the local NIC rather than to a single physical NIC.
Steps to configure :
Steps to configure :
Step #1: Create a bond0
configuration file
Red Hat Linux stores network
configuration in /etc/sysconfig/network-scripts/ directory. First, you need to
create bond0 config file:
# vi
/etc/sysconfig/network-scripts/ifcfg-bond0
Append following lines to it:
DEVICE=bond0
IPADDR=192.168.1.20
NETWORK=192.168.1.0
NETMASK=255.255.255.0
USERCTL=no
BOOTPROTO=none
ONBOOT=yes
IPADDR=192.168.1.20
NETWORK=192.168.1.0
NETMASK=255.255.255.0
USERCTL=no
BOOTPROTO=none
ONBOOT=yes
Replace above IP address with your
actual IP address. Save file and exit to shell prompt.
Step #2: Modify eth0 and eth1 config
files:
Open both configuration using vi
text editor and make sure file read as follows for eth0 interface
# vi /etc/sysconfig/network-scripts/ifcfg-eth0
Modify/append directive as follows:
DEVICE=eth0
USERCTL=no
ONBOOT=yes
MASTER=bond0
SLAVE=yes
BOOTPROTO=none
# vi /etc/sysconfig/network-scripts/ifcfg-eth0
Modify/append directive as follows:
DEVICE=eth0
USERCTL=no
ONBOOT=yes
MASTER=bond0
SLAVE=yes
BOOTPROTO=none
Open eth1 configuration file using
vi text editor:
# vi
/etc/sysconfig/network-scripts/ifcfg-eth1Make sure file read as follows for
eth1 interface:
DEVICE=eth1
USERCTL=no
ONBOOT=yes
MASTER=bond0
SLAVE=yes
BOOTPROTO=none
USERCTL=no
ONBOOT=yes
MASTER=bond0
SLAVE=yes
BOOTPROTO=none
Save file and exit to shell prompt.
Step # 3: Load bond driver/module
Make sure bonding module is loaded
when the channel-bonding interface (bond0) is brought up. You need to modify
kernel modules configuration file:
# vi /etc/modprobe.conf
Append following two lines:
Append following two lines:
alias bond0 bonding
options bond0 mode=balance-alb miimon=100
options bond0 mode=balance-alb miimon=100
Step # 4: Test configuration
First, load the bonding module:
# modprobe bonding
Restart networking service in order to bring up bond0 interface:
# service network restart
# modprobe bonding
Restart networking service in order to bring up bond0 interface:
# service network restart
Verify everything is working:
# less /proc/net/bonding/bond0Output:
# less /proc/net/bonding/bond0Output:
Bonding Mode: load balancing
(round-robin)
MII Status: up
MII Polling Interval (ms): 0
Up Delay (ms): 0
Down Delay (ms): 0
Slave Interface: eth0
MII Status: up
Link Failure Count: 0
Permanent HW addr:
00:0c:29:c6:be:59
Slave Interface: eth1
MII Status: up
Link Failure Count: 0
Permanent HW addr:
00:0c:29:c6:be:63
Q: - What is the difference between
LILO and GRUB ?
1) LILO has no interactive command
interface, whereas GRUB does.
2) LILO does not support booting from a network, whereas GRUB does.
3) LILO stores information regarding the location of the operating systems it can to load physically on the MBR.
2) LILO does not support booting from a network, whereas GRUB does.
3) LILO stores information regarding the location of the operating systems it can to load physically on the MBR.
If you change your LILO config file,
you have to rewrite the LILO stage one boot loader to the MBR. Compared with
GRUB, this is a much more risky option since a misconfigured MBR could leave
the system unbootable. With GRUB, if the configuration file is configured
incorrectly, it will simply default to the GRUB command-line interface.
For more Questions click here
For more Questions click here