lazy industries

Tag: Powershell

OpsMgr: Uninstalling a Management Pack using Powershell

by Dan Kregor on May.02, 2008, under OpsMgr, Technology

I recently had the need to uninstall a ManagementPack from OpsMgr without using the Operators Console (kept getting a exception error every time I opened the console after importing the eXcSoftware Management Pack). Here’s how I did it:

    Here’s how I did it:

  • On the RMS, open Command Shell.
  • 080502-Blog Powershell1

     

  • You’ll need to know the name of the MP, so at the powershell prompt type Get-ManagementPack. If [like me] you have a large number of MP’s installed, you’ll probably want to pipe this into a text file, or expand the Screen Buffer Size to something like 3000, run the command and then [right click and select find to] search.
  • 080502-Blog Powershell

  • Once you have the name we can now uninstall the MP. Start by typing the following:

    $MP = Get-ManagementPack :where-opject {$_.Name -eq ‘eXcSoftware.nonWindows’

    We’ve now set the variable $MP to contain the values for the MP. Now type in:

    uninstall-managementpack -managementpack $mp

  • Sadly, there is no confirmation that the MP has been uninstalled. You’ll have to go into the console to confirm.

Thankfully [for me] this did fix my issue. I really must get around to setting up my test OpsMgr environment rather than working live with production.

1 Comment :, , more...

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!