Server Management - Systems Insight Manager
cancel
Showing results for 
Search instead for 
Did you mean: 

Reversing Events in HP SIM Integration

Paul Brabban
Occasional Visitor

Reversing Events in HP SIM Integration

Hi,

I'm working on a simple one-way integration from HP SIM 4.2 to another event management system, using the Custom Command functionality in SIM. Everything is going fine except that I'd like to automatically reverse/clear events that are sent from SIM on the other system. My problem is that I need common information to identify the particular event to reverse, such as system name (which is passed as an environment variable) and an event type, but the event type text changes between the original alert and the clear event (System is unreachable/System is reachable, for example)

Alternatively, can HP SIM trigger a custom command when an event goes into a 'Cleared' state and if so how?

Can anyone offer any help as to what I could use as my keys?

Thanks

Paul

3 REPLIES
cherepenin
Frequent Advisor

Re: Reversing Events in HP SIM Integration

Hello,

 

May be you need HPSIMInt.jar file from old HP SIM to HP OVO integration with EventListener process:

 

C:\>"C:\Program Files\HP\Systems Insight Manager\j2re\bin\java.exe" -cp "c:\temp\HPSIMInt.jar;C:\Program Files\HP\Systems Insight Manager\lib\xercesImpl.jar;C:\Program Files\HP\Systems Insight Manager\lib\mxpartnerlib5_0_2.jar;C:\Program Files\HP\Systems Insight Manager\lib\commons-logging.jar;C:\Program Files\HP\Systems Insight Manager\lib\saaj.jar;C:\Program Files\HP\Systems Insight Manager\lib\jaxrpc.jar;C:\Program Files\HP\Systems Insight Manager\lib\axis.jar;C:\Program Files\HP\Systems Insight Manager\lib\commons-discovery.jar;C:\Program Files\HP\Systems Insight Manager\lib\dom4j-1.4.jar;C:\Program Files\HP\Systems Insight Manager\lib\sax2.jar;C:\Program Files\HP\Systems Insight Manager\lib\xerces.jar;C:\Program Files\HP\Systems Insight Manager\lib\mx.jar;C:\Program Files\HP\Systems Insight Manager\lib\cimclient.jar"  -Djavax.net.ssl.trustStore="c:\Program Files\HP\Systems InsightManager\config\certstor\hp.keystore"  ClearEvents 112895
mxpath file is C:\Program Files\HP\Systems Insight Manager\config\mx.properties
port number is 50001
Events were cleared successfully

stevenliutj
Advisor

Re: Reversing Events in HP SIM Integration

Hello,

 

There is a table notices in SIM Database, and you may refer NoticeType,Generated,Cleared columns.

 

NoticeType column for example    Notetype 18 vs hp.nodestatus.unreachable

                                                                               19 vs hp.nodestatus.reachable

Generated column is a reference number, only one to one event.

Cleared column, if one event is cleared, then the content of Cleared column is filled by cleared reference number.

 

Hope useful to you.

 

BR

 

Steven

cherepenin
Frequent Advisor

Re: Reversing Events in HP SIM Integration

Hello All.

 

Some updates for my pervious post.

 

For using HPSIMInt.jar it is needed:

 

1. Credentials File (hpsimcms.conf):

 

C:\temp>echo doamin\username > hpsimcms.conf
C:\temp>simconfig pass PASSWORD >> hpsimcms.conf

 

where:

simconfig - utility from old HPSIM to HPOVO integration

 

2. simconfig, HPSIMInt.jar, HPSIMInt.conf, hpsimcms.conf should be in same directory and also, this dir should be 'current work dir' in script:

 

C:\Windows\System32> dir c:\temp\HPSIMInt\


 22.03.2012  12:06             1 000 ClearEvents.cmd
15.09.2010  13:00                23 hpsimcms.conf
22.03.2012  11:45                58 HPSIMInt.conf
01.12.2011  10:50            24 965 HPSIMInt.jar
01.12.2011  10:50            20 543 simconfig.exe

3. Script content (ClearEvents.cmd):

 

@ECHO OFF
cd c:\temp\HPSIMInt\
"C:\Program Files\HP\Systems Insight Manager\j2re\bin\java.exe"  -classpath "c:\temp\HPSIMInt\HPSIMInt.jar;C:\Program Files\HP\Systems Insight Manager\lib\xercesImpl.jar;C:\Program Files\HP\Systems Insight Manager\lib\mxpartnerlib5_0_2.jar;C:\Program Files\HP\Systems Insight Manager\lib\commons-logging.jar;C:\Program Files\HP\Systems Insight Manager\lib\saaj.jar;C:\Program Files\HP\Systems Insight Manager\lib\jaxrpc.jar;C:\Program Files\HP\Systems Insight Manager\lib\axis.jar;C:\Program Files\HP\Systems Insight Manager\lib\commons-discovery.jar;C:\Program Files\HP\Systems Insight Manager\lib\dom4j-1.4.jar;C:\Program Files\HP\Systems Insight Manager\lib\sax2.jar;C:\Program Files\HP\Systems Insight Manager\lib\xerces.jar;C:\Program Files\HP\Systems Insight Manager\lib\mx.jar;C:\Program Files\HP\Systems Insight Manager\lib\cimclient.jar"  -Djavax.net.ssl.trustStore="c:\Program Files\HP\Systems Insight Manager\config\certstor\hp.keystore" ClearEvents %1

 

4. Example of using this script:

 user@hostname:~$ ssh administrator@hp.sim.server  "c:/temp/HPSIMInt/ClearEvents.cmd 114104"

mxpath file is C:\Program Files\HP\Systems Insight Manager\config\mx.properties
port number is 50001
Events were cleared successfully