When it comes to monitoring a Linux box, there are more than enough options to choose from. While there are many production-quality monitoring solutions (e.g., Nagios, Zabbix, Zenoss), boasting of fancy UI, monitoring scalability, comprehensive reporting capabilities, etc., these solutions are probably an overkill for most of us end users. If all you need is to check the basic status (e.g., CPU load, memory usage, active processes) of a remote Linux server or desktop, consider [linux-dash][1].
linux-dash is a web-based lightweight monitoring dashboard for Linux machines, which can display, in real-time, various system properties, such as CPU load, RAM usage, disk usage, Internet speed, network connections, RX/TX bandwidth, logged-in users, running processes etc. linux-dash does not come with any backend database for storing long-term statistics. Simply drop in linux-dash app in an existing web server (e.g., Apache, Nginx), and you are good to go. It is a quick and easy way to set up remote monitoring for personal projects.
In this tutorial, I am going to describe **how to set up linux-dash in Nginx web server on Linux**. Nginx is preferred over Apache web server due to its lightweight engine.
### Set up linux-dash on Debian, Ubuntu or Linux Mint ###
Configure php-fpm by editing /etc/php5/fpm/pool.d/www.conf. Make sure to edit "user", "group" and "listen" directives as shown below. You can keep the rest of the configuration unchanged.
Next, configure php-fpm by editing /etc/php-fpm.d/www.conf. In this file, make sure to set "listen", "user" and "group" fields as below. You can leave the rest of the configuration unchanged.
Finally, restart Nginx web server as well as php-fpm, and set them to auto-start upon boot.
$ sudo service php-fpm restart
$ sudo service nginx restart
$ sudo chkconfig nginx on
$ sudo chkconfig php-fpm on
In this example, we have configured linux-dash to use TCP port 8080. So make sure that the firewall is not blocking TCP port 8080.
### Monitor a Linux Machine with linux-dash ###
To access linux-dash from a web browser, simply go to http://<linux-IP-address>:8080/linux-dash/ on your web browser.
Below are the screenshots of linux-dash. The web dashboard consists of several widgets, each of which displays particular system properties. You can customize the look of the web dashboard by rearranging and/or closing some of the widgets. [Here][3] is a demo site set up by the creator of linux-dash.