Introduction and practice of snmp communication line management

Source: Internet
Author: User
Tags snmp snmp port

Snmp Simple Network Management Protocol

The predecessor of the Simple Network Management Protocol (SNMP) is the Simple gateway monitoring Protocol (SGMP), which is used to manage communication lines. Subsequently, SGMP was greatly modified, especially when SMI and MIB compliant with Internet definitions were added: the improved protocol was the famous SNMP.

Simple Network Management protocol (SNMP) is composed of a set of network management standards, including an application layer protocol (application layer protocol), database model schema), and a set of data objects. This protocol supports network management systems to monitor whether devices connected to the network have any management concerns. This Protocol is part of an Internet protocol cluster defined by internet Engineering team IETF, Internet Engineering Task Force.

Working Process:

In typical SNMP usage, many systems are managed, and one or more systems are managing them. Each managed system runs a software component called agent, and reports information to the management system through SNMP.

Basically, the SNMP Agent presents management data with variables. The management system uses the GET, GETNEXT, and GETBULK protocol commands to retrieve information, or the agent uses TRAP or INFORM to transmit data without being asked. The management system can also send configuration update or control requests to actively manage the system through SET protocol commands. Configuration and control commands are only used when the basic structure of the network needs to be changed, while monitoring commands are often used.

Variables that can be accessed through SNMP are combined in a hierarchical manner. These layers and other metadata such as the type and description of variables) are described in the form of management information library MIBs.



Configure SNMP basic functions-SNMP v1 and SNMP v2C


Go to System View

System-view

Start the SNMP Agent service

By default, the snmp agent service is disabled. You can run this command or any configuration command of the SNMP-Agent to start the snmp agent.

Set system information

Snmp-agent sys-info {contact sys-contact | location sys-location | version {v1 | v2c |

V3} * | all} by default, the system maintenance contact information is "R & D Beijing, paiweitechnologies

Co., Ltd. "; physical location information:" Beijing China "; version: SNMPv3

Set group name and Access Permissions

Set directly

Set Group Name

Snmp-agent community {read | write} community-name [acl-number | mib-view

View-name] *

Indirect settings

Set an SNMP Group

Snmp-agent group {v1 | v2c} group-name [read-view] [write-view]

[Overview y-view overview y-view] [acl-number

Add a new user to an SNMP Group

Snmp-agent usm-user {v1 | v2c} user-namegroup-name [acl-number]

Set the size of the SNMP message package that the Agent can receive/send

The default value of snmp-agent packet max-size is 1500 bytes.



Configure basic SNMP functions for SNMP V3)

Go to System View

System-view

Start the SNMP Agent service

Snmp-agent (required) the SNMP Agent service is disabled by default.

Set an SNMP Group

Snmp-agent group v3 group-name [authentication | privacy] [read-view]

[Write-view] [policy-viewpolicy-view] [acl-number] (required)

Add a new user to an SNMP Group

Snmp-agent usm-user v3 user-name group-name [authentication-mode {md5 | sha}

Auth-password [privacy-mode des56priv-password] [acl-number] required

Configure Trap


Go to System View

System-view

Set Trap target host address

Snmp-agent target-host trap addressudp-domain {ip-address} [udp-port-number]

Params securityname security-string [v1 | v2c | v3 {authentication | privacy} (required)

Set the source address for sending the Trap

Snmp-agent trap source interface-typeinterface-number (optional)

Set the length of the message queue for the Trap packet sent to the target host.

Snmp-agent trap queue-size (optional)

SNMP display and Maintenance

Displays the system information of the current SNMP device.

Display snmp-agent sys-info [contact | location | version] *

Display Device group information

Display snmp-agent group [group-name]

Display SNMP user information

Display snmp-agent usm-user [engineidengineid | username user-name | group-name]

Show Trap list information

Display snmp-agent trap-list

Display the group name of the current configuration

Display snmp-agent community [read | write]

Displays the MIB view of the current configuration.

Display snmp-agent mib-view [exclude | include | viewname view-name]

Lab:

Environment: Virtual Machine: server2003 linux5.4

The topology is as follows:



650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F0M62-0.png "style =" float: none; "title =" 000 topology. PNG "/>


Enable and configure Server2003 SNMP:

650) this. width = 650; "src =" http://img1.51cto.com/attachment/201309/200912179.png "style =" float: none; "title =" 001 2003 server 01.PNG"/>



650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F03P8-2.png "style =" float: none; "title =" 001 2003 server 02.PNG"/>


View the snmp port 161

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F01A7-3.png "style =" float: none; "title =" 001 2003 server 03.PNG"/>

Basic configurations of the R1 Port:

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F030c-4.png "style =" float: none; "title =" 003 fw1 01.PNG"/>

Test communication with the Host:

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F05139-5.png "style =" float: none; "title =" 003 fw1 02.PNG"/>

Enable SNMP

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F010b-6.png "style =" float: none; "title =" 003 fw1 03.PNG"/>

Set Group Name

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F04194-7.png "style =" float: none; "title =" 003 fw1 04.PNG"/>

Set Contact Person: James

Location: Data Center 1

Supported protocols: all when not clear)

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F02629-8.png "style =" float: none; "title =" 003 fw1 05.PNG"/>

Enable the active report function:

Reported HOST: 192.168.2.200

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F04923-9.png "style =" float: none; "title =" 003 fw1 06.PNG"/>

Reports: situations reported)

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F014P-10.png "style =" float: none; "title =" 003 fw1 07.PNG"/>

Basic port configurations of R2:

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F04O5-11.png "style =" float: none; "title =" 004 fw2 01.PNG"/>

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F03335-12.png "style =" float: none; "title =" 004 fw2 02.PNG"/>

Communication between test and r1 and Host:

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F04537-13.png "style =" float: none; "title =" 004 fw2 03.PNG"/>

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F03K2-14.png "style =" float: none; "title =" 004 fw2 04.PNG"/>

The enable group name of SNMP:

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F01E5-15.png "style =" float: none; "title =" 004 fw2 05.PNG"/>

Set Contact Person: Li Si

Location: IDC 2

Supported protocols: all when not clear)

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F0O59-16.png "style =" float: none; "title =" 004 fw2 06.PNG"/>

Enable the active report function:

Reported HOST: 192.168.2.200

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F0AG-17.png "style =" float: none; "title =" 004 fw2 07.PNG"/>

Switch sw1 port configuration

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F04105-18.png "style =" float: none; "title =" 005 sw1 01.PNG"/>

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F0B03-19.png "style =" float: none; "title =" 005 sw1 02.PNG"/>

Set Account:

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F01032-20.png "style =" float: none; "title =" 005 sw1 03 account. PNG "/>

Servers 2003

Enable WhatsUp Gold

Enable scan as follows:

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F0O91-21.png "style =" float: none; "title =" 006 01.PNG"/>


The basic view is as follows:

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F03321-22.png "style =" float: none; "title =" 006 02.PNG"/>

Click Map in the lower left corner of the window to switch to the view.

Right-click the switch icon to log on to the management device:

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F05155-23.png "style =" float: none; "title =" 006 03.png"/>

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F051Q-24.png "style =" float: none; "title =" 006 04.PNG"/>

Enter 192.168.4.2 as follows:

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F0A29-25.png "style =" float: none; "title =" 006 05.PNG"/>


650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F0KX-26.png "title =" 006 06.PNG"/>


When the web server is disconnected, the following icon is displayed:

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131227/050F02V2-27.png "style =" float: none; "title =" 006 07.PNG"/>


After successful connection, the following information is displayed to monitor the device:


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.