This could be useful when you really need to shutdown... some kind of a "Vulcan Key" to the kernel :)
#echo 1 > /proc/sys/kernel/sysrq
#echo o > /proc/sysrq-trigger
Showing posts with label linux. Show all posts
Showing posts with label linux. Show all posts
Thursday, 25 April 2013
Tuesday, 23 February 2010
My 10 UNIX Command Line Mistakes
A very good (and tragicomic) article. Sometimes we play down the importance of an enter in the cli.
One of my greatest errors was a typo in a Solaris... crontab -r it's not the same as crontab -e (despite the position of the keys!)
Link here
One of my greatest errors was a typo in a Solaris... crontab -r it's not the same as crontab -e (despite the position of the keys!)
Link here
Tuesday, 16 February 2010
Bonding interfaces in Linux
Bonding interfaces provides lb/ft to a network connection. So, if you have a lot of nics and a managed switch (supporting trunking), bonding will be a very good option!
First, create a bond interface file:
# vi /etc/sysconfig/network-scripts/ifcfg-bond0
DEVICE=bond0
IPADDR=x.x.x.x
NETWORK=x.x.x.x
NETMASK=x.x.x.x
USERCTL=no
BOOTPROTO=none
ONBOOT=yes
Next, set the first interface in the bond:
# vi /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE=eth0
USERCTL=no
ONBOOT=yes
MASTER=bond0
SLAVE=yes
BOOTPROTO=none
Then, the second interface:
# vi /etc/sysconfig/network-scripts/ifcfg-eth1
DEVICE=eth1
USERCTL=no
ONBOOT=yes
MASTER=bond0
SLAVE=yes
BOOTPROTO=none
Add the bonding module to the modules configuration:
# vi /etc/modprobe.conf
alias bond0 bonding
options bond0 mode=0 miimon=100
Mode 0 for fault tolerance, mode 1 for load balance.
To see a full list of the bonding available modes, go to the official Red Hat KB article here.
Check the bonding module:
# modprobe bonding
Restart the network service:
# service network restart
Check the status of the bond:
# less /proc/net/bonding/bond0
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
Thats all... always remember to check /proc/net/bonding/bond0 for link failures.
Subscribe to:
Posts (Atom)