Xymon Mailing List Archive search

Perl client without xymon client. (OPEN)

list Oyvind Bjorge
Thu, 9 Aug 2012 14:26:41 +0000
Message-Id: <user-276f647e7ed1@xymon.invalid>

The syntax of the bb-protocol was described in bb-doc, so tested with the following perl subroutine and it worked.

- Øyvind


sub sendToXymon {
   use IO::Socket;
   my($server,$port,$host,$test,$color,$date,$subject,$string) = @_ ;
   my $sock = new IO::Socket::INET (
                                    PeerAddr => $server,
                                    PeerPort => $port,
                                    Proto => 'tcp',
                                   );
   die "Could not create socket: $!\n" unless $sock;
   print $sock "status " . &xymonhost($host) . "." . $test . " " . $color . " " . $date . " " . $subject . "\n" . $string ;
   close($sock);
}

sub xymonhost {
my($host) = @_ ;
   $host =~ s/\./,/g ;
   return $host ;
}
Fra: Deiss, Mark [user-aa18037b3fdc@xymon.invalid]
Sendt: 9. august 2012 15:54
Til: Bjørge Øyvind (Operations); xymon at xymon.com
Emne: RE: Perl client without xymon client. (OPEN)

You could investigate using Big Sister as a client. It's been a few years since I used it. It ~was Perl based and ~was compatible with Big Brother/port 1984 transmission/BB messaging format at the time.

I think it is safe to mention it now; in the past, Mr. Croteau and Mr. MacGuire would throw thunderbolts from Mount BB.

-----Original Message-----
From: xymon-bounces at xymon.com [mailto:xymon-bounces at xymon.com] On Behalf Of user-9b0f7b358aa3@xymon.invalid
Sent: Thursday, August 09, 2012 9:17 AM
To: xymon at xymon.com
Subject: [Xymon] Perl client without xymon client. (OPEN)

Is there anyone that have made a perl module or subroutine for sending to a xymon-server without having to install the xymon client?
On some node it is difficult to install a client. Some vendors are very afraid of having things installed on "their" equipment, and the os might be stripped down with no compilers and so on.
For sending to xymon I guess all you need is a simple socket connections so I expect that this has been done many times already.
Anyone who would like to share?

/ Øyvind