当前位置:文档之家› 各类设备snmp配置

各类设备snmp配置

设备SNMP配置说明1、SNMP原理的相关介绍 (2)2、各种设备SNMP协议的配置 (3)Cisco设备 (3)Catalyst OS (3)IOS (3)华为设备 (3)IOS (3)Huawei OS (3)Foundry设备 (3)港湾设备 (3)Extreme设备 (4)configure snmp community (4)用来替代第一种命令 (4)3COM设备 (5)Avaya设备 (6)北电设备 (6)北电passport 86系列snmp配置 (6)passport 6400 (6)passport 8006 (7)nortel系列 (7)3com交换机snmp配置 (7)4900交换机网管的设置 (7)4400交换机网管的设置 (7)4200交换机网管的设置 (8)1、SNMP原理的相关介绍基于TCP / IP的网络管理包含两部分:网络管理站(也叫管理进程,m a n a g e r)和被管理的网络单元(也叫被管设备)。

被管设备种类繁多,例如:路由器、X 终端、终端服务器和打印机等。

这些被管设备的共同点就是都运行TCP / IP协议。

被管设备端和管理相关的软件叫做代理程序( a g e n t )或代理进程。

基于TCP / IP的网络管理包含3个组成部分:1) 一个管理信息库M I B(Management Information Base)。

管理信息库包含所有代理进程的所有可被查询和修改的参数。

2) 关于M I B 的一套公用的结构和表示符号。

叫做管理信息结构S M I(Structure of Management Information)。

3) 管理进程和代理进程之间的通信协议,叫做简单网络管理协议S N M P(Simple Network Management Protocol)。

关于管理进程和代理进程之间的交互信息,S N M P定义了5种报文:1) g e t - r e q u e s t操作:从代理进程处提取一个或多个参数值。

2) g e t - n e x t - r e q u e s t操作:从代理进程处提取一个或多个参数的下一个参数值。

3) s e t - r e q u e s t操作:设置代理进程的一个或多个参数值。

4) g e t - r e s p o n s e操作:返回的一个或多个参数值。

这个操作是由代理进程发出的。

它是前面3中操作的响应操作。

5) t r a p 操作:代理进程主动发出的报文,通知管理进程有某些事情发生。

前面的3个操作是由管理进程向代理进程发出的。

后面两个是代理进程发给管理进程的(为简化起见,前面3个操作分别叫做g e t、g e t - n e x t和s e t操作)。

SNMP(简单网络管理协议)是用来管理网络设备时的国际标准协议,通过对网络设备MIB(管理信息库)中的具体参数的查询和设置,可以实现对网络设备的管理。

例如:对许多启用了标准SNMP协议的网络设备(如Cisco交换机、路由器等)的接口信息,不但能使用前面介绍的SNMP的get操作获得接口状态的up或down的信息,而且可以使用set 操作来设置接口的up或down状态。

这就是使用SNMP协议对网络设备进行管理的技术实现原理。

2、各种设备SNMP协议的配置Cisco设备Catalyst OS配置SNMP的共同体名:set snmp community [read-only|read-write|read-write-all] community_stringIOS全局模式配置SNMP的共同体名:snmp-server community community_string [ro|rw]华为设备IOS同Cisco配置方法Huawei OS<switch>super[switch]sys[switch]snmp-agent community [read|write] community_string[switch]snmp-agent sys-info version allFoundry设备同Cisco设备IOS配置方法港湾设备命令格式:config snmp community [readonly|readwrite] <string>[readonly|readwrite] 读确认/读写确认字符串默认值:<string> 字符串值readonly:public;readwrite:private使用指导community 字符串为远程网络管理员配置交换机提供了一种用户确认机制。

在交换机上有两种Community 字符串:读确认字符串(readonly)允许对交换机进行只读访问;读写确认字符串(readwrite)提供了对交换机读写操作的权限。

配置实例Harbour(config)# config snmp community readonly harbourservice snmp enable相关命令show snmp community-stringExtreme设备configure snmp community命令格式:configure snmp community [readonly | readwrite] {encrypted} <alphanumeric string>命令描述:Configures the value of the default SNMP read or read/write community string.readonly Specifies read-only access to the system.readwrite Specifies read and write access to the system.encrypted Specifies encryption, for use only by the switch when uploading ordownloading a configuration. Should not be used through the CLI.alphanumeric string Specifies an SNMP community string name.默认值:The default read-only community string is public. The default read/write community string is private.举例:以下命令是设置一个读写权限的共同体名extremeconfigure snmp community readwrite extreme用来替代第一种命令命令格式:configure snmp add community [readonly | readwrite] {encrypted} <alphanumeric string>命令描述:Adds an SNMP read or read/write community string.readonly Specifies read-only access to the system.readwrite Specifies read and write access to the system.encrypted Specifies encryption, for use only by the switch when uploading ordownloading a configuration. alphanumeric string Specifies an SNMP community string name.See “Usage Guidelines” for moreinformation.默认值:The default read-only community string is public. The default read/write community string is private.用法:Community strings provide a simple method of authentication between a switch and a remote networkmanager. Read community strings provide read-only access to the switch. The default read-only community string is public. Read-write community strings provide read and write access to the switch.The default read/write community string is private.To change the value of the default read/write and read-only community strings, use the configure snmp community command.举例:以下命令是设置一个读写权限的共同体名extremeconfigure snmp add community readwrite extreme3COM设备华为3Com路由器、交换机新旧命令行配置snmp对比新命令行版本中:snmp-agent local-engineid 800007DB00E0FC0000106877 #该行自动生成* snmp-agent community read public* snmp-agent community write privatesnmp-agent sys-info contact HuaWei BeiJing Chinasnmp-agent sys-info location BeiJing China* snmp-agent sys-info version all* snmp-agent trap-host .... #接收trap的网管主机地址老命令行版本中:* snmp-server enable traps snmpsnmp-server engineid 800007DB00E0FC0000106877 #该行自动生成* snmp-server community public ro* snmp-server community private rw* snmp-server host 10.110.x.x public #接收trap的网管主机地址snmp-server trap-source Vlan-interface2 #发送trap的源端口说明:当存在网管平台(如N2000)和Quidview集成时,带*号的为必配置项目。

相关主题