Hi,
I have written some Java classes for raising traps directly to Mon over UDP.
I have noticed that even though I pass the current time in the trap to the
server, it always records the time the service failed as the same as the
time that the Mon server was started. It records the end time (the time I
send an 'ok' trap) with the correct time. I have tested it with Perl, and
the result is the same. The two scripts are included below.
Any ideas?
Anthony
1. DOWN.PL
#!/usr/bin/perl
use Mon::Client;
my $mon = new Mon::Client(host => "localhost", username => "me", password =>
"me");
die "$0 new Mon::Client failed\n" unless defined $mon;
$status = $mon->send_trap(
group => "test",
service => "test",
retval => 1,
opstatus => "fail",
summary => "Testing",
detail => "Testing Detail"
);
warn "$0: Mon::Client::send_trap failed\n" unless defined($status);
------------------
2. UP.PL
#!/usr/bin/perl
use Mon::Client;
my $mon = new Mon::Client(host => "localhost", username => "me", password =>
"me");
die "$0 new Mon::Client failed\n" unless defined $mon;
$status = $mon->send_trap(
group => "test",
service => "test",
retval => 1,
opstatus => "ok",
summary => "Testing",
detail => "Testing Detail"
);
warn "$0: Mon::Client::send_trap failed\n" unless defined($status);
CAUTION - This message may contain privileged and confidential information intended
only for the use of the addressee named above. If you are not the intended recipient
of this message you are hereby notified that any use, dissemination, distribution or
reproduction of this message is prohibited. If you have received this message in error
please notify AMCOR immediately. Any views expressed in this message are those of the
individual sender and may not necessarily reflect the views of AMCOR.