GICT knowledge base
How to Install Log.io on a Centos Server?
Published
How to Install Log.io on a Centos Server?
Log.io is a small simple but effective application build on top of Node.js and Socket.io, which allows monitoring Linux server log files in real time through web interface screen widgets. The users can easily watch their server log files through a web browser. It is powered by node.js. Let’s have a look into the installation of the Log.io.
1) Login to your server via SSH as root.
# ssh root@IP
2) Always it is a good practice to follow before any new installations make sure that the currently installed packages are up to date.
# yum update all -y
3) Before the installation, you will need to enable EPEL repository on your server. For that execute the following command.
#yum install http://mirror.us.leaseweb.net/epel/7/x86_64/e/epel-release-7-5.noarch.rpm
4) Verify the EPEL repository has been enabled on your server.
# yum repolist
5) Now we can install node.js and the NPM packages.
# yum install nodejs npm
6) After the installation of Node.js and NPM, it is time to install Log.io on the server. You can install Log.io using NPM.
# npm install -g log.io –user root
The installation may not take much time to complete. We have specified the user for the command we executed to install log.io. It is because we log.io need certain permissions in that case only it can monitor your server log files.
7) Now let’s see how to configure Log.io. The configuration files are located in the home directory of the user under a hidden directory called ‘log.io’.
# cd ~/.log.io/
8) Inside the directory “.log.io” you can see three configuration files as mentioned following.
harvester.conf
log_server.conf
web_server.conf
In the most of the cases, you will be needed to edit the file “harvest.conf” in which you can specify the log files which wanted to monitor. Open the file with your favorite text editor.
# vi harvester.conf
9) After editing the configuration file you have to start the log.io by executing the following commands.
# log.io-server &
# log.io-harvester &
10) Now open your favorite web browser and navigate to http://IP-ADDRESS:28778/ to access the log.io web interface.
Hence we have successfully installed the Log.io on the server.
If you need any further assistance please contact our support department.
