DX NetOps

 View Only

  • 1.  Query data type different in Spectrum

    Posted 16 days ago

    Hello Team,

    I have a question of DX Spectrum: is there a way to change the data type for two attributes-specifically "hwMemoryDevFree" and "hwMemoryDevSize"? I am having an issue with the data type returned by the MIB; it is a Counter64 type, but Spectrum is returning it as an Integer.

    image

    Greetings!



  • 2.  RE: Query data type different in Spectrum

    Posted 12 days ago

    Ah, I would have thought that they are the same thing. A counter is an integer - as in a number. In this case, the space allocated for it as an OID is 64 bits worth (which is important since you want adequate space to take into account rollover!).

    Concerning what you have shown, you are referencing two different mechanisms as to how things are defined. The top one is pulling things from the MIB itself, which, as you point out, has the concept of Strings, Octets, Counter32 and Counter64, etc.

    However, the bottom is specifying how attributes are stored in the actual Spectrum database (as opposed to the MIB) - in this case as an integer since we are dealing with numbers. The other types include Booleans and Date/Time. The mappings in Spectrum for this sort of thing do NOT tie into how things are defined in the MIB - except when dealing with the obvious - as in you aren't going to be mapping a String to an Integer!

    If you want to start looking into Attribute Types mapped into models then you can use the MTE for this sort of thing. However, I would express caution that if you don't know how to use the MTE then you can right royally screw up the models on the system. So, make sure you take a backup of the SSDb beforehand. Also, Spectrum needs to be fully down before you perform any MTE changes (NOT that I am suggesting you do this at all here).

    However, before you even consider doing any of this, I would ask as to why is this causing you issues? It seems that you are making a problem out of something that isn't a problem.




  • 3.  RE: Query data type different in Spectrum

    Posted 12 days ago

    OK, just looking into this - a counter is an integer! As in both are numbers. In the case of the counter, the MIB is specifying that it has a 64-bit address space (which is important for taking rollover into account).

    For the Spectrum attribute definitions, this is how it handles attributes - as in OIDs (though thy don't necessarily need to be OIDs) getting mapped into various different types - that may not necessarily reflect the actual types defined in the MIB. However, I should state that if you have a string then it won't be mapped as an integer - as in we aren't trying to shoe horn apples into oranges!

    If you want to have a look at the attribute types to adjust them (booleans, date/time, integers, etc.) then you can do this in the MTE for the model in question BUT I would caution you against this unless you really know what you are doing. Using the MTE is a case of - here there be dragons! You can right royally screw up your database - so make sure you have a backup AND do this on a test environment beforehand.

    Before you do any of this though, my question for yourself would be - why is this causing you a problem? It seems that you are making a problem out of something that isn't a problem.