Page 1 of 2

plugin to monitor remote unix server oracle alert log file

Posted: Thu Sep 06, 2012 10:59 am
by maxwellmiranda
plugin to monitor remote unix server oracle alert log file for ORA- errors...

i will be using SSH for monitoring this file...

do you have any plugin for this

Re: plugin to monitor remote unix server oracle alert log fi

Posted: Thu Sep 06, 2012 11:12 am
by lmiltchev
Here's our documentation on monitoring hosts via SSH:

http://assets.nagios.com/downloads/nagi ... ng_SSH.pdf

Is this what you were looking for?

Re: plugin to monitor remote unix server oracle alert log fi

Posted: Thu Sep 06, 2012 11:36 am
by maxwellmiranda
No...i need to monitor a log file for certain patterns on a remote aix host

Re: plugin to monitor remote unix server oracle alert log fi

Posted: Thu Sep 06, 2012 1:31 pm
by scottwilkerson
I believe this can do what you are looking for, in perl

http://exchange.nagios.org/directory/Pl ... nt/details

Re: plugin to monitor remote unix server oracle alert log fi

Posted: Thu Sep 06, 2012 2:48 pm
by maxwellmiranda
does this require any installation on the remote machine that i will be monitoring in order to make this Perl script work?

Re: plugin to monitor remote unix server oracle alert log fi

Posted: Thu Sep 06, 2012 3:39 pm
by scottwilkerson
This perl script would be installed on the remote machine and then called via NRPE or check_by_ssh

Re: plugin to monitor remote unix server oracle alert log fi

Posted: Thu Sep 13, 2012 2:02 pm
by maxwellmiranda
i tried another script that was available on nagios on remote server....i get the following error

remhau:/users/nagios> ./check_log3.pl -h
Can't locate utils.pm in @INC (@INC contains: /usr/opt/perl5/lib/5.8.8/aix-thread-multi /usr/opt/perl5/lib/5.8.8 /usr/opt/perl5/lib/site_perl/5.8.8/aix-thread-multi /usr/opt/perl5/lib/site_perl/5.8.8 /usr/opt/perl5/lib/site_perl .) at ./check_log3.pl line 147.
BEGIN failed--compilation aborted at ./check_log3.pl line 147.

Re: plugin to monitor remote unix server oracle alert log fi

Posted: Fri Sep 14, 2012 7:26 am
by scottwilkerson
This plugin also expects to find the utils.pm file in it's directory. You can find a copy of it on your Nagios XI server in /usr/local/nagios/libexec

Re: plugin to monitor remote unix server oracle alert log fi

Posted: Fri Sep 14, 2012 1:10 pm
by maxwellmiranda
i tried..but now it is showing incorrect result...it shows no matches found even if there is a text in the file i am searching

remhau:/users/nagios> check_log3.pl -l '/u01/oracle/admin/remprd10/bdump/alert_remprd10.log' -s alertlog.seek -p 'autobackup'
OK - No matches found.
remhau:/users/nagios> check_log3.pl -l '/u01/oracle/admin/remprd10/bdump/alert_remprd10.log' -s alertlog.seek -p autobackup
OK - No matches found.
remhau:/users/nagios> check_log3.pl -l '/u01/oracle/admin/remprd10/bdump/alert_remprd10.log' -s alertlog.seek -p Thread
OK - No matches found.
remhau:/users/nagios> check_log3.pl -l '/u01/oracle/admin/remprd10/bdump/alert_remprd10.log' -s alertlog.seek -p Thread -w 1


the file i am checking has the following text in it"

-------------
Fri Sep 14 04:01:05 2012
ALTER SYSTEM ARCHIVE LOG
Fri Sep 14 04:01:05 2012
Thread 1 advanced to log sequence 11741 (LGWR switch)
Current log# 2 seq# 11741 mem# 0: /u04/oradata/remprd10/redo02b.log
Current log# 2 seq# 11741 mem# 1: /u05/oradata/remprd10/redo02a.log
Fri Sep 14 04:01:18 2012
Starting control autobackup
Control autobackup written to DISK device
handle '/dbbackups/remprd/backup/ctlbkp_remprd10_c-1166144379-20120914-00.CTL'
Fri Sep 14 09:05:41 2012
Thread 1 advanced to log sequence 11742 (LGWR switch)
Current log# 3 seq# 11742 mem# 0: /u04/oradata/remprd10/redo03b.log
Current log# 3 seq# 11742 mem# 1: /u05/oradata/remprd10/redo03a.log
Fri Sep 14 12:00:44 2012
ALTER SYSTEM ARCHIVE LOG
Fri Sep 14 12:00:44 2012
Thread 1 advanced to log sequence 11743 (LGWR switch)
Current log# 1 seq# 11743 mem# 0: /u04/oradata/remprd10/redo01b.log
Current log# 1 seq# 11743 mem# 1: /u05/oradata/remprd10/redo01a.log
Fri Sep 14 12:00:53 2012
Starting control autobackup
Control autobackup written to DISK device
handle '/dbbackups/remprd/backup/ctlbkp_remprd10_c-1166144379-20120914-01.CTL'


----------------

Re: plugin to monitor remote unix server oracle alert log fi

Posted: Wed Sep 19, 2012 10:49 am
by maxwellmiranda
can someone look into this and reply