Monitoring a server with GKrellM remotely over SSH

I would like to monitor my server on my desktop computer with the GKrellM-utility. I would also like to have it run over ssh, so that it can run over the internet without being open to everyone. So here’s what I did:

  • First step is to set up key-based passwordless login.
  • Install gkrellmd (gkrellm-server). As I use debian I type “apt-get install gkrellmd”. Use your flavor of package-manager.
  • (optional) Edit /etc/gkrellmd.conf if there’s anything you’d like to change. The default works perfectly when using SSH-tunnels, because it looks like you’re running from localhost. If you don’t want to run over SSH you could add your desktop’s IP in allowed-host. Restart gkrellmd if you have changed the config.
  • Now open a SSH-tunnel on your desktop to your server. The text in red you should change to your wish, and the text in green is OK if you didn’t change anything in the config-file.
  • ssh -N -f -L 19150:127.0.0.1:19150 user@server
  • The red number is the local port which leads to your tunnel. If you want to monitor more than one computer you’ll need to change this number to an available port (check with netstat -nt). The red text is of course your user login on the server.
  • run:
  • gkrellm -s 127.0.0.1 -P 19150
  • The red number should be the same as above.
  • GKrellM should pop up and do it’s thing :)

Leave a Reply