How to Install Netdata on CentOS 7

In this article, We are going to perform How to Install Netdata On CentOS 7 system or any other cloud platform like Amazon Ec2, Azure VM, Google Cloud Compute,etc. with preinstalled CentOS 7.

Introduction

Netdata is real-time performance,troubleshooting and health Monitoring tool for Applications and Systems.Netdata is free and Open Source tool which supports for Linux, FreeBSD and MacOS systems which is helpful for SysAdmins, DevOps and Developers for troubleshooting real time issues.

Prerequisites

  • CentOS 7 with Minimal Installation
  • SSH Access with sudo privileges
  • Open Firewall Port: 19999

Step 1: Install Netdata on CentOS

Before installing make sure system packages are up to date.

$ sudo yum update -y 

We have to install some dependency packages before installing netdata,

$ sudo yum install autoconf automake curl gcc git libmnl-devel libuuid-devel openssl-devel libuv-devel lz4-devel Judy-devel make nc pkgconfig python zlib-develnn -y

Next, We have to Clone the Netdata Packages from Git, Enter below command.

$ sudo git clone https://github.com/netdata/netdata.git --depth=100

Output:

$ sudo git clone https://github.com/netdata/netdata.git --depth=100
Cloning into 'netdata'...
remote: Enumerating objects: 2146, done.
remote: Counting objects: 100% (2146/2146), done.
remote: Compressing objects: 100% (1617/1617), done.
remote: Total 2146 (delta 653), reused 1415 (delta 480), pack-reused 0
Receiving objects: 100% (2146/2146), 3.69 MiB | 0 bytes/s, done.
Resolving deltas: 100% (653/653), done.
$ ls

Output:

netdata
$ cd netdata/

Install netdata using netdata official script.

$ sudo ./netdata-installer.sh

Output:

$ sudo ./netdata-installer.sh

^
|.-. .-. .-. .-. . netdata
| '-' '-' '-' '-' real-time performance monitoring, done right!
+----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+--->


You are about to build and install netdata to your system.

It will be installed at these locations:

- the daemon at /usr/sbin/netdata
- config files in /etc/netdata
- web files in /usr/share/netdata
- plugins in /usr/libexec/netdata
- cache files in /var/cache/netdata
- db files in /var/lib/netdata
- log files in /var/log/netdata
- pid file at /var/run/netdata.pid
- logrotate file at /etc/logrotate.d/netdata

This installer allows you to change the installation path.
Press Control-C and run the same command with --help for help.


NOTE:
Anonymous usage stats will be collected and sent to Google Analytics.
To opt-out, pass --disable-telemetry option to the installer.

Press ENTER to build and install netdata to your system >

Press “Enter”  Key  to proceed installation, after successful installation you will see below output at end.

Output:

netdata by default listens on all IPs on port 19999,
so you can access it with:

http://this.machine.ip:19999/

To stop netdata run:

systemctl stop netdata

To start netdata run:

systemctl start netdata

Uninstall script copied to: /usr/libexec/netdata/netdata-uninstaller.sh

--- Installing (but not enabling) the netdata updater tool ---
Update script is located at /usr/libexec/netdata/netdata-updater.sh

--- Check if we must enable/disable the netdata updater tool ---
You chose *NOT* to enable auto-update, removing any links to the updater from cron (it may have happened if you are reinstalling)

Removing cron reference: /etc/cron.daily/netdata-updater

--- Wrap up environment set up ---
Preparing .environment file
[/home/adminstraviso/netdata]# chmod 0644 /etc/netdata/.environment
OK

Setting netdata.tarball.checksum to 'new_installation'

--- We are done! ---

^
|.-. .-. .-. .-. .-. . netdata .-. .-
| '-' '-' '-' '-' '-' is installed and running now! -' '-'
+----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+--->

enjoy real-time performance and health monitoring...

Finally, We need to Start and Enable the Netdata service to make the changes effect.

$ sudo systemctl start netdata

$ sudo systemctl enable netdata

$ sudo systemctl status netdata

Output:

$ sudo systemctl status netdata
● netdata.service - Real time performance monitoring
Loaded: loaded (/usr/lib/systemd/system/netdata.service; enabled; vendor preset: disabled)
Active: active (running) since Sat 2020-01-18 00:09:20 CST; 4min 10s ago
Main PID: 74401 (netdata)
CGroup: /system.slice/netdata.service
├─74401 /usr/sbin/netdata -P /var/run/netdata/netdata.pid -D -W set global process scheduling policy keep -W set global OOM score keep
├─74482 bash /usr/libexec/netdata/plugins.d/tc-qos-helper.sh 1
├─74484 /usr/libexec/netdata/plugins.d/go.d.plugin 1
├─74519 /usr/bin/python /usr/libexec/netdata/plugins.d/python.d.plugin 1
└─74523 /usr/libexec/netdata/plugins.d/apps.plugin 1

 Starting Real time performance monitoring...
 Started Real time performance monitoring.
 SIGNAL: Not enabling reaper
 netdata INFO : MAIN : SIGNAL: Not enabling reaper

Step 2: Netdata Web Interface

Open a browser and type the following URL of http://localhost:19999 OR http://IP-Address:19999

netdata web interface on centos 7

Finally, We have Installed Netdata Monitoring tool on CentOS 7.

Step 3: Configure Netdata Alarm Email Notification

Netdata supports different typed alarm notification methods such as Amazon SNS,email,IRC,slack..,etc. To know more about supported notifications method, go through this link.

For Email notification , Netdata supports Sendmail as MTA (Mail Transfer Agent), make sure you have installed and configured sendmail on your system, if not go through below link.

How to Configure Sendmail to Relay Emails using Gmail SMTP on Ubuntu 18.04/16.04 LTS.

To learn more about Netdata. Please refer Netdata official documentation.

Conclusion

In this article, we have performed How to Install Netdata On CentOS 7 System.

Related Articles

How to Install Netdata On Ubuntu 18.04/16.04 LTS system.

How to download and Install Nagios on Ubuntu 18.04/16.04 LTS

How to Install ELK Stack on Ubuntu

How to Install Splunk on Ubuntu 18.04/16.04 LTS

How to Install Splunk Enterprise on CentOS 7

Shivdas Kanade

I am Shivdas Kanade working as DevOps Engineer. Passionate about Linux, Open Source and DevOps Tools. Believe in sharing knowledge.

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.

0 Shares
Share via
Copy link