Sponsored Content
Full Discussion: Tomcat Monitoring log file
Top Forums Shell Programming and Scripting Tomcat Monitoring log file Post 302684133 by SkySmart on Thursday 9th of August 2012 07:53:05 AM
Old 08-09-2012
There are several log monitoring options available on the internet and sadly, most of them require some type of work. Your log monitoring endeavor can be significantly simplified if the log file you wish to monitor actually has date and timestamps in it...meaning, do the lines in the log contain some type of date and time?

if so, then,

1. you can either write your own log monitoring script: this would take a lot of time and can be very messy. There are several scenarios to consider to ensure you are actually informed when the state of the log file and its contents changes or matches your specified criteria.

2. you can grab programs off the internet that will attempt to monitor the log for you. the drawback to this (in my opinion) is that most of these programs require the installation of other applications or they require too much time to get accustom to. but if you need their names, here they are: swatch, splunk.

3. i have nagios installed in my environment and i use a tool called logrobot. you can do a search for logrobot and see if that fits your need. as far as i know, it doesn't send emails..except only via Nagios. but i guess it can be configured to do so via cron if thats what you needed.

if you dont have timestamps in your log file, things can get very messy and i would leave this to other members of this forum to provide their suggestions for this type of situation.

If you have Nagios, you may want to read this article:

http://ezinearticles.com/?Nagios-Log...ely&id=5862227

Last edited by SkySmart; 10-10-2012 at 09:59 AM.. Reason: Found a more detailed article
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Monitoring log file

Hi, I ned to monitor the tomcat log file called "catalina.out" for "Out of memory" error. the script should monitor this file and send us the mail as soon as it finds the string "Out of memory" in the file. can ypu suggest me which is the best way to do this? (4 Replies)
Discussion started by: shivanete
4 Replies

2. Shell Programming and Scripting

Monitoring Tomcat Instance using shell script

Hello Forum, I have prepared script to monitor the tomcat status. Following is the script which will monitor tomcat instance.I need little modifcation in the script. My script will grep for java,the output of grep command will analyze by if condition under for loop and will send following echo... (7 Replies)
Discussion started by: coolguyamy
7 Replies

3. Shell Programming and Scripting

help needed - log file monitoring script

hi Gurus, Need to pick your brains on this minor script project. I would like to continuously monitor a log file with sample log messages as below, and if PSOldGen percentage is either 99% or 100% for consecutively 10 times, alert someone. {Heap before gc invocations=46516: PSYoungGen ... (6 Replies)
Discussion started by: kenchen722
6 Replies

4. Shell Programming and Scripting

Tomcat log file in date format

Hi, I was asked to write a new logrotate file for tomcat logs..in which one of the requirement is to have date and time appended at the end of the file name. I have tried dateext and dateformat-%Y-%m-%d-%s but these directives didn't have the option for HH:MM. I am very new to this... (2 Replies)
Discussion started by: sdspawankumar
2 Replies

5. Solaris

Tomcat..Unable to deploy application remotely in tomcat

Hi, We have upgrade tomcat from 5.0.20 to 7.0.33 and made changes to server.xml file according to newer version.. how ever the upgrade went fine and now i am unable to deploy application remotely.. it is giving 403 access denied error.. we have seperate appbase directory mentioned in server.xml..... (0 Replies)
Discussion started by: phani4u
0 Replies

6. Shell Programming and Scripting

Monitoring Tomcat Service with shell script

Hello Forum, I have prepared script to monitor the tomcat status. Following is the script which will monitor tomcat instance. I need little modifcation in the script. My script will grep for process, the output of grep command will analyze by if condition under for loop and will send... (2 Replies)
Discussion started by: ooilinlove
2 Replies

7. Shell Programming and Scripting

Monitoring script for a log file

Hi, I need to get a script working to monitor a log file and throw an alert via mailx as soon as a particular error is encountered. I do not want repeatative email notifications of same error so simply cat logfile and grepping the error would not work. Here is what i planned but it seems... (2 Replies)
Discussion started by: roshan.171188
2 Replies

8. UNIX for Advanced & Expert Users

Alternative to tail -n -0 -F for monitoring live log file

Hello, I have been working on script which need to generate an alert based upon live logs. If string is found then an alert mail must triggered. tail -n -0 -F works fine to redirect the each latest line from live logs file to grep a pattern for matching but it seems to be not working on... (7 Replies)
Discussion started by: ketanraut
7 Replies

9. UNIX for Beginners Questions & Answers

Monitoring script for Log file

Hi, Iam new to unix , plz help me to write below script. I need to write a script for Monitoring log file when any error occurs it has to send a mail to specified users and it should be always pick latest error not the existing one and the script should be able to send mail all errors (more... (1 Reply)
Discussion started by: vij05
1 Replies

10. UNIX for Beginners Questions & Answers

Shell script for continuously monitoring log file

Hi I have written below log monitoring script to egrep multiple words and redirect the output to a text file and its working fine but I want to add some more below given functionality to it, which is very advance and im not very good in it, so please help if you can :) I am egrepping all the... (1 Reply)
Discussion started by: scazed
1 Replies
MODEMMANAGER(8) 					      System Manager's Manual						   MODEMMANAGER(8)

NAME
ModemManager - modem management daemon SYNOPSIS
ModemManager [--version] | [--help] ModemManager [--debug] [--log-level=<level>] [--log-file=<filename>] [--timestamps] [--relative-timestamps] DESCRIPTION
The ModemManager daemon provides a unified high level API for communicating with (mobile broadband) modems. While the basic commands are standardized, the more advanced operations (like signal quality monitoring while connected) varies a lot. ModemManager is a system daemon and is not meant to be used directly from the command line. OPTIONS
The following options are supported: --version Print the ModemManager software version and exit. --help Print ModemManager's available options and exit. --debug Runs ModemManager with "DEBUG" log level and without daemonizing. This is useful for debugging, as it directs log output to the con- trolling terminal in addition to syslog. --log-level=<level> Sets how much information ModemManager sends to the log destination (usually syslog's "daemon" facility). By default, only informa- tional, warning, and error messages are logged. Given level must be one of "ERR", "WARN", "INFO" or "DEBUG". --log-file=<filename> Specify location of the file where ModemManager will dump its log messages, instead of syslog. --timestamps Include absolute timestamps in the log output. --relative-timestamps Include timestamps, relative to the start time of the daemon, in the log output. SEE ALSO NetworkManager(8). 31 October 2011 MODEMMANAGER(8)
All times are GMT -4. The time now is 01:06 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy