[snmp++]读取cisco路由交换机信息[一] - 环境搭建
首先从网上下载gn3这个摸拟器以及cisco路由器的bin.
如图,下面的clouds里添加本地连接,这样表示路由器与本机的网卡桥接。即在R2里的接口设置一个与本机的IP地址同一网段。这样局域网的机就可以与R2通信
R2的配置如下
snmp-server community public RO 读
snmp-server community private RW 写
这两个开启snmp服务。
Router#show running-config Building configuration... Current configuration : 623 bytes ! version 12.4 service timestamps debug datetime msec service timestamps log datetime msec no service password-encryption ! hostname Router ! boot-start-marker boot-end-marker ! enable password wen ! no aaa new-model memory-size iomem 5 ! ! ip cef no ip domain lookup ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! interface FastEthernet0/0 ip address 192.168.15.196 255.255.255.0 duplex auto speed auto ! ip http server ! ! ! snmp-server community public RO snmp-server community private RW ! ! ! control-plane ! ! ! ! ! ! ! ! ! line con 0 line aux 0 line vty 0 4 password wen login line vty 5 871 password wen login ! ! end Router#
到此已可以用snmp++读取信息了