CentOSLinuxTutorials

How To Install Ntopng on CentOS 7

ntop_logo

In this tutorial, we will show you how to install Ntopng on CentOS 7. For those of you who didn’t know, Ntop, short for Network Top, is an open-source network traffic monitoring and analysis tool that provides real-time insights into network activities. It offers a comprehensive set of features, including traffic statistics, protocol analysis, and user-friendly web interfaces, making it an invaluable asset for network administrators. By leveraging Ntop’s capabilities, you can gain deep visibility into your network, identify bottlenecks, detect anomalies, and optimize performance.

This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple. I will show you the step-by-step installation of Ntopng on CentOS 7.

Prerequisites

  • A server running one of the following operating systems: CentOS 7.
  • It’s recommended that you use a fresh OS install to prevent any potential issues.
  • SSH access to the server (or just open Terminal if you’re on a desktop).
  • A non-root sudo user or access to the root user. We recommend acting as a non-root sudo user, however, as you can harm your system if you’re not careful when acting as the root.

Install Ntopng on CentOS 7

Step 1. To begin, it’s crucial to update your CentOS 7 system to ensure you have the latest packages and security patches. Open a terminal and run the following commands:

sudo yum update -y
sudo yum upgrade -y

Step 2. Installing Dependencies.

Ntop relies on several dependencies to function properly. Install the required dependencies by executing the following command:

sudo yum install -y pfring n2disk nprobe

Step 3. Installing Ntopng on CentOS 7.

To install Ntop, you need to add the official Ntop repository to your CentOS system. Run the following command to create a new repository file:

sudo nano /etc/yum.repos.d/ntop.repo

Inside the file, add the following lines:

[ntop]
name=ntop packages
baseurl=https://packages.ntop.org/centos/7/x86_64/
enabled=1
gpgcheck=1
gpgkey=https://packages.ntop.org/centos/7/x86_64/ntop.key

With the Ntop repository added, you can now install Ntopng, the next-generation version of Ntop. Run the following command:

yum update
yum install ntopng ntopng-data
yum install redis php-pecl-redis

Step 4. Configure Ntopng.

Once installed, Ntopng needs a configuration file. For testing purposes, we can use the sample config file, but don’t forget to create a proper configuration file (man Ntopng) later:

cp /etc/ntopng/ntopng.conf.sample /etc/ntopng/ntopng.conf

Step 5. Start Ntopng and Redis server also enable the service to start at boot time:

systemctl start redis-server.service
systemctl enable redis-server.service
systemctl start ntopng.service
systemctl enable ntopng.service

Step 6. Configure ipables or firewall.

firewall-cmd --direct --add-rule ipv4 filter IN_public_allow 0 -m tcp -p tcp --dport 3000 -s 192.168.1.146 -j ACCEPT

Step 7. Access Ntopng.

If all is well, now you can test your Ntopng application by typing http://your-server-ip:3000. You will see Ntopng login page. For the first time, you can use user ‘admin’ and password ‘admin’.

Install Ntopng on CentOS 7

Congratulations! You have successfully installed Ntopng. Thanks for using this tutorial for installing Ntopng server monitoring on CentOS 7 systems. For additional help or useful information, we recommend you to check the official Ntopng website.

VPS Manage Service Offer
If you don’t have time to do all of this stuff, or if this is not your area of expertise, we offer a service to do “VPS Manage Service Offer”, starting from $10 (Paypal payment). Please contact us to get the best deal!

Save

r00t

r00t is a seasoned Linux system administrator with a wealth of experience in the field. Known for his contributions to idroot.us, r00t has authored numerous tutorials and guides, helping users navigate the complexities of Linux systems. His expertise spans across various Linux distributions, including Ubuntu, CentOS, and Debian. r00t's work is characterized by his ability to simplify complex concepts, making Linux more accessible to users of all skill levels. His dedication to the Linux community and his commitment to sharing knowledge makes him a respected figure in the field.
Back to top button