[TOP TIP] Server monitoring (the cool way)

So you want to monitor one or more servers but you find nagios or icinga2 rather boring? You want to do some monitoring the way the cool admins are doing it? Maybe, you simply want to impress your fellow miserable co-workers? Or your ULTRAWIDE monitor just has too much free real-estate and you want to fill it with something.

So how do you do it? You do it the gkrellm way 8)

Install gkrellm on the server

yum install gkrellm-daemon
systemctl enable gkrellmd

The above should install and enable gkrellm with systemd, but before we start the daemon we need to properly configure it.

Configure gkrellm on the server

So open the configuration file at /etc/gkrellmd.conf and set the following parameters.

* update-hz, update frequency, anything above 5 seconds should be ok, unless you know what you are doing.

  • max-clients, should be set to 1 since we usually monitor only from one location

  • address, we listen at the local loopback address

  • port, any high numbered port is ok

update-hz 5
max-clients 1
address 127.0.0.1
port 19150

Now we may start our daemon and we are ready to listen for the client.

systemctl start gkrellmd

Install gkrellm on your desktop

yum install gkrellm

The above should install gkrellm. You may just type "gkrellm" and see it monitor your desktop system, since it is possible to execute gkrellm multiple times and have each instance monitor a different system.

Configure gkrellm on your desktop

There is no immediate configuration, once you start using gkrellm, you may use the graphical interface to configure all the different monitors. Each system being monitored will have its own configuration saved under the ~/.gkrellm2/ directory.

But, there is one little thing that we need to configure, ssh port redirection from the desktop system to the server. We avoid connecting directly the two (or more) systems via the TCP ports because the connection will NOT be secure, in addition, this method has the advantage of not running the daemon on a public interface.

We expect that you already have setup proper ssh access to the server as root. If you want, you could also modify the "gkrellmd" user/group with its own ssh certificate key, to avoid using root. But that is out of the scope of this "top tip" post.

So, the following ssh command will redirect the local 19150 port to the remote server 19150 port, both listening on the local loopback and not any public interface. Finally, we execute gkrellm and tell it to hit the redirected port.

ssh -N -f -L 19150:127.0.0.1:19150 root@server.domain.tld
gkrellm -f -s 127.0.0.1 -P 19150

Skin it, plugin it…

Find themes here

Find plugins here

Be cool

Now you are one of the cool admins. Let that breeze of coolness flow over you. 8)

0 Replies

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct