摘要 |
A method and device for establishing a router neighbor are provided by the embodiments of the present invention. The method includes: obtaining the first discovery protocol Hello message sent from the neighbor router, wherein the first Hello message carries the identification information and the priority information of the neighbor router (101); according to the priority information of the neighbor router, and/or the priority information of the local end router, and/or whether the identification information of the neighbor router is the identification information of the opposite end device of the virtual link configured by the local end router, determining whether to add the related information of the neighbor router into the neighbor list of the local end router (102). The embodiments of the invention ensure that a small device can establish the neighbor relationship with a Designated Router (DR) and a Back Designated Router (BDR) in a network, and ensure the normal Open Shortest Path First (OSPF) function of the small device. |