Ошибка snmp 1500

  • Remove From My Forums
  • Question


  • Should i delete the registry key? or what else should be done about this?

    • Edited by

      Tuesday, March 13, 2012 3:01 AM

    • Moved by
      Doug Neal
      Tuesday, March 13, 2012 5:43 AM
      Not MBSA related (From:MBSA — Microsoft Baseline Security Analyzer)

Answers

  • Hi,

    This Error is logged because the SNMP Service checks if the registry path mentioned in the Event Description is present and determines that it is not. This registry path is needed for the SNMP trap configuration and created once traps are set up.

    This has been determined not to have any influence to the operation of SNMP or the system and should be ignored. The occurance of the Event can be avoided by creating the registry path in question before installing the SNMP Feature.

    Please refer:
    http://support.microsoft.com/kb/2002303


    William Tan

    TechNet Community Support

    • Marked as answer by
      Arthur Xie
      Wednesday, March 28, 2012 9:20 AM

On my 64-bit Linux server, I am trying to install Net-SNMP 5.7.3. However, I am facing a challenge while handling getBulkRequest for an OID that has MIBs beneath it. My Linux server returns an error code and I am unable to figure out the cause of this error. Even though I can fetch the information for each MIB by using snmpget, I keep encountering the same error when I try to perform snmpbulkget.

Error in packet.
Reason: (genError) A general failure occured
Failed object: MY-ELEMENT-MIB::myModel.0

I suspect that the issue is with my Agent’s
SNMP configuration
file, but despite my efforts, I haven’t been able to fix it. Just to be sure, I am sharing all the steps I have taken so far. I hope that the simplified version of my code will be helpful for others and save them the trouble that I had to go through to reach this point.

To launch my Agent, I placed my snmp.conf in the /etc/snmp/ directory. I have configured it to utilize v2c and have made it accessible to the general public.

###############################################################################
#
# EXAMPLE.conf:
#   An example configuration file for configuring the Net-SNMP agent ('snmpd')
#   See the 'snmpd.conf(5)' man page for details
#
#  Some entries are deliberately commented out, and will need to be explicitly activated
#
###############################################################################
#
#  AGENT BEHAVIOUR
#
#  Listen for connections from the local system only
#agentAddress  udp:127.0.0.1:161
#  Listen for connections on all interfaces (both IPv4 *and* IPv6)
agentAddress udp:161,udp6:[::1]:161
###############################################################################
#
#  ACCESS CONTROL
#
####
# First, map the community name (COMMUNITY) into a security name
# (local and mynetwork, depending on where the request is coming
# from):
#       sec.name  source          community
com2sec local     localhost       secret42
com2sec cust1_sec default         public
####
# Second, map the security names into group names:
#               sec.model  sec.name
group MyRWGroup v1         local
group MyRWGroup v2c        local
group cust1_grp v1         cust1_sec
group cust1_grp v2c        cust1_sec
####
# Third, create a view for us to let the groups have rights to:
#           incl/excl subtree                              mask
view all    included  .1
#view cust1_v excluded  .1
#view cust1_v included  sysUpTime.0
#view cust1_v included  interfaces.ifTable.ifEntry.ifIndex.1 ff.a0
####
# Finally, grant the groups access to their views:
#                context sec.model sec.level match  read     write  notif
access MyRWGroup ""      any       noauth    exact  all      all    none
access cust1_grp ""      any       noauth    exact  all      all    none
#  Full read-only access for SNMPv3
#rouser   authOnlyUser
#  Full write access for encrypted requests
#     Remember to activate the 'createUser' lines above
#rwuser   authPrivUser   priv
###############################################################################
#
#  SYSTEM INFORMATION
#
#  Note that setting these values here, results in the corresponding MIB objects being 'read-only'
#  See snmpd.conf(5) for more details
sysLocation    Server Room
sysContact     Me 
# Application + End-to-End layers
sysServices    72
###############################################################################
#
#  ACTIVE MONITORING
#
#   send SNMPv1  traps
#trapsink     localhost:162 public
#   send SNMPv2c traps
#trap2sink    localhost public
#   send SNMPv2c INFORMs
#informsink   localhost public
#  Note that you typically only want *one* of these three lines
#  Uncommenting two (or all three) will result in multiple copies of each notification.
#
#  Event MIB - automatically generate alerts
#
# Remember to activate the 'createUser' lines above
#iquerySecName   internalUser       
#rouser          internalUser
# generate traps on UCD error conditions
#defaultMonitors          yes
# generate traps on linkUp/Down
#linkUpDownNotifications  yes
###############################################################################
#
#  EXTENDING THE AGENT
#
#
#  AgentX Sub-agents
#
#  Run as an AgentX master agent
master          agentx
#  Listen for network connections (from localhost)
#    rather than the default named socket /var/agentx/master
#agentXSocket    tcp:localhost:705

Upon initiating snmpd, the Agent, I proceed to launch a sub-Agent Daemon through my C++ program. The following example for the Daemon was utilized: http://www.net-snmp.org/tutorial/tutorial-5/toolkit/demon/example-demon.c

I have implemented the sub-Agent code in C++ which is called by the daemon’s init_myMibSubAgent() method instead of init_nstAgentSubagentObject().

#include 
#include 
#include 
#include "myMibSubAgent.h"
#include "SNMPAppData.h"
#include 
using namespace std;
void CMyMibSubAgent::init_myMibSubAgent(void)
{
    static oid myGeneral_oid[] = { 1, 3, 6, 1, 4, 1, 1234, 2, 1, 2};
    // myModel; DisplayString
    static oid myModel_oid[] = { 1, 3, 6, 1, 4, 1, 1234, 2, 1, 2, 1}; // We dont add 0 to end of watch scalar registration oid
    netsnmp_register_watched_scalar(
        netsnmp_create_handler_registration("myModel", NULL,
            myModel_oid, OID_LENGTH(myModel_oid),
            HANDLER_CAN_RWRITE),
        netsnmp_create_watcher_info(&gSNMPAppData.myGeneral.data.myModel, sizeof(gSNMPAppData.myGeneral.data.myModel),
            ASN_OCTET_STR, WATCHER_SIZE_STRLEN));
            
    // mySerialCode; DisplayString
    static oid mySerialCode_oid[] = { 1, 3, 6, 1, 4, 1, 1234, 2, 1, 2, 2}; // We dont add 0 to end of watch scalar registration oid
    netsnmp_register_watched_scalar(
        netsnmp_create_handler_registration("mySerialCode", NULL,
            mySerialCode_oid, OID_LENGTH(mySerialCode_oid),
            HANDLER_CAN_RWRITE),
        netsnmp_create_watcher_info(&gSNMPAppData.myGeneral.data.mySerialCode, sizeof(gSNMPAppData.myGeneral.data.mySerialCode),
            ASN_OCTET_STR, WATCHER_SIZE_STRLEN));
    
    // myType; INTEGER
    static oid myType_oid[] = { 1, 3, 6, 1, 4, 1, 1234, 2, 1, 2, 3, 0};
    netsnmp_register_int_instance("myType", myType_oid, OID_LENGTH(myType_oid), &gSNMPAppData.myGeneral.data.myType, NULL );
    
    // mySoftwareRev; DisplayString
    static oid mySoftwareRev_oid[] = { 1, 3, 6, 1, 4, 1, 1234, 2, 1, 2, 4}; // We dont add 0 to end of watch scalar registration oid
    netsnmp_register_watched_scalar(
        netsnmp_create_handler_registration("mySoftwareRev", NULL,
            mySoftwareRev_oid, OID_LENGTH(mySoftwareRev_oid),
            HANDLER_CAN_RWRITE),
        netsnmp_create_watcher_info(&gSNMPAppData.myGeneral.data.mySoftwareRev, sizeof(gSNMPAppData.myGeneral.data.mySoftwareRev),
            ASN_OCTET_STR, WATCHER_SIZE_STRLEN));
            
    // myState; INTEGER
    static oid myState_oid[] = { 1, 3, 6, 1, 4, 1, 1234, 2, 1, 2, 5, 0};
    netsnmp_register_int_instance("myState", myState_oid, OID_LENGTH(myState_oid), &gSNMPAppData.myGeneral.data.myState, NULL );
    
    // mySeverityLevel; INTEGER
    //static oid mySeverityLevel_oid[] = { 1, 3, 6, 1, 4, 1, 1234, 2, 1, 2, 6, 0};
    //netsnmp_register_int_instance("mySeverityLevel", mySeverityLevel_oid, OID_LENGTH(mySeverityLevel_oid), &gSNMPAppData.myGeneral.data.mySeverityLevel, NULL );
    
    // myAssetTag; DisplayString
    static oid myAssetTag_oid[] = { 1, 3, 6, 1, 4, 1, 1234, 2, 1, 2, 7}; // We dont add 0 to end of watch scalar registration oid
    netsnmp_register_watched_scalar(
        netsnmp_create_handler_registration("myAssetTag", NULL,
            myAssetTag_oid, OID_LENGTH(myAssetTag_oid),
            HANDLER_CAN_RWRITE),
        netsnmp_create_watcher_info(&gSNMPAppData.myGeneral.data.myAssetTag, sizeof(gSNMPAppData.myGeneral.data.myAssetTag),
            ASN_OCTET_STR, WATCHER_SIZE_STRLEN));
            
    // myTtMaxTargets; Integer32
    static oid myTtMaxTargets_oid[] = { 1, 3, 6, 1, 4, 1, 1234, 2, 1, 3, 1, 0};
    netsnmp_register_int_instance("myTtMaxTargets", myTtMaxTargets_oid, OID_LENGTH(myTtMaxTargets_oid), &gSNMPAppData.myTrapTargets.data.myTtMaxTargets, NULL );
    
    // myTtCfgTableNextIndex; Integer32
    static oid myTtCfgTableNextIndex_oid[] = { 1, 3, 6, 1, 4, 1, 1234, 2, 1, 3, 2, 0};
    netsnmp_register_int_instance("myTtCfgTableNextIndex", myTtCfgTableNextIndex_oid, OID_LENGTH(myTtCfgTableNextIndex_oid), &gSNMPAppData.myTrapTargets.data.myTtCfgTableNextIndex, NULL );
    
    // myTtCfgTable
    for (int i=0; i < vsmNcIpCfgEntry_MAXROWS; i++)
    {
        // myTtCfgIndex; Integer32
        //static oid myTtCfgIndex_oid[] = { 1, 3, 6, 1, 4, 1, 1234, 2, 1, 3, 3, 1, 1, i+1};
        //string myTtCfgIndexStr = "myTtCfgIndex."+i;
        //netsnmp_register_int_instance(myTtCfgIndexStr.c_str(), myTtCfgIndex_oid, OID_LENGTH(myTtCfgIndex_oid), &gSNMPAppData.vsmNcIpCfgEntry.data[i].myTtCfgIndex, NULL );
        
        // myTtCfgIpAddress; IpAddress
        oid myTtCfgIpAddress_oid[] = { 1, 3, 6, 1, 4, 1, 1234, 2, 1, 3, 3, 1, 2, i+1};
        string myTtCfgIpAddressStr = "myTtCfgIpAddress." + std::to_string(i);
        netsnmp_register_handler(
            netsnmp_create_handler_registration(myTtCfgIpAddressStr.c_str(), handle_myTtCfgIpAddress,
                myTtCfgIpAddress_oid, OID_LENGTH(myTtCfgIpAddress_oid), HANDLER_CAN_RWRITE));
            
        // myTtCfgCommunity; OCTET STRING
        oid myTtCfgCommunity_oid[] = { 1, 3, 6, 1, 4, 1, 1234, 2, 1, 3, 3, 1, 3, i+1};
        string myTtCfgCommunityStr = "myTtCfgCommunity." + std::to_string(i);
        netsnmp_register_watched_instance(
            netsnmp_create_handler_registration(myTtCfgCommunityStr.c_str(), NULL,
                myTtCfgCommunity_oid, OID_LENGTH(myTtCfgCommunity_oid),
                HANDLER_CAN_RWRITE),
            netsnmp_create_watcher_info(&gSNMPAppData.myTtCfgEntry.data[i].myTtCfgCommunity, sizeof(gSNMPAppData.myTtCfgEntry.data[i].myTtCfgCommunity),
                ASN_OCTET_STR, WATCHER_SIZE_STRLEN));
        
        // myTtCfgEntryStatus; RowStatus
        oid myTtCfgEntryStatus_oid[]    = { 1, 3, 6, 1, 4, 1, 1234, 2, 1, 3, 3, 1, 4, i+1};
        string myTtCfgEntryStatusStr = "myTtCfgEntryStatus." + std::to_string(i);
        netsnmp_register_int_instance(myTtCfgEntryStatusStr.c_str(), myTtCfgEntryStatus_oid, OID_LENGTH(myTtCfgEntryStatus_oid), &gSNMPAppData.myTtCfgEntry.data[i].myTtCfgEntryStatus, NULL );
    }
}
int CMyMibSubAgent::handle_myTtCfgIpAddress(netsnmp_mib_handler             *handler,
                                                     netsnmp_handler_registration   *reginfo,
                                                     netsnmp_agent_request_info     *reqinfo,
                                                     netsnmp_request_info           *requests)
{
    switch(reqinfo->mode) 
    {
        case MODE_GET:
        {
            snmp_set_var_typed_value(requests->requestvb, ASN_IPADDRESS,
                (u_char *)&gSNMPAppData.vsmNcIpCfgEntry.data[1].vsmIpAddress,
                sizeof(gSNMPAppData.vsmNcIpCfgEntry.data[1].vsmIpAddress));
        }
            break;
        case MODE_SET_RESERVE1:
            break;
        case MODE_SET_RESERVE2:
            break;
        case MODE_SET_FREE:
            break;
        case MODE_SET_ACTION:
            break;
        case MODE_SET_COMMIT:
            break;
        case MODE_SET_UNDO:
            break;
        default:
            return SNMP_ERR_GENERR;
    }
    return SNMP_ERR_NOERROR;
}

At last, I have included the MIB module that utilizes both snmpbulkget and snmpget in the Manager’s /usr/share/snmp/mibs/ directory.

--
-- Common Object Definitions for My Element MIB
--
MY-ELEMENT-MIB DEFINITIONS ::= BEGIN
    --  Relationship to Other MIBs
    --
    --
    --  The objects defined in this MIB are located under the
    --  private.enterprises subtree as shown below:
    --
    --               iso(1).org(3).dod(6).internet(1)
    --                            |
    --                         private(4)
    --                            |
    --                       enterprises(1)
    --                            |
    --                        myOID(1234)
    --                            |
    --                   myRegistrations(2)
    --                            |
    --                     myElementMIB(1)
    --                                 
    --
    --
    --  Object Synopsis
    --  
    --
    --  All objects within this MIB are prefixed with the OBJECT
    --  IDENTIFIER "p", where "p" is:
    --
    --  iso(1).org(3).dod(6).internet(1).private(4).enterprises(1).
    --          myOID(1234).myRegistrations(2).myElementMIB(1)
    --  
    --  or, 1.3.6.1.4.1.1234.2.1
    --
    --
    --  Object Name                               Object Id         
    --  ================================          ==============
    --
    --  myMIBNotifications                      p.0
    --    myStateChange                         p.0.1
    --  myGeneral                               p.2
    --    myModel                               p.2.1.0
    --    mySerialCode                          p.2.2.0
    --    myType                                p.2.3.0
    --    mySoftwareRev                         p.2.4.0
    --    myState                               p.2.5.0
    --    mySeverityLevel                       p.2.6.0
    --    myAssetTag                            p.2.7.0
    --  myTrapTargets                           p.3
    --    myTtMaxTargets                          p.3.1.0
    --    myTtCfgTableNextIndex                   p.3.2.0
    --    myTtCfgTable                            ****
    --      myTtCfgEntry                          ****.1
    --        myTtCfgIndex                        ****.1.1.n
    --        myTtCfgIpAddress                    ****.1.2.n
    --        myTtCfgCommunity                    ****.****
    --        myTtCfgEntryStatus                  ****.1.4.n
    --
    
    IMPORTS
        MODULE-IDENTITY, NOTIFICATION-TYPE, OBJECT-TYPE,
        IpAddress, TimeTicks, Integer32
            FROM SNMPv2-SMI
        TEXTUAL-CONVENTION,
        DisplayString, RowStatus
            FROM SNMPv2-TC
        myRegistrations
            FROM MY-REG;
    myElementMIB MODULE-IDENTITY
        LAST-UPDATED "200503230000Z"
        ORGANIZATION "My Solutions, Inc."
        CONTACT-INFO
            "   
                My Solutions, Inc.
                123 Smith Ave
                Los Angeles, CA 12345, 
                USA.
                phone: +1 (123) 123-4567
                e-mail: me@example.org
                http://www.website.com/support" 
    DESCRIPTION
        "This MIB module describes the generic 
        characteristics of a manageable physical
        element beneath the my enterprise."
    REVISION      "9911120000Z"
    DESCRIPTION
        "First draft."
    REVISION      "200004100000Z"
    ::= { myRegistrations 1 }
    --
    -- Element MIB Textual Conventions
    --
    MyFloatingPoint ::= TEXTUAL-CONVENTION
        DISPLAY-HINT
            "63a"
        STATUS current
        DESCRIPTION
            "FloatingPoint provides a way of representing 
            non-integer numbers in SNMP. Numbers are 
            represented as a string of ASCII characters in
            the natural way. So for example, '3', '3.142' 
            and '0.3142E1' are all valid numbers. 
            
            The syntax for the string is as follows. [] 
            enclose an optional element, | is the separator 
            for a set of alternatives. () enclose syntax 
            which is to be viewed as a unit.
            FloatingPoint ::= [Sign]
                              (Float1 | Float2 | DigitSequence)
                              [ExponentPart]
            Float1 ::= DigitSequence '.' [DigitSequence]
            Float2 ::= '.' DigitSequence
            DigitSequence ::= Digit [DigitSequence]
            ExponentPart ::= ('e' | 'E') [Sign] DigitSequence
            Digit ::= '0'..'9'
            Sign ::= '+' | '-'"
        SYNTAX OCTET STRING (SIZE (1..63))
    MyTimecode ::= TEXTUAL-CONVENTION
        DISPLAY-HINT
            "11a"
        STATUS current
        DESCRIPTION
            "A display representation for timecode which
            essentially provides a machine readable address 
            for video and audio. Timecodes are represented as 
            a string of ASCII characters as hh:mm:ss:ff where
            hh is hours, mm is minutes, ss is seconds and
            ff is video frames."
        SYNTAX OCTET STRING (SIZE (0..11))
    --
    --  The Element MIB top-level groups
    --
    -- NOTE: { myElementMIB 1 } is reserved for internal use
    myGeneral        OBJECT IDENTIFIER ::= { myElementMIB 2 }
    myTrapTargets    OBJECT IDENTIFIER ::= { myElementMIB 3 }
    --
    --  The Element MIB Object Definitions
    --
    --
    -- The General Group
    -- The myGeneral group provides general
    -- information for the my managed element.
    --
    myModel OBJECT-TYPE
        SYNTAX      DisplayString (SIZE(0..64))
        MAX-ACCESS  read-only
        STATUS      current
        DESCRIPTION
            "The element model string. The preferred value is
            the customer-visible part number, which may be 
            printed on the physical managed element itself.
            
            If the element being managed does not have 
            a model descriptor, or the model descriptor is
            unknown to the agent, the value of this variable 
            will be a null string."
    ::= { myGeneral 1 }
    mySerialCode OBJECT-TYPE
        SYNTAX      DisplayString (SIZE(0..64))
        MAX-ACCESS  read-only
        STATUS      current
        DESCRIPTION
            "The manufacturing serial code of the
            element on which the management software
            is running.  The preferred value is the serial 
            number string actually printed on the CCU itself
            (if present).
            
            If the element being managed does not have 
            a serial code, the value of this variable 
            will be a null string."
    ::= { myGeneral 2 }
    myType OBJECT-TYPE
        SYNTAX      INTEGER {
                        myTypeUnknown(1),
                        -- My Type
                        myType1(2),
                            
                        -- My Type
                        myType2(3),
                        
                        -- My Type
                        myType3(4)
                    }
        MAX-ACCESS  read-only
        STATUS      current
        DESCRIPTION
            "Identifies the type of the element being managed."
    ::= { myGeneral 3 }
    mySoftwareRev OBJECT-TYPE
        SYNTAX      DisplayString (SIZE(0..64))
        MAX-ACCESS  read-only
        STATUS      current
        DESCRIPTION
            "The revision stamp of the software running on 
            the element that supports this MIB module."
    ::= { myGeneral 4 }
    myState OBJECT-TYPE
        SYNTAX      INTEGER {
                        myElementRunning(1),
                        myElementInMaintenance(2),
                        myElementFaulty(3),
                        myElementDisabled(4),
                        myElementIdling(5),
                        myElementInitializing(6),
                        myElementResetting(7),
                        myElementHalted(8),
                        myElementSwLicenseExpired(9),
                        myElementImntSwLicExpiry(10),
                        myElementSwLicRecovered(11)
                    }
        MAX-ACCESS  read-only
        STATUS      current
        DESCRIPTION
            "The operational state of an element."
    ::= { myGeneral 5 }
    
    mySeverityLevel OBJECT-TYPE
        SYNTAX      INTEGER {
                        levelUnknown(1),
                        levelTrace(2),
                        levelInformational(3),
                        levelNormal(4),
                        levelWarning(5),
                        levelAlarm(6),
                        levelResentWarning(7),
                        levelResentAlarm(8)
                    }
        MAX-ACCESS  accessible-for-notify
        STATUS      current
        DESCRIPTION
            "Defines the typical severity levels"
    ::= { myGeneral 6 }
    myAssetTag OBJECT-TYPE
        SYNTAX      DisplayString (SIZE(0..64))
        MAX-ACCESS  read-only
        STATUS      current
        DESCRIPTION
            "This object is a user-assigned asset tracking identifier for 
            the element"
    ::= { myGeneral 7 }
    --
    -- The Trap Targets Group
    -- The myTrapTargets group provides means to
    -- configure the trap target specifics using which an 
    -- element can dispatch traps.
    --
    myTtMaxTargets OBJECT-TYPE
        SYNTAX      Integer32
        MAX-ACCESS  read-only
        STATUS      current
        DESCRIPTION
            "The maximum number of trap targets that this
            element can support. 
            
            If the value of this variable is -1, the element
            element is capable of supporting a theoretically
            infinite number of trap targets dynamically. In
            othercases, the maximum number of trap targets 
            that can be supported by this element is limited
            to the value of this variable."
    ::= { myTrapTargets 1 }
    myTtCfgTableNextIndex OBJECT-TYPE
        SYNTAX      Integer32
        MAX-ACCESS  read-only
        STATUS      current
        DESCRIPTION
            "Identifies a hint for the next value of  
            myTtCfgIndex to be used in a row creation attempt
            for the myTtCfgTable table. If no new rows can be
            created, this object will have a value of 0."
    ::= { myTrapTargets 2 }
    myTtCfgTable OBJECT-TYPE
        SYNTAX  SEQUENCE OF MyTtCfgEntry
        MAX-ACCESS  not-accessible
        STATUS  current
        DESCRIPTION
            "A list of trap target configuration entries on
            this element.
            Trap Target Configuration Entry Creation:
            =========================================
            When creating a trap target configuration entry
            the manager should use a GET operation to 
            determine the value of myTtCfgTableNextIndex.0.
            If this value is non-zero, the manager can then 
            use this value as the index while creating a 
            table row.
            
            The process of creating and activating a row of 
            this table takes two forms: the one-set mode and 
            the multiple-set mode.
            
            In the one-set mode, a manager must specify the
            values of myTtCfgIpAddress and myTtCfgCommunity
            required to activate a row in a single SET operation
            along with an assignment of the myTtCfgEntryStatus
            to 'createAndGo(4)'. If the values and instances
            supplied are correct, an instance of the trap target
            configuration is created and the value of 
            myTtCfgEntryStatus transitions to 'active(1)'.
            for example:
            ============
            SnmpGet()
                returns
                    
            SnmpSet(,
                    ,
                    )
                returns 
                    ,
                    ,
                    
                
            In the multiple-set mode, creating a trap target
            configuration table row, filling it with values,
            and activating it are carried out in discrete steps.
            To create the row, the manager specifies a value
            of 'createAndWait(5)' for the myTtCfgEntryStatus
            status variable. This SET request could contain
            values of myTtCfgIpAddress and myTtCfgCommunity
            but it is not required. More often, the values for 
            these columnar objects are specified in additional
            SET requests. After each SET operation, the 
            myTtCfgEntryStatus variable takes on the value 
            'notReady(3)' or 'notInService(2)'. To place the
            entry into service, the manager requests that the
            myTtCfgEntryStatus variable transition to the
            'active(1)' state.
            for example:
            ============
            SnmpGet(, NULL)
                returns
                    
            SnmpSet()
                returns
                    
            SnmpSet(,
                    )
                returns
                    ,
                    
            SnmpSet()
                returns
                    
            Trap Target Configuration Entry Deletion:
            =========================================
            To delete an existing trap target configuration
            entry, the manager performs a SET operation on the
            myTtCfgEntryStatus variable with the value
            'destroy(6)'."
        ::= { myTrapTargets 3 }
    myTtCfgEntry OBJECT-TYPE
        SYNTAX  MyTtCfgEntry
        MAX-ACCESS  not-accessible
        STATUS current  
        DESCRIPTION
            "A trap target configuration entry."
        INDEX   { myTtCfgIndex }
        ::= { myTtCfgTable 1 }
    MyTtCfgEntry ::=
        SEQUENCE {
            myTtCfgIndex
                Integer32,
            myTtCfgIpAddress
                IpAddress,
            myTtCfgCommunity
                OCTET STRING,
            myTtCfgEntryStatus
                RowStatus
        }
    myTtCfgIndex OBJECT-TYPE
        SYNTAX  Integer32 (1..2147483647)
        MAX-ACCESS  not-accessible
        STATUS  current
        DESCRIPTION
            "The index of a trap target configuration row.
            
            Note that the value of this object will not
            be visible to a manager and any GET/SET 
            operations on this variable will fail."
        ::= { myTtCfgEntry 1 }
    myTtCfgIpAddress OBJECT-TYPE
        SYNTAX  IpAddress
        MAX-ACCESS  read-only
        STATUS  current
        DESCRIPTION
            "The IP address of the target/manager to which
            this element is supposed to send notifications."
        ::= { myTtCfgEntry 2 }
    myTtCfgCommunity OBJECT-TYPE
        SYNTAX  OCTET STRING (SIZE(0..128))
        MAX-ACCESS  read-only
        STATUS  current
        DESCRIPTION
            "The community name to be used when this element
            sends notifications to the target identified by 
            this value of this entries myTtCfgIpAddress."
        ::= { myTtCfgEntry 3 }
    myTtCfgEntryStatus OBJECT-TYPE
        SYNTAX  RowStatus
        MAX-ACCESS  read-only
        STATUS  current
        DESCRIPTION
            "This object controls the creation, activation
            and deletion of a row in trap target configuration
            table."
        ::= { myTtCfgEntry 4 }
    --
    --  The Element MIB Notifications
    --
    --
    --  The notifications group is being assigned the OID "0" so as
    --  to comply with the trap handling in the different SNMP versions
    --
    myMIBNotifications OBJECT IDENTIFIER ::= { myElementMIB 0 }
    myStateChange NOTIFICATION-TYPE
        OBJECTS {
            myState
        }
        STATUS  current
        DESCRIPTION
            "Notifies when a state change occurs on an element.
            The myState variable will hold the new state that
            the element is operating in."
        ::= { myMIBNotifications 1 }
    
END

snmpget command I used on Manager

snmpget -v 2c -c public 10.16.20.191 MY-ELEMENT-MIB::myModel.0
MY-ELEMENT-MIB::myModel.0 = STRING: Hello World

The Manager was the target of my use of the snmpbulkget command.

snmpbulkget -v 2c -c public 10.16.20.191 MY-ELEMENT-MIB::myGeneral
Error in packet.
Reason: (genError) A general failure occured
Failed object: MY-ELEMENT-MIB::myModel.0

Additional Notes:

  • The results obtained are identical when using OID directly.
  • By analyzing with Wireshark, I observed that my Linux system provides a reply to the getBulkRequest containing the information of all the MIBs located under the OID.
  • By utilizing the -DALL switch in my snmpbulkget command, I was able to retrieve information on all the MIBs located under the OID. However, the presence of an Error Status = 5 indicates that I received a genError response.
  • Remove From My Forums
  • Question


  • Should i delete the registry key? or what else should be done about this?

    • Edited by

      Tuesday, March 13, 2012 3:01 AM

    • Moved by
      Doug Neal
      Tuesday, March 13, 2012 5:43 AM
      Not MBSA related (From:MBSA — Microsoft Baseline Security Analyzer)

Answers

  • Hi,

    This Error is logged because the SNMP Service checks if the registry path mentioned in the Event Description is present and determines that it is not. This registry path is needed for the SNMP trap configuration and created once traps are set up.

    This has been determined not to have any influence to the operation of SNMP or the system and should be ignored. The occurance of the Event can be avoided by creating the registry path in question before installing the SNMP Feature.

    Please refer:
    http://support.microsoft.com/kb/2002303


    William Tan

    TechNet Community Support

    • Marked as answer by
      Arthur Xie
      Wednesday, March 28, 2012 9:20 AM

Понравилась статья? Поделить с друзьями:
  • Ошибка u1000 nissan qashqai j11
  • Ошибка smtp шлюза или сертификата
  • Ошибка u1000 nissan primera p12
  • Ошибка u1000 nissan note
  • Ошибка sniper elite 4 directx 11