Atlassian uses cookies to improve your browsing experience, perform analytics and research, and conduct advertising. Accept all cookies to indicate that you agree to our use of cookies on your device.
Atlassian cookies and tracking notice, (opens new window)
Atlassian uses cookies to improve your browsing experience, perform analytics and research, and conduct advertising. Accept all cookies to indicate that you agree to our use of cookies on your device. Atlassian cookies and tracking notice, (opens new window)
/
Cisco router basic SNMP v1 or v2 configuration guide
Updated Apr 23, 2013

    Cisco router basic SNMP v1 or v2 configuration guide

    Apr 23, 2013

      The following code is an example configuration for a cisco device using SNMP v1 or v2 showing how to configure and access list, an SNMP view, SNMP read-only access and read-write access.  If you would prefer to use SNMP V3 see our guide here.

      If you are looking for a good SNMP management platform to provide fault and performance management you can download NMIS from here.  NMIS is an open source network management system, which supports Cisco devices including Nexus, ASR, CRS, Catalyst and good old IOS.

      Configuration

      The first command in the code below creates an access list that includes any device from 192.168.1.X and names the list 42.  

      The configuration then creates a view of the SNMP tree named NMIS8RO that allows the whole tree (iso is the root) to be visible (this could be changed so only the ifTable was accessible, for example), the community string NMISreadView is then attached to the view NMIS8RO and added as read-only to the access list 42.  

      The next line does almost the same thing, granting full access (no view specified) as read-only to our 42 access list.

      If read-write access is required you can use the next line, it enables SNMP writes using NMISwrite  as the community string that has full access to the snmp tree (no view given) when connecting from access list 42.

      Next location and contact details are configured.

      ! Access list to limit servers which can do SNMP access-list 42 permit 192.168.1.0 0.0.0.255 ! ! SNMP View to ensure entire SNMP Tree is available (optional) snmp-server view NMIS8RO iso included ! ! Read only Community String with view and Access List snmp-server community NMISreadView view NMIS8RO RO 42 ! ! Read only Community String and Access List snmp-server community NMISread RO 42 ! ! Read write community with access list (needed for IPSLA) snmp-server community NMISwrite RW 42 ! ! Set the location (optional) snmp-server location Brisbane, Queensland, Australia ! ! Set the contact (optional) snmp-server contact NMIS Dudes, +617 3555 5558

      That should be all that is required to get basic SNMP access to your router configured.  If you haven't already, add your cisco device to NMIS, instructions to do that are here. Note: if you have setup your device and everything should be working but it doesn't, try using SNMP v1 (see the previous instructions for how to do that in NMIS)

      Testing

      To test the new configuration use snmpwalk on your linux server running NMIS or your NMIS VM:

      snmpwalk -v 2c -c NMISread <cisco_device_name_or_ip> 1.3.6.1.2.1.1

      This command should output something like this:

      NMPv2-MIB::sysDescr.0 = STRING: Cisco IOS Software, 1841 Software (C1841-ADVENTERPRISEK9-M), Version 12.4(25f), RELEASE SOFTWARE (fc2) Technical Support: http://www.cisco.com/techsupport Copyright (c) 1986-2011 by Cisco Systems, Inc. Compiled Tue 16-Aug-11 06:21 by prod_rel_team SNMPv2-MIB::sysObjectID.0 = OID: SNMPv2-SMI::enterprises.9.1.620 DISMAN-EVENT-MIB::sysUpTimeInstance = Timeticks: (96372878) 11 days, 3:42:08.78 SNMPv2-MIB::sysContact.0 = STRING: SNMPv2-MIB::sysName.0 = STRING: cisco_device_name_or_ip SNMPv2-MIB::sysLocation.0 = STRING: SNMPv2-MIB::sysServices.0 = INTEGER: 78 SNMPv2-MIB::sysORLastChange.0 = Timeticks: (0) 0:00:00.00

       

      For more information, commands and sample configurations see the cisco configuration guide: http://www.cisco.com/en/US/docs/ios/12_2/configfun/configuration/guide/fcf014.html

        Community Home

        NMIS
        • Downloads
          Downloads
        • Downloads
          Downloads
        • Downloads
          Downloads
        Results will update as you type.
        • Introduction & Setup
        • Configuration
          • Additional CBQoS SNMP Collection
          • Advanced Configuration Options for Optimising NMIS8
          • Cisco SNMP Configuration and Verfication Process
          • Configuration Files for NMIS
          • Configuring Email Server for NMIS Notifications including Gmail server
          • Configuring NMIS for full LDAP Support
          • Configuring NMIS for Multi-Tenancy
          • Configuring NMIS to use Active Directory Authentication (ms-ldap or ms-ldaps)
          • Configuring NMIS to use Internal Authentication
          • Controlling the Collection of Interfaces, Adjustments and Overrides
          • Import Nodes into NMIS8 - bulk import and integration
          • Linking Nodes to other systems including Web, SSH, Telnet and whatever you need.
          • Making Sounds for Critical Events on the NMIS Dashboard
          • Managing Servers and Services with NMIS8
          • Modelling MIBS that use Indexes using the systemHealth section
          • NMIS8 - Installing NMIS in a Non Standard Location
          • NMIS8 Configuration
            • Adding and Editing a Device in NMIS8
            • Cisco router basic SNMP v1 or v2 configuration guide
            • NMIS8 - A Quick Getting Started Guide
            • NMIS8 Contacts
            • NMIS8 Email
            • NMIS8 Escalations
            • NMIS8 Groups
            • NMIS8 Nodes
            • NMIS8 Roles
          • NMIS8 Node Polling Configuration
          • NMIS9 Documentation
          • NMIS 8 - Configuration Options for Server Performance Tuning
          • NMIS 9 - Configuration Options for Server Performance Tuning
          • NMIS - Polling Policy - Configuring Variable Polling Polices
          • NMIS Configuration
          • NMIS Customising the Dashboard Layout - Save Windows and Positions
          • NMIS File Permissions
          • NMIS Threshold Configuration
          • SNMP Traps with Cisco and Other devices
          • Sync or copy NMIS data between two NMIS servers
          • User Management in NMIS
          • Using SNMPv3 with NMIS for Secure Network Management
          • Using Unique Identifiers (UUID) for NMIS Nodes
        • Features
        • Virtual Machine
        • How-To Guides
        • FAQ
        • Release Notes
        • Troubleshooting & Help
        • Opmantek Virtual Machine: Implementing SNMPv3 AES256 in the NMIS9 VM for Secure Network Management
        • NMIS8 VM Installation Guide
        • Virtual Appliance Maintenance: Updating Software
        • NMIS Device Troubleshooting Process
        • Automatically accept EULAs
        • Using NMIS to monitor services
        • Linux Hardening Guides
        • Solutions
        • NMIS9 - WMI Basic Configuration
        • NMIS9 - SNMP Basic Configuration
        • How to Configure WMI on the Windows Server
        • How to test WMI using the wbemtest
        • SNMP Trap and Rsyslog Setup for Ubuntu 20+
          Questions
          Calendars

        You‘re viewing this with anonymous access, so some content might be blocked.
        {"serverDuration": 12, "requestCorrelationId": "4559b9e9347340988f63ff766e5eaeca"}