check_email_loop.pl problem fixed
David Gentry
dgentry at ultainc.com
Tue Aug 30 21:44:26 CEST 2005
Hi Dave
Since I am not perl savvy, can you tell me if this is correct? This
is what my script shows:
Take line 104-116:
104
105 # Ok - check if it's time to release another mail
106
107 # ...
108
109 # creating new serial id
110 my $serial = time();
111 $serial = "ID#" . $serial . "#$$";
112
113
114 # sending new ping email
115 %other_smtp_opts={};
116 if ( $debug == 1 ) {
117 $other_smtp_opts{'Debug'} = 1;
118 }
Move it after line 149:
147
148 # Count messages, that we are looking 4:
Ins 149 while ($msgcount > 0) {
150 @msglines = @{$pop->top($msgcount,1)};
151 for (my $i=0; $i < scalar @messageids; $i++) {
152 if (messagematchsid(\@msglines,$messageids[$i])) {
153 $matchcount++;
154 # newest received mail than the others, ok remeber
id.
155 $newestid = $messageids[$i] if ($messageids[$i]
> $newestid || !defined $newestid);
156 $pop->delete($msgcount); # remove E-Mail from POP3
server
Right after the Ins.
Thanks.
- David Gentry (davidtechie)
-----------------------
This thread is located in the archive at this URL:
http://www.nagiosexchange.org/nagios-users.34.0.html?&tx_maillisttofaq_pi
1[showUid]=8776
-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.
::: Messages without supporting info will risk being sent to /dev/null
More information about the Users
mailing list