Monitoring logs using MultiTail
For any system administrator, monitoring log files is a very tedious task, and if we have to refer to more than one log file at the same time to troubleshoot any issue, it becomes even more difficult to keep switching between logs.
For such situations, we can use the MultiTail tool, which can help us to take a look at multiple log files in real time. Using MultiTail, we can display multiple log files in a single window or shell, and it will show us the last few lines of the log file in real time.
Getting ready
To use MultiTail, we don't have to set up anything in particular on our Linux system. Only the multitail
package needs to be installed. This can be done using this command:
apt-get install multitail
How to do itβ¦
Once the MultiTail tool has been installed, we can start using it as per our requirements using these commands:
If we want to view two log files using
multitail
, we will run this command:multitail /var/log/syslog /var/log/boot.log
We can see that...