snmp-server community string [view view-name] [ro | rw] [number]
no snmp-server community string
string Community string that acts like a password and permits access to the SNMP protocol. view view-name (Optional) Name of a previously defined view. The view defines the objects available to the community. ro (Optional) Specifies read-only access. Authorized management stations are only able to retrieve MIB objects. rw (Optional) Specifies read-write access. Authorized management stations are able to both retrieve and modify MIB objects. number (Optional) Integer from 1 to 99 that specifies an access list of IP addresses that are allowed to use the community string to gain access to the SNMP agent.
To set up the community access string to permit access to the Simple Network Management Protocol (SNMP), use the snmp-server community global configuration command. To remove the specified community string, use the no form of this command.
By default, an SNMP community string permits read-only access to all objects.
The no snmp-server command disables all versions of SNMP (SNMPv1, SNMPv2C, SNMPv3).
The first snmp-server command that you enter enables all versions of SNMP.
The following example assigns the string comaccess to SNMP allowing read-only access and specifies that IP access list 4 can use the community string:Router(config)# snmp-server community comaccess ro 4
The following example assigns the string mgr to SNMP allowing read-write access to the objects in the restricted view:Router(config)# snmp-server community mgr view restricted rw
The following example removes the community comaccess:Router(config)# no snmp-server community comaccess
The following example disables all versions of SNMP:Router(config)# no snmp-server
If the snmp-server community command is not used during the SNMP configuration session, it will automatically be added to the configuration after the snmp host command is used. In this case, the default password (string) for the snmp-server community will be taken from the snmp host command.
� Cisco Systems, Inc. 2001, 2002, 2003
World Wide Education
|Converted from CHM to HTML with chm2web Pro 2.85 (unicode)|