I am looking for a script ( bash / perl / python ) which uppon calling by cron every 5 seconds it will check if new lines were added to my specific log files. If there are any new lines, the script should mail to root the notification containing the log event.
Is there any way that I can accomplish this ?