Monitor Linux With Netdata

Monitoring Linux with Netdata

Netdata is a real-time resource monitoring tool with a friendly web front-end developed and maintained by FireHOL. With this tool, you can read charts representing resource utilization of things like CPUs, RAM, disks, network, Apache, Postfix and more. It is similar to other monitoring software like Nagios; however, Netdata is only for real-time monitoring via a web interface.

Understanding Netdata

There’s currently no authentication, so if you’re concerned about someone getting information about the applications you’re running on your system, you should restrict who has access via a firewall policy. The UI is simplified in a way anyone could look at the graphs and understand what they’re seeing, or at least be impressed by your flashy setup.

The web front-end is very responsive and requires no Flash plugin. The UI doesn’t clutter things up with unneeded features, but sticks to what it does. At first glance, it may seem a bit much with the hundreds of charts you have access to, but luckily the most commonly needed charts (i.e. CPU, RAM, network, and disk) are at the top. If you wish to drill deeper into the graphical data, all you have to do is scroll down or click on the item in the menu to the right. Netdata even allows you to control the chart with play, reset, zoom and resize with the controls on the bottom right of each chart.

Netdata chart control

Netdata chart control

When it comes down to system resources, the software doesn’t need too much either. The creators choose to write the software in C. Netdata doesn’t use much more than ~40MB of RAM.

Netdata memory usage

Netdata memory usage

Download Netdata

To download this software, you can head over to Netdata GitHub page. Then click the “Clone or download” green button on the left of the page. You should then be presented with two options.

Via the ZIP file

One option is to download the ZIP file. This will include everything in the repository; however, if the repository is updated then you will need to download the ZIP file again. Once you download the ZIP file, you can use the

unzip

tool in the command line to extract the contents. Running the following command will extract the contents of the ZIP file into a ”

netdata

” folder.

$ cd ~/Downloads
$ unzip netdata-master.zip
Netdata unzipped

Netdata unzipped

You don’t need to add the

-d

option in

unzip

because their content is inside a folder at the root of the ZIP file. If they didn’t have that folder at the root,

unzip

would have extracted the contents in the current directory (which can be messy).

Via git

The next option is to download the repository via

git

. You will, of course, need git installed on your system. This is usually installed by default on Fedora. If not, you can install git from the command line with the following command.

$ sudo dnf install git

After installing

git

, you will need to “clone” the repository to your system. To do this, run the following command.

$ git clone https://github.com/firehol/netdata.git

This will then clone (or make a copy of) the repository in the current working directory.

Install Netdata

There are some packages you will need to build Netdata successfully. Luckily, it’s a single line to install the things you need (as stated in their installation guide). Running the following command in the terminal will install all of the dependencies you need to use Netdata.

$ dnf install zlib-devel libuuid-devel libmnl-devel gcc make git autoconf autogen automake pkgconfig

Once the required packages are installed, you will need to

cd

into the

netdata/

directory and run the

netdata-installer.sh

script.

$ sudo ./netdata-installer.sh

You will then be prompted to press enter to build and install the program. If you wish to continue, press enter to be on your way!

Netdata install.

Netdata install.

If all goes well, you will have Netdata built, installed, and running on your system. The installer will also add an uninstall script in the same folder as the installer called

netdata-uninstaller.sh

. If you change your mind later, running this script will remove it from your system.

You can see it running by checking its status via

systemctl

.

$ sudo systemctl status netdata

Accessing Netdata

Now that we have Netdata installed and running, you can access the web interface via port 19999. I have it running on a test machine, as shown in the screenshot below.

An overview of what Netdata running on your system looks like

An overview of what Netdata running on your system looks like

Congratulations! You now have successfully installed and have access to beautiful displays, graphs, and advanced statistics on the performance of your machine. Whether it’s for a personal machine so you can show it off to your friends or for getting deeper insight into the performance of your server, Netdata delivers on performance reporting for any system you choose.


Image courtesy Mitchel Bootoriginally posted to Unsplash here.

Using Software

12 Comments

  1. This is a really wonderful tool and I recommend to use it cause it’s worthy.
    Thanks for share,

  2. Frank Ch. Eigler

    “The web front-end is very responsive and requires no plugins like Flash or even JavaScript. ”

    Might want to double-check on that. I only see a richly javascripty UI on the my-netdata.io demo pages.

  3. Travis Mattila

    The guide worked 99.99% for me, when i ran (sudo ./netdata-installed.sh) i got error messages (yes i have sudo enabled) to make it work i had to do su and then ran the .sh and it loaded.
    Thanks for the guide, it was very clear and easy.

  4. Aaron Rumbold

    There’s a typo in the installer line:

    $ sudo ./netdata-installed.sh

  5. Edward

    why not just systemctl enable cockpit

    • @Edward: Cockpit is also a great way to monitor system resources. The Magazine isn’t about only giving you one way to do things. We know there are many tools and utilities for some jobs, and try to show you more than one way to peel a potato.

  6. mosquito

    Fast install netdata:
    $ sudo dnf copr enable mosquito/netdata
    $ sudo dnf install netdata
    $ sudo systemctl start netdata.service
    Visit http://localhost:19999

    This Copr repository has supported el6, el7, fc22-25. Please see https://copr.fedorainfracloud.org/coprs/mosquito/netdata/

    • Rafael Reuber

      Hey mosquito, your repository is awesome! Its already have the last version of netdata.
      Thank you for share!

  7. This is absolutely gorgeous.

  8. Tom Bates

    Can’t access from my PC…. URL = http://192.168.0.19:19999/

    I can access Cockpit… URL = https://192.168.0.19:9090/

    I tried with https, no go….

    Ideas?

Comments are Closed

The opinions expressed on this website are those of each author, not of the author's employer or of Red Hat. Fedora Magazine aspires to publish all content under a Creative Commons license but may not be able to do so in all cases. You are responsible for ensuring that you have the necessary permission to reuse any work on this site. The Fedora logo is a trademark of Red Hat, Inc. Terms and Conditions