[go: up one dir, main page]

WO2012037762A1 - Method and apparatus for configuring address resolution protocol entry - Google Patents

Method and apparatus for configuring address resolution protocol entry Download PDF

Info

Publication number
WO2012037762A1
WO2012037762A1 PCT/CN2010/080025 CN2010080025W WO2012037762A1 WO 2012037762 A1 WO2012037762 A1 WO 2012037762A1 CN 2010080025 W CN2010080025 W CN 2010080025W WO 2012037762 A1 WO2012037762 A1 WO 2012037762A1
Authority
WO
WIPO (PCT)
Prior art keywords
address
interface
resolution protocol
address resolution
vlan
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Ceased
Application number
PCT/CN2010/080025
Other languages
French (fr)
Chinese (zh)
Inventor
孙凯意
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
ZTE Corp
Original Assignee
ZTE Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by ZTE Corp filed Critical ZTE Corp
Publication of WO2012037762A1 publication Critical patent/WO2012037762A1/en
Anticipated expiration legal-status Critical
Ceased legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • H04L61/09Mapping addresses
    • H04L61/10Mapping addresses of different types
    • H04L61/103Mapping addresses of different types across network layers, e.g. resolution of network layer into physical layer addresses or address resolution protocol [ARP]

Definitions

  • the present invention relates to the field of network communication technologies, and in particular, to a method and apparatus for configuring an address resolution protocol table. Background technique
  • a network element device when a network element device sends data to other network element devices, it needs to know the IP address and medium access control (MAC) address of the other network device.
  • the network element device can know the IP address of the other network element device; and the MAC address is obtained by searching in the address resolution protocol entry (the address resolution protocol entry includes a matching IP address and a MAC address); The network element device knows the MAC address of the other network element device, and can send data to the other network element device.
  • the process of obtaining the MAC address of the target network element device by the source network element device is as follows: First, the source network element device sends an address resolution protocol request to other network element devices, and all other network element devices determine the address after receiving the address resolution protocol request. If the IP address in the protocol request matches the MAC address of the protocol, if the matching, the target network element device sends the response information including the MAC address to the source network element device, and the source network element device obtains the target network according to the response information. The MAC address of the metadevice.
  • the source NE device When the source NE device needs to send data, it first searches for the MAC address matching the IP address of the target network element device in the address resolution protocol table corresponding to its own IP interface. If the MAC address matching the IP address is not found, the MAC address of the target network element device is obtained by sending an address resolution protocol to all other network element devices.
  • mapping between an IP address and a MAC address in the above address resolution protocol entry is generally manually configured. Due to the large number of networks, manual configuration errors often occur, causing some network element devices to fail to send data to other network element devices. Summary of the invention
  • the main purpose of the present invention is to provide a method and apparatus for configuring an address resolution protocol table, which improves the correctness of the mapping relationship between an IP address and a MAC address in an address resolution protocol entry.
  • the present invention provides a method for configuring an address resolution protocol table, which includes:
  • V LAN virtual local area network
  • the method further includes: determining whether the first a second device to which the device is optically connected;
  • the first device is connected to the physical port of the second device by the physical port of the first device; the physical port of the first device and the physical port corresponding to the second device are in the VLAN.
  • the first device includes: one or more first device IP interfaces; each first device IP interface corresponds to an address resolution protocol entry.
  • the second device connected to the first device fiber is one or more; each second device includes one or more second device IP interfaces.
  • the present invention further provides an apparatus for configuring an address resolution protocol table, including:
  • a first query module configured to: query a second device that is connected to the first device fiber a first device IP interface and a second device IP interface under a virtual local area network (V LAN ) where the physical port is located;
  • V LAN virtual local area network
  • a second query module configured to: query the first device IP interface and the second device IP interface in the same network segment from the VLAN;
  • An acquiring module configured to: obtain an IP address corresponding to a second device IP interface of the network segment, and a media access control (MAC) address of the second device, and establish a mapping relationship between the IP address and the MAC address;
  • MAC media access control
  • the module is added, and the mapping relationship is added to the address resolution protocol entry corresponding to the IP address of the first device under the network segment.
  • the apparatus for configuring an address resolution protocol of the present invention further includes:
  • a judging module configured to: determine whether there is a second device connected to the first device fiber;
  • And establishing a module configured to: establish a fiber connection between the first device and the second device when there is no second device connected to the first device fiber.
  • the first device is connected to the physical port of the second device by the physical port of the first device; the physical port of the first device and the physical port corresponding to the second device are in the VLAN.
  • the first device includes: one or more first device IP interfaces; each first device IP interface corresponds to an address resolution protocol entry.
  • the second device connected to the first device fiber is one or more; each second device includes one or more second device IP interfaces.
  • the mapping method of the address resolution protocol table provided by the present invention by establishing the second device MAC, is mapped to the IP address corresponding to the IP address of the second device IP interface of the same device and the IP address of the second device on the same network segment.
  • the mapping relationship is added to the address resolution protocol entry corresponding to the corresponding IP address of the first device, and the configuration speed is fast, which ensures the correctness of the mapping relationship between the IP address and the MAC address in the address resolution protocol entry, thereby ensuring the first device.
  • the address resolution protocol entry is used to accurately find the MAC address of the target second device.
  • FIG. 1 is a flowchart of an embodiment of a method for configuring an address resolution protocol of the present invention
  • FIG. 2 is a flowchart of another embodiment of a method for configuring an address resolution protocol of the present invention
  • FIG. 3 is an address resolution protocol of the present invention.
  • FIG. 4 is a schematic structural diagram of another embodiment of an apparatus for configuring an address resolution protocol according to the present invention.
  • FIG. 5 is a block diagram showing the structure of a Transport Multi-Protocol Label Switching (T-MPLS) network system according to the present invention.
  • T-MPLS Transport Multi-Protocol Label Switching
  • Step S101 Query a first virtual local area network (V LAN ) corresponding to a physical port corresponding to a second device connected to the first device fiber.
  • V LAN virtual local area network
  • Step S102 Query, from the VLAN, the first device IP interface and the second device IP interface in the same network segment;
  • Step S103 Obtain an IP address corresponding to the second device IP interface of the network segment and a media access control (MAC) address of the second device, and establish a mapping relationship between the IP address and the MAC address.
  • MAC media access control
  • Step S104 Add the mapping relationship to an address resolution protocol entry corresponding to the IP address of the first device under the network segment.
  • the MAC address of the second device is obtained from a database in the T-MPLS network system.
  • the MAC address of all network element devices in the T-MPLS network system is recorded in the database.
  • the MAC address of each network element device is the sum of the rack MAC address of the network element device and the corresponding offset value.
  • FIG. 2 another embodiment of the method for configuring an address resolution protocol table of the present invention is provided, which includes:
  • Step S201 determining whether there is a second device connected to the first device fiber
  • Step S202 if not, establishing a fiber connection between the first device and the second device;
  • Step S203 Querying a first device in a virtual local area network (VLAN) where the physical port corresponding to the second device connected to the first device fiber is located IP interface and second device IP interface;
  • VLAN virtual local area network
  • Step S204 Query, from the VLAN, the first device IP interface and the second device IP interface in the same network segment;
  • Step S205 Obtain an IP address corresponding to the IP address of the second device under the network segment and a Media Access Control (MAC) address of the second device, and establish a mapping relationship between the IP address and the MAC address.
  • MAC Media Access Control
  • Step S206 Add the mapping relationship to an address resolution protocol entry corresponding to the IP address of the first device under the network segment.
  • the steps S203 to S206 of the embodiment are the same as the steps S101 to S104 of the previous embodiment, and details are not described herein again.
  • step S201 it is determined whether there is a second device connected to the first device fiber, which is based on the first device topology connection obtained in the T-MPLS network system database, and if the topology connection of the first device is empty, There is no second device connected to the first device fiber.
  • the first device is connected to the physical port of the first device through the physical port of the first device; the physical port of the first device and the physical port corresponding to the second device are in the VLAN. .
  • the information about the first device IP interface and the second device IP interface under the VLAN and under the same network segment may be recorded in a set table.
  • the first device includes: one or more first device IP interfaces; each first device IP interface corresponds to an address resolution protocol entry.
  • the second device connected to the first device fiber is one or more; each second device includes one or more second device IP interfaces.
  • the different second devices have different IP interfaces, and the corresponding MAC addresses are different.
  • each second device in the VLAN and in the same network segment includes the second device 1, 2, 3, 4, each second device includes a second device IP interface.
  • the IP address corresponding to the IP interface of the second device 1 is a
  • the IP address corresponding to the IP interface of the second device 2 is b
  • the IP address corresponding to the IP interface of the second device 3 is c
  • the IP address of the second device 4 The IP address corresponding to the interface is d; the MAC address of the second device 1 is k, the MAC address of the second device 2 is w, the MAC address of the second device 3 is X, and the MAC address of the second device 4 is y.
  • IP address a corresponds to MAC address k
  • IP address b corresponds to MAC address w
  • IP address c corresponds to MAC address x
  • IP address d corresponds to MAC address y.
  • a second device includes multiple second device IP interfaces, for example, the second device 1 includes two IP interfaces, one of the IP interfaces corresponding to the IP address is al, and the other IP interface corresponding to the IP address is a2;
  • the device 3 includes two IP interfaces.
  • the IP address corresponding to one IP interface is cl, and the IP address corresponding to the other IP interface is c2.
  • IP address a corresponds to MAC address k
  • IP address a2 corresponds to MAC address k
  • IP address b corresponds to MAC address w
  • IP address cl corresponds to MAC address X
  • IP address c2 Corresponding to the MAC address x
  • the IP address d corresponds to the MAC address y; and so on.
  • the IP address and MAC address mapping relationship 1 or 2 is added to the address resolution protocol corresponding to the IP address I of the first device.
  • the mapping between the IP address and the MAC address is 1 or 2 , respectively, added to the address resolution protocol entry corresponding to the IP interface I and II of the first device, and so on.
  • the MAC address, the mapping relationship between the IP address corresponding to the IP address of the second device and the IP address of the second device on the same network segment, and the mapping relationship is added to the address resolution protocol entry corresponding to the IP interface of the corresponding first device.
  • the configuration is fast, and the correct mapping between the IP address and the MAC address in the address resolution protocol entry is ensured. Therefore, the first device can accurately find the MAC address of the target second device through the address resolution protocol entry.
  • the configuration method of the address resolution protocol table provided in this embodiment has the advantage of quick configuration speed compared to the manual configuration of the prior art.
  • the method includes: a first query module 11, a second query module 12, an obtaining module 13, and an adding module 14.
  • the first query module 11 is configured to query the first device IP interface and the second device IP interface under the virtual local area network (V LAN ) where the physical port corresponding to the second device connected to the first device fiber is located.
  • the second query module 12 is configured to query, from the VLAN, the first device IP interface and the second device IP interface under the same network segment.
  • the obtaining module 13 is configured to obtain an IP address corresponding to the second device IP interface of the network segment and a media access control (MAC) address of the second device, and establish a mapping relationship between the IP address and the MAC address.
  • the adding module 14 is configured to add the mapping relationship to an address resolution protocol entry corresponding to the IP interface of the first device in the network segment.
  • the MAC address of the second device is obtained from a database in the T-MPLS network system, and the MAC address of all the network element devices in the T-MPLS network system is recorded in the database.
  • the MAC address of each network element device is the sum of the rack MAC address of the network element device and the corresponding offset value.
  • FIG. 4 another embodiment of the address resolution protocol table configuration apparatus 20 of the present invention is provided, which includes: a determining module 21, an establishing module 22, a first querying module 23, a second querying module 24, and an obtaining module 25. , join module 26.
  • the first query module 23, the second query module 24, the obtaining module 25, and the joining module 26 are respectively consistent with the functions of the modules of the same name in the foregoing embodiments, and details are not described herein again.
  • the determining module 21 is configured to determine whether there is a second device connected to the optical fiber of the first device.
  • the establishing module 22 is configured to establish a fiber connection between the first device and the second device when there is no second device connected to the first device fiber. Wherein, determining whether there is a second device connected to the optical fiber of the first device is based on
  • the first device topology connection obtained in the T-MPLS network system database if the top connection of the first device is empty, it indicates that there is no second device connected to the first device fiber.
  • the first device in the configuration device 20 of the address resolution protocol table is connected to the physical port optical fiber corresponding to the second device by using the physical port of the first device; the physical port corresponding to the physical port of the first device and the second device The port is in the VLAN.
  • the information about the first device IP interface and the second device IP interface under the VLAN and under the same network segment may be recorded in a set table.
  • the first device in the configuration device 20 of the address resolution protocol table includes: one or more first device IP interfaces; each first device IP interface corresponds to an address resolution protocol entry.
  • the second device that is optically connected to the first device in the configuration device 20 of the address resolution protocol table is one or more; each second device includes one or more second device IP interfaces.
  • the different second devices have different IP interfaces, and the corresponding MAC addresses are different.
  • each second device in the VLAN and in the same network segment includes the second device 1, 2, 3, 4, each second device includes a second device IP interface.
  • the IP address corresponding to the IP interface of the second device 1 is a
  • the IP address corresponding to the IP interface of the second device 2 is b
  • the IP address corresponding to the IP interface of the second device 3 is c
  • the IP address of the second device 4 The IP address corresponding to the interface is d; the MAC address of the second device 1 is k, the MAC address of the second device 2 is w, the MAC address of the second device 3 is X, and the MAC address of the second device 4 is y.
  • IP address a corresponds to MAC address k
  • IP address b corresponds to MAC address w
  • IP address c corresponds to MAC address x
  • IP address d corresponds to MAC address y.
  • a second device includes multiple second device IP interfaces, for example, the second device 1 includes two IP interfaces, one of which corresponds to an IP address of a l and the other IP interface has an IP address of a2;
  • the second device 3 includes two IP interfaces, and one of the IP interfaces corresponds to an IP address of cl.
  • the IP address corresponding to an IP interface is c2.
  • IP address a corresponds to MAC address k
  • IP address a2 corresponds to MAC address k
  • IP address b corresponds to MAC address w
  • IP address cl corresponds to MAC address X
  • IP address c2 Corresponding to the MAC address x
  • the IP address d corresponds to the MAC address y; and so on.
  • the IP address and MAC address mapping relationship 1 or 2 is added to the address resolution protocol corresponding to the IP address I of the first device.
  • the mapping between the IP address and the MAC address is 1 or 2 , respectively, added to the address resolution protocol entry corresponding to the IP interface I and II of the first device, and so on.
  • the mapping device of the address resolution protocol of the embodiment is configured by establishing a mapping relationship between the second device MAC and the IP address corresponding to the IP address of the second device and the second device IP interface of the first device. The relationship is added to the corresponding address resolution protocol entry corresponding to the IP address of the first device.
  • the configuration is fast, ensuring the correctness of the mapping between the IP address and the MAC address in the address resolution protocol entry. Therefore, the first device passes the address.
  • the resolution protocol entry accurately finds the MAC address of the target second device.
  • the device for configuring the address resolution protocol table provided in this embodiment has the advantage of quick configuration speed compared to the manual configuration of the prior art.
  • the device for configuring the address resolution protocol table provided in this embodiment may be separately set or may be set in the first device.
  • the first device and the second device described in the foregoing embodiments are network element devices in the T-MPLS network system.
  • the following is a specific example of the present invention:
  • FIG. 5 is a schematic structural diagram of a T-MPLS network system, which includes network element devices NE1, NE2, NE3, and NE4, and the NE1 is connected to NE2, NE3, and NE4, respectively.
  • the connection between NE1 and NE2 is through the physical ports of NE1, Gei-1/9 and NE2.
  • Physical port Gei-1/10 fiber connection implementation the Gei-1/9 of NE1 is in VLAN 2
  • the IP address corresponding to the IP interface of NE1 in VLAN 2 is 192.168.100.1
  • the Gei-1/10 of NE2 is in VLAN 2
  • the IP address corresponding to the IP interface of NE2 in VLAN 2 is 192.168.100.2.
  • the connection between NE1 and NE3 is realized by the physical port Gei-1/10 of NE1 and the Gei-1/10 fiber connection of the physical port of NE2.
  • the Gei-1/10 of NE1 is in VLAN3
  • the IP address of the IP interface of NE1 in VLAN3 is 192.168.200.1
  • the Gei-1/10 of NE3 is in VLAN 4
  • the IP address corresponding to the IP interface of NE3 in VLAN 4 is 192.168. .200.2.
  • the connection between NE1 and NE4 is realized by the physical port Gei-1/1 of NE1 and the physical port Gei-1/10 fiber of NE2.
  • the Gei-1/1 of NE1 is in VLAN 2
  • the IP address corresponding to the IP interface of NE1 in VLAN 2 is 192.168.200.1
  • the Gei-1/10 of NE4 is in VLAN 2
  • the IP address corresponding to the IP interface of NE4 in VLAN 2 is 192.168.100.3.
  • the IP interface in the VLAN 2 includes: the IP interface corresponding to the IP address 192.168.100.1 of the IP1 in the VLAN 2 and the IP interface corresponding to the IP address 192.168.200.1, and the IP interface corresponding to the IP address 192.168.100.2 of the NE2 in the VLAN 2.
  • IP interfaces on the same network segment of the IP interface in VLAN 2 include: IP interface corresponding to IP address 192.168.100.1 of NE1 in VLAN 2, IP interface corresponding to IP address 192.168.100.2 of NE2 in VLAN 2, and VLAN 4 of NE4 in VLAN 2.
  • the IP address of 192.168.100.2 of NE2 is mapped to the MAC address of NE2, and the mapping relationship is added to the address resolution protocol of the IP interface corresponding to IP address 192.168.100.1 in NE1.
  • the IP address of 192.168.100.3 of NE4 is mapped to the MAC address of NE4, and the mapping relationship is added to the address resolution protocol of the IP interface corresponding to IP address 192.168.100.1 in NE1.
  • the method and device for configuring an address resolution protocol table provided by the present invention by establishing a second device
  • the MAC address, the mapping relationship between the IP address corresponding to the IP address of the second device and the IP address of the second device on the same network segment, and the mapping relationship is added to the address resolution protocol entry corresponding to the IP interface of the corresponding first device.
  • the configuration is fast, and the correct mapping between the IP address and the MAC address in the address resolution protocol entry is ensured. Therefore, the first device can accurately find the MAC address of the target second device through the address resolution protocol entry.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Small-Scale Networks (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

A method and apparatus for configuring an address resolution protocol entry are disclosed in the present invention. The method includes: inquiring IP interfaces of a first device and a second device which is connected with the first device by fiber in a Virtual Local Area Network (VLAN) in which the physical port of the second device locates (S101); inquiring the IP interfaces of the first device and the second device under the same network section in the VLAN (S102); acquiring the IP address and the Media Access Control (MAC) address corresponding to the IP interface of the second device under the network section, and establishing a mapping relationship between the IP address and the MAC address (S103); adding the mapping relationship to the address resolution protocol entry corresponding to the IP interface of the first device under the network section (S104). The method and apparatus for configuring an address resolution protocol entry provided by the present invention ensures the correctness of the mapping relationship between the IP address and the MAC address in the address resolution protocol entry, by establishing the mapping relationship between the MAC of the second device and the IP address of the second device which is in the same VLAN and the same network section with the IP interface of the first device, and adding the mapping relationship to the address resolution protocol entry of the first device.

Description

地址解析协议表目的配置方法和装置  Address analysis protocol table configuration method and device

技术领域 Technical field

本发明涉及网络通讯技术领域, 尤其涉及一种地址解析协议表目的配置 方法和装置。 背景技术  The present invention relates to the field of network communication technologies, and in particular, to a method and apparatus for configuring an address resolution protocol table. Background technique

现有技术中, 网元设备向其他网元设备发送数据时, 需要知道该其他网 络设备的 IP地址和介质访问控制 ( MAC )地址。 一般地网元设备都可以知 道该其他网元设备的 IP地址; 而 MAC地址则需通过在地址解析协议表目查 找来获取 (地址解析协议表目包含有相匹配的 IP地址和 MAC地址); 网元设 备知道该其他网元设备的 MAC地址, 便可向该其他网元设备发送数据。  In the prior art, when a network element device sends data to other network element devices, it needs to know the IP address and medium access control (MAC) address of the other network device. Generally, the network element device can know the IP address of the other network element device; and the MAC address is obtained by searching in the address resolution protocol entry (the address resolution protocol entry includes a matching IP address and a MAC address); The network element device knows the MAC address of the other network element device, and can send data to the other network element device.

源网元设备获取目标网元设备的 MAC地址的过程如下: 首先源网元设 备向其他网元设备发送地址解析协议请求, 其他所有的网元设备接收到该地 址解析协议请求后, 都会判断地址解析协议请求中的 IP地址是否与其本身的 MAC地址匹配, 若匹配, 该目标网元设备向源网元设备发送包含 MAC地址 的应答信息, 源网元设备则根据该应答信息便可获得目标网元设备的 MAC 地址。  The process of obtaining the MAC address of the target network element device by the source network element device is as follows: First, the source network element device sends an address resolution protocol request to other network element devices, and all other network element devices determine the address after receiving the address resolution protocol request. If the IP address in the protocol request matches the MAC address of the protocol, if the matching, the target network element device sends the response information including the MAC address to the source network element device, and the source network element device obtains the target network according to the response information. The MAC address of the metadevice.

上述这种通过向所有的其他网元设备发送地址解析协议请求, 以获取目 标网元设备的 MAC地址的方式, 占用了大量的传输资源。 为了减少所占的 传输资源,现有技术中,通过将目标网元设备的 IP地址与 MAC地址的映射 关系緩存在自身的 IP接口对应的地址解析协议表目中。  The foregoing manner of occupying a MAC address of a target network element device by sending an address resolution protocol request to all other network element devices occupies a large amount of transmission resources. In the prior art, the mapping relationship between the IP address of the target network element device and the MAC address is cached in the address resolution protocol entry corresponding to the IP interface of the target network element.

当源网元设备需要发送数据时, 首先在其自身的 IP接口对应的地址解析 协议表目中, 查找与目标网元设备的 IP地址相匹配的 MAC地址。 若未查找 到与 IP地址相匹配的 MAC地址, 则通过向所有其他的网元设备发送地址解 析协议请求获得目标网元设备的 MAC地址。  When the source NE device needs to send data, it first searches for the MAC address matching the IP address of the target network element device in the address resolution protocol table corresponding to its own IP interface. If the MAC address matching the IP address is not found, the MAC address of the target network element device is obtained by sending an address resolution protocol to all other network element devices.

上述的地址解析协议表目中 IP地址与 MAC地址的映射关系一般是通过 手工配置。 由于网路庞大, 手工配置时常出现错误, 使部分网元设备无法正 常向其他网元设备发送数据。 发明内容 The mapping between an IP address and a MAC address in the above address resolution protocol entry is generally manually configured. Due to the large number of networks, manual configuration errors often occur, causing some network element devices to fail to send data to other network element devices. Summary of the invention

本发明的主要目的在于提供一种地址解析协议表目的配置方法和装置, 提高地址解析协议表目中 IP地址与 MAC地址映射关系的正确性。  The main purpose of the present invention is to provide a method and apparatus for configuring an address resolution protocol table, which improves the correctness of the mapping relationship between an IP address and a MAC address in an address resolution protocol entry.

本发明提出一种地址解析协议表目的配置方法, 其包括:  The present invention provides a method for configuring an address resolution protocol table, which includes:

查询与第一设备光纤连接的第二设备对应的物理端口所在虚拟局域网 ( V LAN ) 下的第一设备 IP接口和第二设备 IP接口;  Querying a first device IP interface and a second device IP interface in a virtual local area network (V LAN ) where the physical port corresponding to the second device connected to the first device fiber is located;

从所述 VLAN下查询在同一网段下的第一设备 IP接口和第二设备 IP接 口; 获取所述网段下的第二设备 IP接口对应的 IP地址和第二设备的介质访 问控制 ( MAC )地址, 并建立所述 IP地址与 MAC地址的映射关系; 以及 将所述映射关系加入所述网段下的第一设备 IP接口对应的地址解析协议 表目。  Querying the first device IP interface and the second device IP interface in the same network segment from the VLAN; obtaining the IP address corresponding to the second device IP interface and the media access control of the second device (MAC) The address, and the mapping relationship between the IP address and the MAC address is established; and the mapping relationship is added to the address resolution protocol entry corresponding to the IP interface of the first device under the network segment.

优选地, 所述查询与第一设备光纤连接的第二设备对应的物理端口所在 V LAN下的第一设备 IP接口和第二设备 IP接口之前, 所述方法还包括: 判断是否存在与第一设备光纤连接的第二设备;  Preferably, before the querying the first device IP interface and the second device IP interface in the V LAN corresponding to the physical port of the second device connected to the first device, the method further includes: determining whether the first a second device to which the device is optically connected;

若不存在, 则建立第一设备与第二设备的光纤连接。  If not, establish a fiber connection between the first device and the second device.

优选地, 所述第一设备通过第一设备物理端口与第二设备对应的物理端 口光纤连接; 所述第一设备物理端口和第二设备对应的物理端口处于所述 VLAN下。  Preferably, the first device is connected to the physical port of the second device by the physical port of the first device; the physical port of the first device and the physical port corresponding to the second device are in the VLAN.

优选地, 所述第一设备包括: 一个或多个第一设备 IP接口; 每个第一设 备 IP接口对应一个地址解析协议表目。  Preferably, the first device includes: one or more first device IP interfaces; each first device IP interface corresponds to an address resolution protocol entry.

优选地, 所述与第一设备光纤连接的第二设备为一个或多个; 每个第二 设备包括有一个或多个第二设备 IP接口。  Preferably, the second device connected to the first device fiber is one or more; each second device includes one or more second device IP interfaces.

本发明另提出一种地址解析协议表目的配置装置, 其包括: The present invention further provides an apparatus for configuring an address resolution protocol table, including:

第一查询模块, 其设置为: 查询与第一设备光纤连接的第二设备对应的 物理端口所在虚拟局域网 (V LAN ) 下的第一设备 IP接口和第二设备 IP接 口; a first query module, configured to: query a second device that is connected to the first device fiber a first device IP interface and a second device IP interface under a virtual local area network (V LAN ) where the physical port is located;

第二查询模块, 其设置为: 从所述 VLAN下查询在同一网段下的第一设 备 IP接口和第二设备 IP接口;  a second query module, configured to: query the first device IP interface and the second device IP interface in the same network segment from the VLAN;

获取模块, 其设置为: 获取所述网段下的第二设备 IP接口对应的 IP地 址和第二设备的介质访问控制(MAC )地址, 并建立所述 IP地址与 MAC地 址的映射关系; 以及  An acquiring module, configured to: obtain an IP address corresponding to a second device IP interface of the network segment, and a media access control (MAC) address of the second device, and establish a mapping relationship between the IP address and the MAC address;

加入模块, 其设置为: 将所述映射关系加入所述网段下的第一设备 IP接 口对应的地址解析协议表目。  The module is added, and the mapping relationship is added to the address resolution protocol entry corresponding to the IP address of the first device under the network segment.

优选地, 本发明的地址解析协议表目的配置装置还包括:  Preferably, the apparatus for configuring an address resolution protocol of the present invention further includes:

判断模块, 其设置为: 判断是否存在与第一设备光纤连接的第二设备; 以及  a judging module, configured to: determine whether there is a second device connected to the first device fiber;

建立模块, 其设置为: 当不存在与第一设备光纤连接的第二设备时, 建 立第一设备与第二设备的光纤连接。  And establishing a module, configured to: establish a fiber connection between the first device and the second device when there is no second device connected to the first device fiber.

优选地, 所述第一设备通过第一设备物理端口与第二设备对应的物理端 口光纤连接; 所述第一设备物理端口和第二设备对应的物理端口处于所述 VLAN下。  Preferably, the first device is connected to the physical port of the second device by the physical port of the first device; the physical port of the first device and the physical port corresponding to the second device are in the VLAN.

优选地, 所述第一设备包括: 一个或多个第一设备 IP接口; 每个第一设 备 IP接口对应一个地址解析协议表目。  Preferably, the first device includes: one or more first device IP interfaces; each first device IP interface corresponds to an address resolution protocol entry.

优选地, 所述与第一设备光纤连接的第二设备为一个或多个; 每个第二 设备包括有一个或多个第二设备 IP接口。  Preferably, the second device connected to the first device fiber is one or more; each second device includes one or more second device IP interfaces.

本发明提供的地址解析协议表目的配置方法和装置, 通过建立第二设备 MAC, 与第一设备 IP接口处于同 VLAN且同网段的第二设备 IP接口对应的 IP地址间的映射关系,将该映射关系加入对应的第一设备 IP接口对应的地址 解析协议表目, 其配置速度快, 确保了地址解析协议表目中 IP地址与 MAC 地址映射关系的正确性, 因此, 保证了第一设备通过地址解析协议表目准确 查找目标第二设备的 MAC地址。 附图概述 The mapping method of the address resolution protocol table provided by the present invention, by establishing the second device MAC, is mapped to the IP address corresponding to the IP address of the second device IP interface of the same device and the IP address of the second device on the same network segment. The mapping relationship is added to the address resolution protocol entry corresponding to the corresponding IP address of the first device, and the configuration speed is fast, which ensures the correctness of the mapping relationship between the IP address and the MAC address in the address resolution protocol entry, thereby ensuring the first device. The address resolution protocol entry is used to accurately find the MAC address of the target second device. BRIEF abstract

图 1是本发明的地址解析协议表目的配置方法一实施例的流程图; 图 2是本发明的地址解析协议表目的配置方法另一实施例的流程图; 图 3是本发明的地址解析协议表目的配置装置一实施例结构示意图; 图 4 是本发明的地址解析协议表目的配置装置另一实施例的结构示意 图;  1 is a flowchart of an embodiment of a method for configuring an address resolution protocol of the present invention; FIG. 2 is a flowchart of another embodiment of a method for configuring an address resolution protocol of the present invention; and FIG. 3 is an address resolution protocol of the present invention. FIG. 4 is a schematic structural diagram of another embodiment of an apparatus for configuring an address resolution protocol according to the present invention; FIG.

图 5是本发明的涉及的传送多协议标签交换(T-MPLS )网络系统的结构 示意图。  Figure 5 is a block diagram showing the structure of a Transport Multi-Protocol Label Switching (T-MPLS) network system according to the present invention.

本发明目的的实现、 功能特点及优点将结合实施例, 参照附图做进一步 说明。 本发明的较佳实施方式 The implementation, functional features, and advantages of the present invention will be further described with reference to the accompanying drawings. Preferred embodiment of the invention

应当理解, 此处所描述的具体实施例仅仅用以解释本发明, 并不用于限 定本发明。  It is understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.

参见图 1 , 提出本发明的地址解析协议表目的配置方法实施例, 其包括: 步骤 S101、 查询与第一设备光纤连接的第二设备对应的物理端口所在虚 拟局域网 (V LAN ) 下的第一设备 IP接口和第二设备 IP接口;  Referring to FIG. 1 , an embodiment of a method for configuring an address resolution protocol table of the present invention is provided. The method includes: Step S101: Query a first virtual local area network (V LAN ) corresponding to a physical port corresponding to a second device connected to the first device fiber. Device IP interface and second device IP interface;

步骤 S102、 从所述 VLAN下查询在同一网段下的第一设备 IP接口和第 二设备 IP接口;  Step S102: Query, from the VLAN, the first device IP interface and the second device IP interface in the same network segment;

步骤 S103、 获取所述网段下的第二设备 IP接口对应的 IP地址和第二设 备的介质访问控制( MAC )地址, 并建立所述 IP地址与 MAC地址的映射关 系;  Step S103: Obtain an IP address corresponding to the second device IP interface of the network segment and a media access control (MAC) address of the second device, and establish a mapping relationship between the IP address and the MAC address.

步骤 S104、将所述映射关系加入所述网段下的第一设备 IP接口对应的地 址解析协议表目。  Step S104: Add the mapping relationship to an address resolution protocol entry corresponding to the IP address of the first device under the network segment.

上述第二设备的 MAC地址为从 T-MPLS网络系统中的数据库中获取的, 该数据库中记录有所述 T-MPLS网络系统中所有网元设备的 MAC地址。 其 中,每个网元设备的 MAC地址是该网元设备的机架 MAC地址与相应的偏移 值之和。 The MAC address of the second device is obtained from a database in the T-MPLS network system. The MAC address of all network element devices in the T-MPLS network system is recorded in the database. The MAC address of each network element device is the sum of the rack MAC address of the network element device and the corresponding offset value.

进一步地, 参见图 2, 提出本发明的地址解析协议表目的配置方法另一 实施例, 其包括:  Further, referring to FIG. 2, another embodiment of the method for configuring an address resolution protocol table of the present invention is provided, which includes:

步骤 S201、 判断是否存在与第一设备光纤连接的第二设备;  Step S201, determining whether there is a second device connected to the first device fiber;

步骤 S202、 若不存在, 则建立第一设备与第二设备的光纤连接; 步骤 S203、 查询与第一设备光纤连接的第二设备对应的物理端口所在虚 拟局域网 (V LAN ) 下的第一设备 IP接口和第二设备 IP接口;  Step S202, if not, establishing a fiber connection between the first device and the second device; Step S203: Querying a first device in a virtual local area network (VLAN) where the physical port corresponding to the second device connected to the first device fiber is located IP interface and second device IP interface;

步骤 S204、 从所述 VLAN下查询在同一网段下的第一设备 IP接口和第 二设备 IP接口;  Step S204: Query, from the VLAN, the first device IP interface and the second device IP interface in the same network segment;

步骤 S205、 获取所述网段下的第二设备 IP接口对应的 IP地址和第二设 备的介质访问控制( MAC )地址, 并建立所述 IP地址与 MAC地址的映射关 系;  Step S205: Obtain an IP address corresponding to the IP address of the second device under the network segment and a Media Access Control (MAC) address of the second device, and establish a mapping relationship between the IP address and the MAC address.

步骤 S206、将所述映射关系加入所述网段下的第一设备 IP接口对应的地 址解析协议表目。  Step S206: Add the mapping relationship to an address resolution protocol entry corresponding to the IP address of the first device under the network segment.

其中, 本实施例的步骤 S203至 S206与上一实施例的步骤 S101至 S104 一致, 在此不再赘述。  The steps S203 to S206 of the embodiment are the same as the steps S101 to S104 of the previous embodiment, and details are not described herein again.

上述步骤 S201中判断是否存在与第一设备光纤连接的第二设备,是根据 T-MPLS 网络系统数据库中获取的有关第一设备拓朴连接, 若第一设备的拓 朴连接为空, 则表明不存在与第一设备光纤连接的第二设备。  In the above step S201, it is determined whether there is a second device connected to the first device fiber, which is based on the first device topology connection obtained in the T-MPLS network system database, and if the topology connection of the first device is empty, There is no second device connected to the first device fiber.

进一步地, 上述实施例中, 所述第一设备通过第一设备物理端口与第二 设备对应的物理端口光纤连接; 所述第一设备物理端口和第二设备对应的物 理端口处于所述 VLAN下。  Further, in the above embodiment, the first device is connected to the physical port of the first device through the physical port of the first device; the physical port of the first device and the physical port corresponding to the second device are in the VLAN. .

上述在所述 VLAN下且在同一网段下的第一设备 IP接口和第二设备 IP 接口的信息可以记录在设定的表里。  The information about the first device IP interface and the second device IP interface under the VLAN and under the same network segment may be recorded in a set table.

进一步地, 上述实施例中, 所述第一设备包括: 一个或多个第一设备 IP 接口; 每个第一设备 IP接口对应一个地址解析协议表目。 进一步地, 上述实施例中, 所述与第一设备光纤连接的第二设备为一个 或多个; 每个第二设备包括有一个或多个第二设备 IP接口。 Further, in the above embodiment, the first device includes: one or more first device IP interfaces; each first device IP interface corresponds to an address resolution protocol entry. Further, in the above embodiment, the second device connected to the first device fiber is one or more; each second device includes one or more second device IP interfaces.

上述第二设备若包括多个不同的第二设备, 则不同的第二设备对应的 IP 接口不同, 对应的 MAC地址不同。  If the second device includes multiple different second devices, the different second devices have different IP interfaces, and the corresponding MAC addresses are different.

若所述 VLAN下且在同一网段下的第二设备包括第二设备 1、 2、 3、 4, 每个第二设备包括一个第二设备 IP接口。 其中, 第二设备 1的 IP接口对应 的 IP地址为 a, 第二设备 2的 IP接口对应的 IP地址为 b, 第二设备 3的 IP 接口对应的 IP地址为 c , 第二设备 4的 IP接口对应的 IP地址为 d; 第二设备 1的 MAC地址为 k,第二设备 2的 MAC地址为 w,第二设备 3的 MAC地址 为 X, 第二设备 4的 MAC地址为 y。  If the second device in the VLAN and in the same network segment includes the second device 1, 2, 3, 4, each second device includes a second device IP interface. The IP address corresponding to the IP interface of the second device 1 is a, the IP address corresponding to the IP interface of the second device 2 is b, and the IP address corresponding to the IP interface of the second device 3 is c, and the IP address of the second device 4 The IP address corresponding to the interface is d; the MAC address of the second device 1 is k, the MAC address of the second device 2 is w, the MAC address of the second device 3 is X, and the MAC address of the second device 4 is y.

则 IP地址与 MAC地址映射关系①为: IP地址 a与 MAC地址 k对应; IP地址 b与 MAC地址 w对应; IP地址 c与 MAC地址 x对应; IP地址 d与 MAC地址 y对应。  The IP address and MAC address mapping relationship 1 is: IP address a corresponds to MAC address k; IP address b corresponds to MAC address w; IP address c corresponds to MAC address x; IP address d corresponds to MAC address y.

若某一第二设备包括多个第二设备 IP接口, 如第二设备 1 包括两个 IP 接口,其中一个 IP接口对应的 IP地址为 al , 另一个 IP接口对应的 IP地址为 a2; 第二设备 3包括两个 IP接口, 其中一个 IP接口对应的 IP地址为 cl , 另 一个 IP接口对应的 IP地址为 c2。  If a second device includes multiple second device IP interfaces, for example, the second device 1 includes two IP interfaces, one of the IP interfaces corresponding to the IP address is al, and the other IP interface corresponding to the IP address is a2; The device 3 includes two IP interfaces. The IP address corresponding to one IP interface is cl, and the IP address corresponding to the other IP interface is c2.

则 IP地址与 MAC地址映射关系②为: IP地址 al与 MAC地址 k对应; IP地址 a2与 MAC地址 k对应; IP地址 b与 MAC地址 w对应; IP地址 cl 与 MAC地址 X对应; IP地址 c2与 MAC地址 x对应; IP地址 d与 MAC地 址 y对应; 依次类推。  The IP address and MAC address mapping relationship 2 is: IP address a corresponds to MAC address k; IP address a2 corresponds to MAC address k; IP address b corresponds to MAC address w; IP address cl corresponds to MAC address X; IP address c2 Corresponding to the MAC address x; the IP address d corresponds to the MAC address y; and so on.

若 VLAN下且在同一网段下的第一设备 IP接口只有一个第一设备 IP接 口 I ,则将上述 IP地址与 MAC地址映射关系①或②加入上第一设备 IP接口 I对应的地址解析协议表目内。  If the IP address of the first device in the VLAN and the first device is only the first device IP interface I, the IP address and MAC address mapping relationship 1 or 2 is added to the address resolution protocol corresponding to the IP address I of the first device. Within the table.

若所述 VLAN下且在同一网段下的第一设备 IP接口包括多个,如包括第 一设备 IP接口 I和第一设备 IP接口 II , 则将上述 IP地址与 MAC地址映射 关系①或②,分别加入上第一设备 IP接口 I 、 II对应的地址解析协议表目内, 依次类推。 本实施例提供的地址解析协议表目的配置方法, 通过建立第二设备If the first device IP interface in the VLAN and the same network segment includes multiple, including the first device IP interface I and the first device IP interface II, the mapping between the IP address and the MAC address is 1 or 2 , respectively, added to the address resolution protocol entry corresponding to the IP interface I and II of the first device, and so on. The method for configuring an address resolution protocol table provided by this embodiment, by establishing a second device

MAC, 与第一设备 IP接口处于同 VLAN且同网段的第二设备 IP接口对应的 IP地址间的映射关系,将该映射关系加入对应的第一设备 IP接口对应的地址 解析协议表目, 其配置速度快, 确保了地址解析协议表目中 IP地址与 MAC 地址映射关系的正确性, 因此, 保证了第一设备通过地址解析协议表目准确 查找目标第二设备的 MAC地址。 The MAC address, the mapping relationship between the IP address corresponding to the IP address of the second device and the IP address of the second device on the same network segment, and the mapping relationship is added to the address resolution protocol entry corresponding to the IP interface of the corresponding first device. The configuration is fast, and the correct mapping between the IP address and the MAC address in the address resolution protocol entry is ensured. Therefore, the first device can accurately find the MAC address of the target second device through the address resolution protocol entry.

另外, 本实施例提供的地址解析协议表目的配置方法, 相对于现有技术 的手工配置, 还具有配置速度快的优点。  In addition, the configuration method of the address resolution protocol table provided in this embodiment has the advantage of quick configuration speed compared to the manual configuration of the prior art.

参见图 3 , 提出本发明的地址解析协议表目的配置装置 10实施例, 其包 括: 第一查询模块 11、 第二查询模块 12、 获取模块 13、 加入模块 14。 其中, 第一查询模块 11 , 用于查询与第一设备光纤连接的第二设备对应的物理端口 所在虚拟局域网 (V LAN ) 下的第一设备 IP接口和第二设备 IP接口。 第二 查询模块 12, 用于从所述 VLAN下查询在同一网段下的第一设备 IP接口和 第二设备 IP接口。 获取模块 13 , 用于获取所述网段下的第二设备 IP接口对 应的 IP地址和第二设备的介质访问控制 ( MAC )地址, 并建立所述 IP地址 与 MAC地址的映射关系。 加入模块 14, 用于将所述映射关系加入所述网段 下的第一设备 IP接口对应的地址解析协议表目。 Referring to FIG. 3, an embodiment of the apparatus 10 for configuring an address resolution protocol of the present invention is provided. The method includes: a first query module 11, a second query module 12, an obtaining module 13, and an adding module 14. The first query module 11 is configured to query the first device IP interface and the second device IP interface under the virtual local area network (V LAN ) where the physical port corresponding to the second device connected to the first device fiber is located. The second query module 12 is configured to query, from the VLAN, the first device IP interface and the second device IP interface under the same network segment. The obtaining module 13 is configured to obtain an IP address corresponding to the second device IP interface of the network segment and a media access control (MAC) address of the second device, and establish a mapping relationship between the IP address and the MAC address. The adding module 14 is configured to add the mapping relationship to an address resolution protocol entry corresponding to the IP interface of the first device in the network segment.

上述第二设备的 MAC地址为从 T-MPLS网络系统中的数据库中获取的, 该数据库中记录有所述 T-MPLS网络系统中所有网元设备的 MAC地址。 其 中,每个网元设备的 MAC地址是该网元设备的机架 MAC地址与相应的偏移 值之和。  The MAC address of the second device is obtained from a database in the T-MPLS network system, and the MAC address of all the network element devices in the T-MPLS network system is recorded in the database. The MAC address of each network element device is the sum of the rack MAC address of the network element device and the corresponding offset value.

进一步地, 参见图 4, 提出本发明的地址解析协议表目的配置装置 20另 一实施例, 其包括: 判断模块 21、 建立模块 22、 第一查询模块 23、 第二查 询模块 24、 获取模块 25、 加入模块 26。 其中, 所述第一查询模块 23、 第二 查询模块 24、 获取模块 25、 加入模块 26分别与上述实施例中的相同名称的 模块功能一致, 在此不再赘述。 所述判断模块 21 , 用于判断是否存在与第一 设备光纤连接的第二设备。 建立模块 22, 用于当不存在与第一设备光纤连接 的第二设备时, 建立第一设备与第二设备的光纤连接。 其中, 上述判断是否存在与第一设备光纤连接的第二设备, 是根据Further, referring to FIG. 4, another embodiment of the address resolution protocol table configuration apparatus 20 of the present invention is provided, which includes: a determining module 21, an establishing module 22, a first querying module 23, a second querying module 24, and an obtaining module 25. , join module 26. The first query module 23, the second query module 24, the obtaining module 25, and the joining module 26 are respectively consistent with the functions of the modules of the same name in the foregoing embodiments, and details are not described herein again. The determining module 21 is configured to determine whether there is a second device connected to the optical fiber of the first device. The establishing module 22 is configured to establish a fiber connection between the first device and the second device when there is no second device connected to the first device fiber. Wherein, determining whether there is a second device connected to the optical fiber of the first device is based on

T-MPLS 网络系统数据库中获取的有关第一设备拓朴连接, 若第一设备的拓 朴连接为空, 则表明不存在与第一设备光纤连接的第二设备。 The first device topology connection obtained in the T-MPLS network system database, if the top connection of the first device is empty, it indicates that there is no second device connected to the first device fiber.

进一步地,上述地址解析协议表目的配置装置 20中的所述第一设备通过 第一设备物理端口与第二设备对应的物理端口光纤连接; 所述第一设备物理 端口和第二设备对应的物理端口处于所述 VLAN下。  Further, the first device in the configuration device 20 of the address resolution protocol table is connected to the physical port optical fiber corresponding to the second device by using the physical port of the first device; the physical port corresponding to the physical port of the first device and the second device The port is in the VLAN.

上述在所述 VLAN下且在同一网段下的第一设备 IP接口和第二设备 IP 接口的信息可以记录在设定的表里。  The information about the first device IP interface and the second device IP interface under the VLAN and under the same network segment may be recorded in a set table.

进一步地, 上述地址解析协议表目的配置装置 20 中的所述第一设备包 括: 一个或多个第一设备 IP接口; 每个第一设备 IP接口对应一个地址解析 协议表目。  Further, the first device in the configuration device 20 of the address resolution protocol table includes: one or more first device IP interfaces; each first device IP interface corresponds to an address resolution protocol entry.

进一步地,上述地址解析协议表目的配置装置 20中的所述与第一设备光 纤连接的第二设备为一个或多个; 每个第二设备包括有一个或多个第二设备 IP接口。  Further, the second device that is optically connected to the first device in the configuration device 20 of the address resolution protocol table is one or more; each second device includes one or more second device IP interfaces.

上述第二设备若包括多个不同的第二设备, 则不同的第二设备对应的 IP 接口不同, 对应的 MAC地址不同。  If the second device includes multiple different second devices, the different second devices have different IP interfaces, and the corresponding MAC addresses are different.

若所述 VLAN下且在同一网段下的第二设备包括第二设备 1、 2、 3、 4, 每个第二设备包括一个第二设备 IP接口。 其中, 第二设备 1的 IP接口对应 的 IP地址为 a, 第二设备 2的 IP接口对应的 IP地址为 b, 第二设备 3的 IP 接口对应的 IP地址为 c , 第二设备 4的 IP接口对应的 IP地址为 d; 第二设备 1的 MAC地址为 k,第二设备 2的 MAC地址为 w,第二设备 3的 MAC地址 为 X, 第二设备 4的 MAC地址为 y。  If the second device in the VLAN and in the same network segment includes the second device 1, 2, 3, 4, each second device includes a second device IP interface. The IP address corresponding to the IP interface of the second device 1 is a, the IP address corresponding to the IP interface of the second device 2 is b, and the IP address corresponding to the IP interface of the second device 3 is c, and the IP address of the second device 4 The IP address corresponding to the interface is d; the MAC address of the second device 1 is k, the MAC address of the second device 2 is w, the MAC address of the second device 3 is X, and the MAC address of the second device 4 is y.

则 IP地址与 MAC地址映射关系①为: IP地址 a与 MAC地址 k对应; IP地址 b与 MAC地址 w对应; IP地址 c与 MAC地址 x对应; IP地址 d与 MAC地址 y对应。  The IP address and MAC address mapping relationship 1 is: IP address a corresponds to MAC address k; IP address b corresponds to MAC address w; IP address c corresponds to MAC address x; IP address d corresponds to MAC address y.

若某一第二设备包括多个第二设备 IP接口, 如第二设备 1 包括两个 IP 接口,其中一个 IP接口对应的 IP地址为 al , 另一个 IP接口对应的 IP地址为 a2; 第二设备 3包括两个 IP接口, 其中一个 IP接口对应的 IP地址为 cl , 另 一个 IP接口对应的 IP地址为 c2。 If a second device includes multiple second device IP interfaces, for example, the second device 1 includes two IP interfaces, one of which corresponds to an IP address of a l and the other IP interface has an IP address of a2; The second device 3 includes two IP interfaces, and one of the IP interfaces corresponds to an IP address of cl. The IP address corresponding to an IP interface is c2.

则 IP地址与 MAC地址映射关系②为: IP地址 al与 MAC地址 k对应; IP地址 a2与 MAC地址 k对应; IP地址 b与 MAC地址 w对应; IP地址 cl 与 MAC地址 X对应; IP地址 c2与 MAC地址 x对应; IP地址 d与 MAC地 址 y对应; 依次类推。  The IP address and MAC address mapping relationship 2 is: IP address a corresponds to MAC address k; IP address a2 corresponds to MAC address k; IP address b corresponds to MAC address w; IP address cl corresponds to MAC address X; IP address c2 Corresponding to the MAC address x; the IP address d corresponds to the MAC address y; and so on.

若 VLAN下且在同一网段下的第一设备 IP接口只有一个第一设备 IP接 口 I ,则将上述 IP地址与 MAC地址映射关系①或②加入上第一设备 IP接口 I对应的地址解析协议表目内。  If the IP address of the first device in the VLAN and the first device is only the first device IP interface I, the IP address and MAC address mapping relationship 1 or 2 is added to the address resolution protocol corresponding to the IP address I of the first device. Within the table.

若所述 VLAN下且在同一网段下的第一设备 IP接口包括多个,如包括第 一设备 IP接口 I和第一设备 IP接口 II , 则将上述 IP地址与 MAC地址映射 关系①或②,分别加入上第一设备 IP接口 I 、 II对应的地址解析协议表目内, 依次类推。  If the first device IP interface in the VLAN and the same network segment includes multiple, including the first device IP interface I and the first device IP interface II, the mapping between the IP address and the MAC address is 1 or 2 , respectively, added to the address resolution protocol entry corresponding to the IP interface I and II of the first device, and so on.

本实施例的地址解析协议表目的配置装置, 通过建立第二设备 MAC、 与 第一设备 IP接口处于同 VLAN且同网段的第二设备 IP接口对应的 IP地址间 的映射关系, 将该映射关系加入对应的第一设备 IP接口对应的地址解析协议 表目, 其配置速度快, 确保了地址解析协议表目中 IP地址与 MAC地址映射 关系的正确性, 因此, 保证了第一设备通过地址解析协议表目准确查找目标 第二设备的 MAC地址。  The mapping device of the address resolution protocol of the embodiment is configured by establishing a mapping relationship between the second device MAC and the IP address corresponding to the IP address of the second device and the second device IP interface of the first device. The relationship is added to the corresponding address resolution protocol entry corresponding to the IP address of the first device. The configuration is fast, ensuring the correctness of the mapping between the IP address and the MAC address in the address resolution protocol entry. Therefore, the first device passes the address. The resolution protocol entry accurately finds the MAC address of the target second device.

另外, 本实施例提供的地址解析协议表目的配置装置, 相对于现有技术 的手工配置, 还具有配置速度快的优点。  In addition, the device for configuring the address resolution protocol table provided in this embodiment has the advantage of quick configuration speed compared to the manual configuration of the prior art.

本实施例提供的地址解析协议表目的配置装置可以单独设置,也可以设 置在第一设备中。  The device for configuring the address resolution protocol table provided in this embodiment may be separately set or may be set in the first device.

以上实施例中所述的第一设备和第二设备为 T-MPLS网络系统中的网元 设备, 以下是本发明的一个具体实例: The first device and the second device described in the foregoing embodiments are network element devices in the T-MPLS network system. The following is a specific example of the present invention:

图 5是 T-MPLS网络系统的结构示意图, 其包括网元设备 NE1、 NE2、 NE3、 NE4 , 所述 NE1分别与 NE2、 NE3和 NE4连接。  5 is a schematic structural diagram of a T-MPLS network system, which includes network element devices NE1, NE2, NE3, and NE4, and the NE1 is connected to NE2, NE3, and NE4, respectively.

其中, NE1与 NE2的连接, 是通过 NE1的物理端口 Gei— 1/9与 NE2的 物理端口 Gei— 1/10光纤连接实现。 其中, NE1的 Gei— 1/9处于 VLAN2中, NE1在 VLAN2中 IP接口对应的 IP地址为 192.168.100.1 ; NE2的 Gei— 1/10 处于 VLAN2中, NE2在 VLAN2中 IP接口对应的 IP地址为 192.168.100.2。 The connection between NE1 and NE2 is through the physical ports of NE1, Gei-1/9 and NE2. Physical port Gei-1/10 fiber connection implementation. Among them, the Gei-1/9 of NE1 is in VLAN 2, the IP address corresponding to the IP interface of NE1 in VLAN 2 is 192.168.100.1, the Gei-1/10 of NE2 is in VLAN 2, and the IP address corresponding to the IP interface of NE2 in VLAN 2 is 192.168.100.2.

NE1与 NE3的连接, 是通过 NE1的物理端口 Gei— 1/10与 NE2的物理端 口 Gei— 1/10光纤连接实现。 其中, NE1的 Gei— 1/10处于 VLAN3中, NE1在 VLAN3中 IP接口对应 IP地址为 192.168.200.1 ; NE3的 Gei— 1/10处于 VLAN4 中, NE3在 VLAN4中 IP接口对应的 IP地址为 192.168.200.2。  The connection between NE1 and NE3 is realized by the physical port Gei-1/10 of NE1 and the Gei-1/10 fiber connection of the physical port of NE2. Among them, the Gei-1/10 of NE1 is in VLAN3, the IP address of the IP interface of NE1 in VLAN3 is 192.168.200.1, the Gei-1/10 of NE3 is in VLAN 4, and the IP address corresponding to the IP interface of NE3 in VLAN 4 is 192.168. .200.2.

NE1与 NE4的连接, 是通过 NE1的物理端口 Gei— 1/1与 NE2的物理端 口 Gei— 1/10光纤连接实现。 其中, NE1的 Gei— 1/1处于 VLAN2中, NE1在 VLAN2 中 IP接口对应的 IP地址为 192.168.200.1 ; NE4 的 Gei— 1/10处于 VLAN2中, NE4在 VLAN2中 IP接口对应的 IP地址为 192.168.100.3。  The connection between NE1 and NE4 is realized by the physical port Gei-1/1 of NE1 and the physical port Gei-1/10 fiber of NE2. Among them, the Gei-1/1 of NE1 is in VLAN 2, the IP address corresponding to the IP interface of NE1 in VLAN 2 is 192.168.200.1, the Gei-1/10 of NE4 is in VLAN 2, and the IP address corresponding to the IP interface of NE4 in VLAN 2 is 192.168.100.3.

由上可知, 在处于 VLAN2下的 IP接口包括: NE1在 VLAN2中 IP地 192.168.100.1对应的 IP接口和 IP地址 192.168.200.1对应的 IP接口、 NE2在 VLAN2中 IP地址 192.168.100.2对应的 IP接口、 NE4在 VLAN2中 IP地址 192.168.100.3对应的 IP接口。  As shown in the above, the IP interface in the VLAN 2 includes: the IP interface corresponding to the IP address 192.168.100.1 of the IP1 in the VLAN 2 and the IP interface corresponding to the IP address 192.168.200.1, and the IP interface corresponding to the IP address 192.168.100.2 of the NE2 in the VLAN 2. The IP interface corresponding to the IP address 192.168.100.3 of the NE4 in VLAN 2.

上述处于 VLAN2下的 IP接口中, 处于同一网段的 IP接口包括: NE1在 VLAN2中 IP地 192.168.100.1对应的 IP接口、 NE2在 VLAN2中 IP地址 192.168.100.2对应的 IP接口、 NE4在 VLAN2中 IP地址 192.168.100.3对应 的 IP接口。  The IP interfaces on the same network segment of the IP interface in VLAN 2 include: IP interface corresponding to IP address 192.168.100.1 of NE1 in VLAN 2, IP interface corresponding to IP address 192.168.100.2 of NE2 in VLAN 2, and VLAN 4 of NE4 in VLAN 2. The IP address corresponding to the IP address 192.168.100.3.

因此, 将 NE2的 IP地址 192.168.100.2与 NE2的 MAC地址建立映射关 系, 并将该映射关系加入 NE1中 IP地址 192.168.100.1对应的 IP接口的地址 解析协议表目中。  Therefore, the IP address of 192.168.100.2 of NE2 is mapped to the MAC address of NE2, and the mapping relationship is added to the address resolution protocol of the IP interface corresponding to IP address 192.168.100.1 in NE1.

同时, 将 NE4的 IP地址 192.168.100.3与 NE4的 MAC地址建立映射关 系, 并将该映射关系加入 NE1中 IP地址 192.168.100.1对应的 IP接口的地址 解析协议表目中。  At the same time, the IP address of 192.168.100.3 of NE4 is mapped to the MAC address of NE4, and the mapping relationship is added to the address resolution protocol of the IP interface corresponding to IP address 192.168.100.1 in NE1.

尽管为示例目的, 已经公开了本发明的优选实施例, 本领域的技术人员 将意识到各种改进、 增加和取代也是可能的, 因此, 本发明的范围应当不限 于上述实施例。 Although the preferred embodiments of the present invention have been disclosed for purposes of illustration, those skilled in the art will recognize that various modifications, additions and substitutions are possible. In the above embodiment.

本领域普通技术人员可以理解上述方法中的全部或部分步骤可通过程序 来指令相关硬件完成, 所述程序可以存储于计算机可读存储介质中, 如只读 存储器、 磁盘或光盘等。 可选地, 上述实施例的全部或部分步骤也可以使用 一个或多个集成电路来实现。 相应地, 上述实施例中的各模块 /单元可以釆用 硬件的形式实现, 也可以釆用软件功能模块的形式实现。 本发明不限制于任 何特定形式的硬件和软件的结合。  One of ordinary skill in the art will appreciate that all or a portion of the above steps may be accomplished by a program instructing the associated hardware, such as a read-only memory, a magnetic disk, or an optical disk. Alternatively, all or part of the steps of the above embodiments may also be implemented using one or more integrated circuits. Correspondingly, each module/unit in the above embodiment may be implemented in the form of hardware or in the form of a software function module. The invention is not limited to any specific form of combination of hardware and software.

工业实用性 Industrial applicability

本发明提供的地址解析协议表目的配置方法和装置, 通过建立第二设备 The method and device for configuring an address resolution protocol table provided by the present invention, by establishing a second device

MAC, 与第一设备 IP接口处于同 VLAN且同网段的第二设备 IP接口对应的 IP地址间的映射关系,将该映射关系加入对应的第一设备 IP接口对应的地址 解析协议表目, 其配置速度快, 确保了地址解析协议表目中 IP地址与 MAC 地址映射关系的正确性, 因此, 保证了第一设备通过地址解析协议表目准确 查找目标第二设备的 MAC地址。 The MAC address, the mapping relationship between the IP address corresponding to the IP address of the second device and the IP address of the second device on the same network segment, and the mapping relationship is added to the address resolution protocol entry corresponding to the IP interface of the corresponding first device. The configuration is fast, and the correct mapping between the IP address and the MAC address in the address resolution protocol entry is ensured. Therefore, the first device can accurately find the MAC address of the target second device through the address resolution protocol entry.

Claims

权 利 要 求 书 Claim 1、 一种地址解析协议表目的配置方法, 其包括: A method for configuring an address resolution protocol entry, which includes: 查询与第一设备光纤连接的第二设备对应的物理端口所在虚拟局域网 ( VLAN ) 下的第一设备 IP接口和第二设备 IP接口;  Querying a first device IP interface and a second device IP interface in a virtual local area network (VLAN) where the physical port corresponding to the second device connected to the first device fiber is located; 从所述 VLAN下查询在同一网段下的第一设备 IP接口和第二设备 IP接 口; 获取所述网段下的第二设备 IP接口对应的 IP地址和第二设备的介质访 问控制 ( MAC )地址, 并建立所述 IP地址与 MAC地址的映射关系; 以及 将所述映射关系加入所述网段下的第一设备 IP接口对应的地址解析协议 表目。  Querying the first device IP interface and the second device IP interface in the same network segment from the VLAN; obtaining the IP address corresponding to the second device IP interface and the media access control of the second device (MAC) The address, and the mapping relationship between the IP address and the MAC address is established; and the mapping relationship is added to the address resolution protocol entry corresponding to the IP interface of the first device under the network segment. 2、 根据权利要求 1所述的地址解析协议表目的配置方法, 其中, 所述查询与第一设备光纤连接的第二设备对应的物理端口所在 VLAN下 的第一设备 IP接口和第二设备 IP接口之前, 所述方法还包括: The method for configuring an address resolution protocol table according to claim 1, wherein the querying the first device IP interface and the second device IP in the VLAN where the physical port corresponding to the second device connected to the first device fiber is located Before the interface, the method further includes: 判断是否存在与第一设备光纤连接的第二设备;  Determining whether there is a second device connected to the first device fiber; 若不存在, 则建立第一设备与第二设备的光纤连接。  If not, establish a fiber connection between the first device and the second device. 3、 根据权利要求 1或 2所述的地址解析协议表目的配置方法, 其中, 所述第一设备通过第一设备物理端口与第二设备对应的物理端口光纤连 接; 所述第一设备物理端口和第二设备对应的物理端口处于所述 VLAN下。 The method for configuring an address resolution protocol table according to claim 1 or 2, wherein the first device is connected to a physical port optical fiber corresponding to the second device by using the first device physical port; the first device physical port The physical port corresponding to the second device is in the VLAN. 4、 根据权利要求 3所述的地址解析协议表目的配置方法, 其中, 所述第一设备包括: 一个或多个第一设备 IP接口; 每个第一设备 IP接 口对应一个地址解析协议表目。 The method for configuring an address resolution protocol table according to claim 3, wherein the first device comprises: one or more first device IP interfaces; each first device IP interface corresponds to an address resolution protocol entry . 5、 根据权利要求 4所述的地址解析协议表目的配置方法, 其中, 所述与第一设备光纤连接的第二设备为一个或多个; 每个第二设备包括 有一个或多个第二设备 IP接口。 The method for configuring an address resolution protocol table according to claim 4, wherein the second device connected to the first device fiber is one or more; each second device includes one or more second devices. Device IP interface. 6、 一种地址解析协议表目的配置装置, 其包括: 第一查询模块, 其设置为: 查询与第一设备光纤连接的第二设备对应的 物理端口所在虚拟局域网 (V LAN ) 下的第一设备 IP接口和第二设备 IP接 口; 第二查询模块, 其设置为: 从所述 VLAN下查询在同一网段下的第一设 备 IP接口和第二设备 IP接口; 6. An apparatus for configuring an address resolution protocol entry, comprising: a first query module, configured to: query a first device IP interface and a second device IP interface under a virtual local area network (V LAN) where the physical port corresponding to the second device connected to the first device fiber is located; The setting is: querying the first device IP interface and the second device IP interface in the same network segment from the VLAN; 获取模块, 其设置为: 获取所述网段下的第二设备 IP接口对应的 IP地 址和第二设备的介质访问控制(MAC )地址, 并建立所述 IP地址与 MAC地 址的映射关系; 以及  An acquiring module, configured to: obtain an IP address corresponding to a second device IP interface of the network segment, and a media access control (MAC) address of the second device, and establish a mapping relationship between the IP address and the MAC address; 加入模块, 其设置为: 将所述映射关系加入所述网段下的第一设备 IP接 口对应的地址解析协议表目。  The module is added, and the mapping relationship is added to the address resolution protocol entry corresponding to the IP address of the first device under the network segment. 7、根据权利要求 6所述的地址解析协议表目的配置装置, 所述装置还包 括: The device for configuring an address resolution protocol table according to claim 6, wherein the device further comprises: 判断模块, 其设置为: 判断是否存在与第一设备光纤连接的第二设备; 以及  a judging module, configured to: determine whether there is a second device connected to the first device fiber; 建立模块, 其设置为: 当不存在与第一设备光纤连接的第二设备时, 建 立第一设备与第二设备的光纤连接。  And establishing a module, configured to: establish a fiber connection between the first device and the second device when there is no second device connected to the first device fiber. 8、 根据权利要求 6或 7所述的地址解析协议表目的配置装置, 其中, 所述第一设备通过第一设备物理端口与第二设备对应的物理端口光纤连 接; 所述第一设备物理端口和第二设备对应的物理端口处于所述 VLAN下。 The apparatus for configuring an address resolution protocol table according to claim 6 or 7, wherein the first device is connected to a physical port optical fiber corresponding to the second device by using the first device physical port; the first device physical port The physical port corresponding to the second device is in the VLAN. 9、 根据权利要求 8所述的地址解析协议表目的配置装置, 其中, 所述第一设备包括: 一个或多个第一设备 IP接口; 每个第一设备 IP接 口对应一个地址解析协议表目。 The device for configuring an address resolution protocol table according to claim 8, wherein the first device comprises: one or more first device IP interfaces; each first device IP interface corresponds to an address resolution protocol entry . 10、 根据权利要求 9所述的地址解析协议表目的配置装置, 其中, 所述与第一设备光纤连接的第二设备为一个或多个; 每个第二设备包括 有一个或多个第二设备 IP接口。 The apparatus for configuring an address resolution protocol table according to claim 9, wherein the second device connected to the first device fiber is one or more; each second device includes one or more second devices. Device IP interface.
PCT/CN2010/080025 2010-09-20 2010-12-20 Method and apparatus for configuring address resolution protocol entry Ceased WO2012037762A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201010288175.9 2010-09-20
CN201010288175.9A CN101945110B (en) 2010-09-20 2010-09-20 Configuration method and device of address resolution protocol entry

Publications (1)

Publication Number Publication Date
WO2012037762A1 true WO2012037762A1 (en) 2012-03-29

Family

ID=43436878

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2010/080025 Ceased WO2012037762A1 (en) 2010-09-20 2010-12-20 Method and apparatus for configuring address resolution protocol entry

Country Status (2)

Country Link
CN (1) CN101945110B (en)
WO (1) WO2012037762A1 (en)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102790692B (en) * 2011-05-19 2015-05-06 中兴通讯股份有限公司 Method for calculating network element interface and web master
CN102325197B (en) * 2011-05-23 2014-03-12 杭州华三通信技术有限公司 Method for communication between intranet equipment and internet equipment and network address transformation equipment
CN103701940B (en) * 2012-09-27 2018-02-27 深圳市中兴通讯技术服务有限责任公司 Address resolution protocol collocation method and device under a kind of NMS
CN102946351B (en) * 2012-10-23 2016-06-08 杭州华三通信技术有限公司 A kind of data transmission method and system
CN104753697B (en) * 2013-12-26 2019-05-24 华为技术有限公司 A method, device and system for controlling automatic deployment of network devices
CN108965135B (en) * 2018-05-25 2021-05-04 西安云维智联科技有限公司 Address self-learning method for Ethernet and fiber channel conversion equipment

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1411210A (en) * 2002-03-08 2003-04-16 华为技术有限公司 Method of acting address analytic protocol Ethernet Switch in application
CN101098292A (en) * 2006-06-29 2008-01-02 中兴通讯股份有限公司 Method for reducing user address resolution protocol broadcast on access equipment
CN101262505A (en) * 2008-04-22 2008-09-10 杭州华三通信技术有限公司 A method, system and device for establishing ARP table items
CN101572930A (en) * 2008-04-28 2009-11-04 鸿富锦精密工业(深圳)有限公司 System and method for stable connection of unauthorized mobile access mobile phone

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100477609C (en) * 2003-07-11 2009-04-08 华为技术有限公司 Method for implementing dedicated network access
CN100454825C (en) * 2003-07-19 2009-01-21 华为技术有限公司 Control Method of Static User Access Network Based on MAC Address

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1411210A (en) * 2002-03-08 2003-04-16 华为技术有限公司 Method of acting address analytic protocol Ethernet Switch in application
CN101098292A (en) * 2006-06-29 2008-01-02 中兴通讯股份有限公司 Method for reducing user address resolution protocol broadcast on access equipment
CN101262505A (en) * 2008-04-22 2008-09-10 杭州华三通信技术有限公司 A method, system and device for establishing ARP table items
CN101572930A (en) * 2008-04-28 2009-11-04 鸿富锦精密工业(深圳)有限公司 System and method for stable connection of unauthorized mobile access mobile phone

Also Published As

Publication number Publication date
CN101945110A (en) 2011-01-12
CN101945110B (en) 2014-08-20

Similar Documents

Publication Publication Date Title
CN102447573B (en) Network system and management method of virtual network
CN105991334B (en) A kind of network topology self-discovery method and device
US10574570B2 (en) Communication processing method and apparatus
KR20120060810A (en) Techniques for routing data between network areas
WO2012037762A1 (en) Method and apparatus for configuring address resolution protocol entry
WO2013082983A1 (en) Method and apparatus for data transmission between openflow network domains
US20240323115A1 (en) Loop Avoidance Communications Method, Device, and System
JP2005080291A (en) System and method for detecting BGP router topology
WO2016082588A1 (en) Link connectivity checking method and apparatus
CN109474495B (en) Tunnel detection method and device
WO2011011933A1 (en) Method and system for realizing network topology discovery
US20200287784A1 (en) Priority based selection of time services
CN102656847A (en) Method and device for determining forwarding rule for data packets
WO2010060304A1 (en) Data communication system, router, data transmission and mobility management method
WO2012155430A1 (en) Method and network management for calculating network element interfaces
US10171306B2 (en) Automatic discovery and provisioning of multi-chassis etherchannel peers
WO2024108493A1 (en) Virtual and real combined dynamic traffic scheduling method and apparatus based on sdn and ndn
CN104767681B (en) A kind of data center network method for routing for tolerating error connection line
CN100486210C (en) Topology finding method and system in SIP network
CN103391232B (en) Virtual machine connection method in cloud system
CN115883456B (en) A method, device and equipment, medium and product for identifying uplink egress
CN115865844A (en) Virtual-real combined dynamic flow scheduling method and device based on SDN and NDN
WO2019001101A1 (en) Routing path analysis method and device
WO2016188222A1 (en) Service message forwarding method and apparatus, and communication system
US20230421499A1 (en) Packet transmission method and apparatus

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 10857475

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 10857475

Country of ref document: EP

Kind code of ref document: A1