Monday, February 3, 2014

Event Integration From 3rd-party Monitoring Tools - Part 3: Msend API configuration

Before you install msend API package, on the server where your 3rd-party monitoring software runs, decide your installation directory <Install_Dir> and define the following environment variable:

$MCELL_HOME=<Install_Dir>/BMC/Server (for UNIX) or
%MCELL_HOME%=<Install_Dir>\BMC\Server (for Windows)

Then add $MCELL_HOME/bin or %MCELL_HOME%\bin to the environment variable PATH.

Now you can untar or unzip your msend API package under %MCELL_HOME% directory.  After all files are installed, open %MCELL_HOME%\etc\mcell.dir and verify all cells are defined correctly.  Then create a directory called "buffer" under %MCELL_HOME%.

For UNIX, verify that $MCELL_HOME/bin/msend has its execution bit turned on.  Run 'chmod +x msend' if needed. In addition, in order to run msend API in buffer mode, you need to create a file called /etc/itm/.reg and make /etc/itm/.reg writable to the account executing msend API.  You need root privilege to create /etc/itm/.reg.

Before calling msend API from your 3rd-party monitoring software, I highly recommend testing the communication by using the following simple test cases:

1. Send an event from command line: 
    msend -n <cell_name> -a EVENT -m "Test from command line"

2. Send an event from command line in buffer mode:
    msend -n <cell_name> -j <Install_Dir>\BMC\server\buffer -a EVENT -m "Test from command line with buffer"

3. Send an event from a text file:
    msend -n <cell_name> myevent1.txt
where myevent1.txt should contain these lines:
EVENT;
       severity=CRITICAL;
       msg="Test from text file";
END

4. Send an event from a text file in buffer mode:
    msend -n <cell_name> -j <Install_Dir>\BMC\server\buffer myevent2.txt
where myevent2.txt should contain these lines:
EVENT;
       severity=CRITICAL;
       msg="Test from text file with buffer";
END
   
In each of the above four cases, verify that an event is present in BPPM/BEM GUI and no error message is displayed from msend command. If you are running msend in buffer mode, also verify that 'msend' process is still running up to 10 minutes after you call msend command.

We will cover msend API execution in the next post.


1 comment:

  1. It's really helpfully discussed. To know more this: http://www.woodstone.nu/salive

    ReplyDelete