DX NetOps

  • 1.  Delete attributes/model types created with MibTools mib import

    Posted Nov 19, 2012 07:55 AM
    Hi
    When mibs are imported using Mib Tools they create new model types and attributes based on the mib imported. This has happened a number of times on our production systems (unapproved I know) and has resulted in a number of model types and attributes with handles starting 0xfff. There are now approx 150 of these attributes, which are then created for all devices, based off GnSNMPDev, modelled in the infrastructure. We would like to remove these attributes and would like to know the best way to do this.

    Using the catalog from an old database may be an option but it might be problematic finding a 'clean' catalog ... we would need to go back quite a way and there will likely have been many changes since then that we will want to keep.

    I was hoping we could use MTE to do this but it seems you can only delete model types or attributes that were created with your registered developer ID. Does anyone know is it possible to use MTE to do this?

    Or is there some other way?

    John


  • 2.  RE: Delete attributes/model types created with MibTools mib import

    Posted Nov 25, 2012 05:36 PM
    Hi John,

    Attributes shouldn't be automatically created when importing a new MIB and I think the attributes you see were created "manually" by somebody.
    After importing the MIB, some user decided that some new attributes might be needed. He/she selected some from the list and proceeded to map these attributes. Once that was done, new attributes were created under CA's developer ID.

    As you discovered, you can only delete attributes created under your developer ID - if you don't have one, it will be the default developer ID used - so there is absolutely no hope in deleting those using MTE.
    I am not sure about using CLI (never tried it) but I suspect it won't work. You can give it a try because there is nothing to lose.

    Your issue does raise a legitimate question - why these attributes are created with CA developer ID and not with default or user developer ID? If they were, there would have been no dramas because you could do anything afterwards with these attributes.
    I am not sure if somebody have a developer ID these attributes are not created under that one instead of CA ...

    I would really appreciate some CA insight into this matter, please.

    To answer your question John, I'm afraid if you really want these attributes gone, you really need to load an old catalog. You can go back quite a while to find one; if no new models/attributes were created recently then you won't lose anything.

    I'm not aware of any way to get some info about attributes creation date ... maybe somebody skilled enough can get that info from database - I'm very far from "skilled.


  • 3.  RE: Delete attributes/model types created with MibTools mib import

    Posted Nov 27, 2012 11:58 AM
    The only way would be to load an older DB with SSdbload -c <savefile.SSdb>


  • 4.  RE: Delete attributes/model types created with MibTools mib import
    Best Answer

    Posted Nov 30, 2012 05:36 AM

    Christian_Schneider wrote:

    The only way would be to load an older DB with SSdbload -c <savefile.SSdb>
    I persevered with support and they eventually relented and provided a way to do this without reverting to an older db :-)


    How to remove model types for mibs imported using MibTools.

    We have an undocumented and unsupported method of removing imported mibs from the SSdb catalog. We recommend that you first save your SSdb catalog and try to perform these steps first on a test server.

    When a mib is imported and added to the SSdb catalog through mibtools a new model is created under SNMP_MIBS that can be seen from Model Type Editor (MTE). So with the SpectroSERVER stopped and MTE running you can filter by SNMP_ and you'll see that under SNMP_MIBS folder you can see all imported mibs that are added to the catalog. Each time a mib is imported it could be seen as a child under SNMP_MIBS and mapped attributes will be created under this new model. For the mibs that are added and that you would like to remove please make a note of the Model_Type ID.
    These model type ids that should be removed are then added to a text file and separated by blank spaces, once this has been complete you can remove these model types with the following command run in the $SPECROOT/SS directory

    $SPECROOT/SS-Tools/db_remove <file name>
    Where the file name is the name of the file of the model list you would like to remove.


    NOTE 1 I found that adding model type ids separated by a space didn't work and only removed the first entry. Putting the model type ids on separate lines worked instead.
    NOTE 2 You could also find the model type ids using CLI if you don't have MTE. Use the command "show inheritance mth=0x10464" - 0x10464 is the mth for SNMP_MIB. All derived model types with handles starting 0xfff are what you need.
    NOTE 3 I did ask what they meant by unsupported. The reply was "Unsupported means that it hasn't been tested by QA and as such we do have not have official procedure on this"
    .