Search code examples
snmp

What are the sysLocation and sysContact objects in snmpd.conf?


I am trying to configure SNMP on Ubuntu 14.04. There is a step where I have to edit the community string along with sysLocation and sysContact but I am not sure what goes there. What are the sysLocation and sysContact objects in the snmpd.conf file and how I can get those values for my machine?


Solution

  • All SNMP devices share the following common configurable parameters:

    • sysLocation
    • sysContact
    • sysName
    • Read-write and read-only access community strings (and frequently, a trap community string)
    • Trap destination

    sysLocation is the physical location for the device being monitored. Its definition in RFC 1213 is:

    sysLocation OBJECT-TYPE
        SYNTAX  DisplayString (SIZE (0..255))
        ACCESS  read-write
        STATUS  mandatory
        DESCRIPTION
            "The physical location of this node (e.g., 'telephone closet,
             3rd floor')."
        ::= { system 6 }
    

    RFC 1213's definition of sysContact is similar to that of sysLocation:

    sysContact OBJECT-TYPE
        SYNTAX  DisplayString (SIZE (0..255))
        ACCESS  read-write
        STATUS  mandatory
        DESCRIPTION
            "The textual identification of the contact person for this managed
             node, together with information on how to contact this person."
        ::= { system 4 }
    

    sysContact is a DisplayString. It's fairly obvious what it's used for: it identifies the primary contact for the device in question. It is important to set this object with an appropriate value, as it can help your operations staff determine who needs to be contacted in the event of some catastrophic failure. You can also use it to make sure you're notified, if you're responsible for a given device, when someone needs to take your device down for maintenance or repairs. As with sysLocation, make sure to keep this information up to date as your staff changes. It's not uncommon to find devices for which the sysContact is someone who left the company several years ago.

    source: http://docstore.mik.ua/orelly/networking_2ndEd/snmp/ch07_01.htm