locked
Questions of Sample Code for Management Pack Development RRS feed

  • Question

  • I just try management pack development code using scom SDK in http://msdn.microsoft.com/en-us/library/hh329038.aspx. This is a very good place to learn the essence of scom.


    But this code is for scom 2007, I am trying scom 2012 sp1. I get stuck in the following code:

     m_mpStore = new ManagementPackFileStore();

                m_mpStore.AddDirectory(@"C:\Program Files\System Center 2012\Operations Manager\");

                Version version = new Version(1, 0);
                m_mp = new ManagementPack("BuildFromScratchManagementPack", "Build From Scratch Management Pack Friendly Name", version, m_mpStore);

                m_libraryMp = new ManagementPack(@"C:\Program Files\System Center Operations Manager 2007\System.Library.mp", m_mpStore);
                m_windowsLibraryMp = new ManagementPack(@"C:\Program Files\System Center Operations Manager 2007\Microsoft.SystemCenter.Library.mp", m_mpStore);
                m_healthLibraryMp = new ManagementPack(@"C:\Program Files\System Center Operations Manager 2007\System.Health.Library.mp", m_mpStore);

    I just can't find any management pack under scom 2012 install location, so I can't instantiate ManagementPackFileStore and the three management packs this example references.

    Can anybody help that let the example code in http://msdn.microsoft.com/en-us/library/hh329038.aspx work for scom 2012 sp1?

    Thanks in advance.


    Jackson


    Tuesday, July 2, 2013 11:24 AM

Answers

  • Well, I guess you will have to write around a few of these things and test. you can find a lot of packs on the scom 2012 sp1 install source. From there copy the packs you need and place them in a path you can reach or which works for you. possibly the server directory under the scom 2012 install folder. Depending on what else this code is doing (didnt check it all).


    Bob Cornelissen - BICTT (My Blog about SCOM) - MVP 2012 + 2013 and Microsoft Community Contributor 2011 + 2012 Recipient

    • Marked as answer by Cloud_TS Wednesday, July 10, 2013 9:40 AM
    Friday, July 5, 2013 10:08 AM
  • Hi 

    SCOM 2012 fully support SCOM 2007 MP xml schema, so you can develop mp using scom 2007 SDK and import in scom 2012.

    or

    you can import scom 2012 binary in vs and develop scom 2012 mp schema mp,there are only little changes in scom 2012 mp to scom 2007 MP.

    Regards   


    sridhar v

    Friday, July 5, 2013 11:00 AM

All replies

  • Well, I guess you will have to write around a few of these things and test. you can find a lot of packs on the scom 2012 sp1 install source. From there copy the packs you need and place them in a path you can reach or which works for you. possibly the server directory under the scom 2012 install folder. Depending on what else this code is doing (didnt check it all).


    Bob Cornelissen - BICTT (My Blog about SCOM) - MVP 2012 + 2013 and Microsoft Community Contributor 2011 + 2012 Recipient

    • Marked as answer by Cloud_TS Wednesday, July 10, 2013 9:40 AM
    Friday, July 5, 2013 10:08 AM
  • Hi 

    SCOM 2012 fully support SCOM 2007 MP xml schema, so you can develop mp using scom 2007 SDK and import in scom 2012.

    or

    you can import scom 2012 binary in vs and develop scom 2012 mp schema mp,there are only little changes in scom 2012 mp to scom 2007 MP.

    Regards   


    sridhar v

    Friday, July 5, 2013 11:00 AM