Search Results

How to Install VnStat – Long-Term Traffic Monitoring via CLI

Another interface monitoring tool that logs and keeps track of past traffic usage and statistics is VnStat.  VnStat is a console-based long-term traffic monitoring utility that makes use monitors traffic usage and details and stores them into flat database for future comparison and statistical purpose. VnStat does not require root access and privilege to do [...]

How to setup Transparent Proxy with Squid

One of the many tasks we could be facing from time to time in our work is setting up and building a production proxy server. Proxy implementation could be done in several ways to achieve the same goal. One best bet we could have with this kind of setup is by using Squid linux software [...]

How to Execute Script When Network Interface Goes down

Both on Linux and Windows world, we get used to a lot of things. This attitude of getting used to the world around us at times, shower us some attitude of just-accept-that and do-not-complain. Getting down to network connectivity, at times, we are just used to plug the cable and wait for it network card [...]

How to configure bonding in Fedora

First create a configuration file for your bond interface, like /etc/sysconfig/network-scripts/ifcfg-bond0. Remember that these files have a strict naming convention–they must say ifcfg- followed by the interface’s kernel name. Configure it as you would any interface: DEVICE=bond0 BOOTPROTO=none ONBOOT=yes NETWORK=192.168.1.0 NETMASK=255.255.255.0 IPADDR=192.168.1.101 USERCTL=yes Then create files for each of your slaves: # ifcfg-eth0 DEVICE=eth0 BOOTPROTO=none [...]

Bonding Options

balance-rr or 0 This is the default, transmitting packets in order from the first available slave through the last, for load balancing and fault tolerance. active-backup or 1 Only one of the bond slaves is used, and the others sit idle until the active slave fails. balance-xor or 2 This has two possible behaviors, which [...]

How to Configure and build bonding in Linux

Most popular distro kernels ship with the bonding driver already available as a module and the ifenslave user level control program installed and ready for use. If your distro does not, or you have need to compile bonding from source (e.g., configuring and installing a mainline kernel from kernel.org), you’ll need to perform the following [...]

How to change the hostname of a Linux system

hange the hostname on a running system On any Linux system you can change its hostname with the command ‘hostname‘ (surprised?)… Here are some quick usages of the command line hostname: hostname without any parameter it will output the current hostname of the system. hostname –fqd it will output the fully qualified domain name (or [...]

How to find hardware configuration of a Linux system

You can get the information directly from /proc, you can use lspci, etc. And if you are using X then there are many ways to show this information in a nice way. Still, I would like to show you the power of this little tool (lshw) that I found very useful if you are using [...]

How to quickly bind a range of IPs on RedHat based systems

Normally when you add a new IP to a network interface in a RedHat based system you create a file ifcfg-eth0:x in /etc/sysconfig/network-scripts/. For example: /etc/sysconfig/network-scripts/ifcfg-eth0:0 DEVICE=eth0:0 ONBOOT=yes BOOTPROTO=static IPADDR=192.168.0.100 NETMASK=255.255.255.0 NETWORK=192.168.0.0 BROADCAST=192.168.0.255 TYPE=Ethernet Similar to the above example you can create several aliases. But what if you have to add a lot of IPs [...]

How to create Bonding in Linux Server

Linux allows binding multiple network interfaces into a single channel/NIC using special kernel module called bonding. “The Linux bonding driver provides a method for aggregating multiple network interfaces into a single logical “bonded” interface. The behavior of the bonded interfaces depends upon the mode; generally speaking, modes provide either hot standby or load balancing services. Additionally, [...]

HOW TO CONFIGURE SENDMAIL

With the growth of the Internet, e-mail has quickly become the main vehicle to spread information through the public at large. As the demand for fast, cheap and reliable e-mail grows, more individuals are turning to Linux to provide a fast, cheap and reliable solution. sendmail was originally developed by Eric Allman, in 1979, as [...]

Add additional IPs to one NIC in Linux

Two commands: $ /sbin/ifconfig eth0:0 192.168.0.4 $ /sbin/route add -host 192.168.0.4 dev eth0:0 (replace that IP with the one you’d like to add) This change will no longer be in effect after rebooting. Therefor you must add the two commands to the bottom of your /etc/rc.local file. Your NIC should now be listening and responding [...]