How to delete a Node CI from the command line? (1115 Views)
Reply
Highlighted
Regular Advisor
Posts: 130
Registered: ‎12-12-2006
Message 1 of 7 (1,115 Views)

How to delete a Node CI from the command line?

[ Edited ]

Is it possible to delete a Node CI from the command line in uCMDB 9.05?  RTSM?

 

 

P.S. This thread has been moved from Application Perf Mgmt (BAC / BSM) Support and News Forum to CMS and Discovery Support and News Forum. - Hp Forum Moderator

Trusted Contributor
Posts: 174
Registered: ‎10-12-2010
Message 2 of 7 (1,037 Views)

Re: How to delete a Node CI from the command line?

There's at least two possibilities for you to look at: the Model Services MBean (JMX) and the UcmdbService webservice (Axis2).

 

There's a Jar you need to call JMX MBean operations from a batch file. The same for performing SOAP calls on the Axis2 webservices.

 

 

-----------------------------------------------------------------------------
o If you find that this or any post resolves your issue, please be sure to mark it as an accepted solution.
o Click the KUDOS star on the left to say 'Thanks'
Regular Advisor
Posts: 130
Registered: ‎12-12-2006
Message 3 of 7 (1,020 Views)

Re: How to delete a Node CI from the command line?

I'm struggling to find a good example in any documentation.  Is anyone trying to remove Node CI's programatically?  Is this even worth the effort?

 

It seems to me the easiest way to delete CI's is via Enrichment.  Thats fine.  But surely there is a way to do this programatically.

HP Expert
Posts: 222
Registered: ‎05-17-2012
Message 4 of 7 (1,011 Views)

Re: How to delete a Node CI from the command line?

Hi,

 

Take a look at the RTSM Developer Reference Guide.

 

The API's for writing your own code are described there.

 

 

Eric Shaffer

"HP Support
If you find that this or any post resolves your issue, please be sure to mark it as an accepted solution."
Trusted Contributor
Posts: 174
Registered: ‎10-12-2010
Message 5 of 7 (996 Views)

Re: How to delete a Node CI from the command line?

[ Edited ]

Have you given some thought to cmdline-jmxclient? You can use that to communicate with the JMX side of UCMDB (JMX console).

 

 

-----------------------------------------------------------------------------
o If you find that this or any post resolves your issue, please be sure to mark it as an accepted solution.
o Click the KUDOS star on the left to say 'Thanks'
Trusted Contributor
Posts: 174
Registered: ‎10-12-2010
Message 6 of 7 (978 Views)

Re: How to delete a Node CI from the command line?

[ Edited ]

Try this:

 

java -jar cmdline-jmxclient-0.10.3.jar - 1.1.1.1:29601 "UCMDB:service=Model Services" removeCMDBObject=1,f22c4b1e0a5e01271054aaf0990c2a57
02/13/2014 11:36:28 +0000 org.archive.jmx.Client removeCMDBObject=1,f22c4b1e0a5e01271054aaf0990c2a57: Object f22c4b1e0a5e01271054aaf0990c2a57 deleted

This will immediately and irrevocably remove a CI with Global ID "f22c4b1e0a5e01271054aaf0990c2a57" from the CMDB.

Tested it and it works.

 

-----------------------------------------------------------------------------
o If you find that this or any post resolves your issue, please be sure to mark it as an accepted solution.
o Click the KUDOS star on the left to say 'Thanks'
Regular Advisor
Posts: 141
Registered: ‎12-08-2011
Message 7 of 7 (128 Views)

Re: How to delete a Node CI from the command line?

Hi,

 

I was also looking for a solution to remove CI from command line.

 

Can you share details like how to run this command ? Can you provide some guidelines here ?

 

java -jar cmdline-jmxclient-0.10.3.jar - 1.1.1.1:29601 "UCMDB:service=Model Services" removeCMDBObject=1,f22c4b1e0a5e01271054aaf0990c2a57

The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the Terms of Use and Rules of Participation.