How To Monitor Network Traffic in Real Time on CentOS 6?

Introduction

In this Vultr tutorial, you will learn how to view incoming and outgoing traffic in real-time using nload. This tool can be useful when you are trying to gauge how much bandwidth your server will use for the month.

This tutorial will work with both 32 and 64 bit systems of CentOS 6.

Installing nload

You only need to install the nload package, which is in the EPEL repository. If you don't have the EPEL repository setup, you can learn how to configure it in this tutorial.

yum -y install nload

Using nload

To run nload, enter the following command (respectively to your Ethernet adapter's name). If you're on another type of virtualization (e.g. KVM or Xen), the ethernet adapter's name can vary from eth0 to even just eth.

nload venet0

nload allows you to define the unit used for network traffic:

nload venet0 -u b|k|g
  • b = bytes
  • k = kilobytes
  • g = gigabytes

A graph will start building shortly after you enter the commands. This is what it will look like:

nload.gif

If you wish to log the graphing information, increase the interval time and dump it to a file. In the example below, 500 is the interval.

cd ~
mkdir logs
cd logs
nload -t 500 | tee graph.log

Congratulations, you can now use nload on your Vultr VPS. If you no longer need it, nload can be removed by typing:

yum -y remove nload
 
  • 0 Utenti hanno trovato utile questa risposta
Hai trovato utile questa risposta?

Articoli Correlati

Choosing an OS: CentOS, Ubuntu, Debian, FreeBSD, CoreOS, or Windows Server

Choosing an OS for your server can be difficult. You're aware that it's important to choose a...

What Ports Are Blocked?

Vultr blocks several ports that are commonly abused for DDOS attacks: TCP & UDP port 17...

Configuring Private Network

If you're assigning a private network to an existing machine (or deploying your own operating...

Configuring Static Networking and IPv6 on CentOS 7

VULTR has recently made changes on their end, and everything should now work fine 'out of the...

How Do I Generate SSH Keys?

An SSH Key allows you to log into your server without needing a password. SSH Keys can be...

Powered by WHMCompleteSolution