CN101945036B - Judging method for failure of main router of virtual route redundancy protocol and router - Google Patents

Judging method for failure of main router of virtual route redundancy protocol and router Download PDF

Info

Publication number
CN101945036B
CN101945036B CN2009101519537A CN200910151953A CN101945036B CN 101945036 B CN101945036 B CN 101945036B CN 2009101519537 A CN2009101519537 A CN 2009101519537A CN 200910151953 A CN200910151953 A CN 200910151953A CN 101945036 B CN101945036 B CN 101945036B
Authority
CN
China
Prior art keywords
router
active
vrrp
election contest
judging
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.)
Expired - Fee Related
Application number
CN2009101519537A
Other languages
Chinese (zh)
Other versions
CN101945036A (en
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.)
Liu Delian
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
Priority to CN2009101519537A priority Critical patent/CN101945036B/en
Publication of CN101945036A publication Critical patent/CN101945036A/en
Application granted granted Critical
Publication of CN101945036B publication Critical patent/CN101945036B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention discloses a judging method for failure of a main router of a virtual route redundancy protocol and a router, which can shorten the time for judging the failure of the main router, thereby shortening the switching time and reducing the loss of traffic flow. The method of the invention comprises the following steps: switching and judging parameters are configured for each router, the switching and judging parameters comprise a statistical parameter N and a message threshold M, N and M are natural numbers, N is greater than or equal to M, and M is less than or equal to 3; each backup router computes the respective statistical cycle T by the following expression: T is equal to N multiplies announcing time cycle plus slope time according to the statistical parameter; and each backup router counts the number of times that the VRRP announcing message is not received in the respective statistical cycle, and when the accumulated number of times that the VRRP announcing message is not received in the statistical cycle achieves the message threshold M, main and backup election is originated.

Description

The determination methods of failure of main router of virtual route redundancy protocol and a kind of router
Technical field
The present invention relates to the data communication field, be specifically related to determination methods and a kind of router that Virtual Router Redundacy Protocol VRRP (VirtualRouter Redundancy Protocol) active router lost efficacy.
Background technology
In the network based on ICP/IP protocol, in order to guarantee the communication between the equipment that direct physical not connects, must specified circuit by.At present specified circuit commonly used by method have two kinds: a kind of is by Routing Protocol (such as interior routing protocol RIP and OSPF) dynamic learning; Another kind is static configuration.Be unpractical at each terminal operation state Routing Protocol, the client operating system platform is not supported dynamic routing protocol mostly, even support to be subject to the restriction of many problems such as administration overhead, the degree of convergence, fail safe yet.Therefore generally adopting terminal IP device static routing configuration, generally is to specify one or more default gateway (Default Gateway) to terminal equipment.The method of static routing has been simplified the complexity of network management and alleviated the communication overhead of terminal equipment, but it still has a shortcoming: if the router of gateway damages by default, all use this gateway must interrupt as the communication of down hop main frame.Even if configured a plurality of default gateways, as not restarting terminal equipment, can not switch to new gateway.Adopt Virtual Router Redundacy Protocol (Virtual Router Redundancy Protocol is called for short VRRP) can well avoid static defective of specifying gateway.
In the VRRP agreement, two groups of important concepts are arranged: VRRP router and virtual router, virtual router master and backup router.The VRRP router refers to move the router of VRRP, is physical entity, and virtual router refers to what the VRRP agreement created, is logical concept.The collaborative work of one group of VRRP router consists of a virtual router jointly.This virtual router externally shows as a router logic with unique fixed ip address and MAC Address.Be in the role that router in the same VRRP group has two kinds of mutual exclusions: virtual router master and backup router, there is and only has a router that is in the master control role in the VRRP group, can there be one or more to be in backup role's router.The VRRP agreement uses selection strategy to select one as master control from groups of routers, be responsible for processing ARP (Addree Require Protocol, the Address requests agreement) and transmit the IP packet, other router in the group is ready as the role of backup.When virtual router master breaks down for a certain reason, backup router can several seconds the time delay and upgrade to active router.Because this switching need not change IP address and MAC Address, therefore be transparent to the terminal user system.
The below manufactures the basic conception of VRRP agreement and working machine and briefly introduces:
Basic conception:
The VRRP group
The VRRP group refers to configure identical VRID (Virtual Router ID), and has a same virtual address, be operated in the set of router in the broadcast domain, general VRRP group is comprised of two or more router, and only have the VRPP of an equipment to be in master state in a VRRP group, other equipment all are to be in stand-by state.
The VRRP state:
DISABLE (closing) state: a certain VRRP group does not configure main virtual ip address, and initial configuration is in this state;
INITIAL (initially) state: main virtual ip address has been put in a certain VRRP assembly, but its interface quits work (Down) or do not have interface IP address.
MASTER (master) state: primary VRRP router, the router that is in this state has VRRP virtual ip address and Virtual MAC, and the response purpose is the request of virtual IP address and MAC, and timed sending VRRP protocol massages is given other VRRP equipment.
BACKUP (backup) state: backup VRRP router, the router under this state receives the VRRP message, if do not receive within a certain period of time the notification packet of main equipment, this state can become the MASTER state.
VRRP PRIORITY (priority), each VRRP router have the priority (1-255) of oneself, and carry out active and standby election contest by this priority, and what priority was high is host apparatus.Agreement regulation VRRP group default priority is 100.
ADVERTISE_TIME (notification time), the VRRP notification time, the VRRP group that is in master state need to send a notification packet a notification time in the cycle, and VRRP agreement regulation acquiescence notification time is 1 second.
MASTER_DOWN_TIME (master server out-of-service time), the VRRP that is in stand-by state organizes, if do not receive the message that priority ratio oneself is high in MASTER_DOWN_TIME, need to switch to master state to main frame.The computing formula of MASTER_DOWN_TIME is as follows:
SKEW_TIME=(255-PRIORITY)/255;
MASTER_DOWN_TIME=3*ADVERTISE_TIME+SKEW_TIME;
Wherein SKEW_TIME is the slope time of agreement regulation.
VRRP Track strategy, VRRP follows the tracks of Link State (interface UP/DOWN, route, BFD etc.), takes certain action policy according to Link State.
Propagate in a broadcast domain by protocol massages between the VRRP group, and carry out active and standby election contest by the height of priority, reach the purpose of standby redundancy.The double layer network that needs a connection below two VRRP routers is in the interface of VRRP router by configuration VRRP under the master state, to other VRRP router delivery protocol messages.The VRRP router is received the VRRP protocol massages of other router, by priority ratio, changes own residing state and campaigns for out active/standby gateway, and in-group priority is the highest serves as primary gateway, other as standby gateway.
The main multicast notification packet that relies on the primary route device between the host-standby communication of VRRP, standby router monitors the state of primary route device by notification packet, and keeps stand-by state.Each VRRP group of VRRP agreement regulation host apparatus need be sent out a notification packet in each announcement cycle, and stand-by equipment does not receive notification packet within continuous three announcement cycles, will become main equipment to oneself, and produces active and standby election contest.The router of winning in the election contest of equipment group sends VRRP group notification packet.Because general each announcement cycle is 1 second, continuous like this three announcement cycles are three seconds time.
Although the VRRP agreement can several seconds the time delay by backup router and upgrade to active router, under high bandwidth and multiple services application scenarios, may cause losing of service traffics, thereby affect user's business experience.Specifically, because backup router will just be initiated active and standby election contest announcement at 3 all after dates of announcement, default each announcement cycle is 1 second, and 3 announcement cycles are 3 seconds so.If transmission rate is 100Mbps (megabit per second), will there be so the data of 300Mbits to lose because of routing failure.
Summary of the invention
The technical problem to be solved in the present invention provides a kind of determination methods and a kind of router of failure of main router of virtual route redundancy protocol, can shorten the judgement time that active router was lost efficacy, and then shortens switching time, reduces losing of service traffics.
For solving the problems of the technologies described above, the invention provides the determination methods that active router lost efficacy among a kind of Virtual Router Redundacy Protocol VRRP, comprising:
Be each configuration of routers switching judging parameter, described switching judging parameter comprises statistical parameter N and message threshold value M, and N and M are natural number, N 〉=M, M≤3;
Each backup router is calculated according to the following formula separately statistic period T according to statistical parameter:
T=N* notification time cycle+slope time;
Each backup router is added up the number of times of not receiving the VRRP notification packet in measurement period separately, when the number of times accumulative total of not receiving the VRRP notification packet in the measurement period reaches message threshold value M, initiate active and standby election contest.
Further, active router receives the message of the active and standby election contest of backup router transmission, adjusts the priority of oneself, participates in active and standby election contest.
Further, the described slope time equal=(255-PRIORITY)/255; Wherein, PRIORITY is the priority of backup router.
For solving the problems of the technologies described above, the present invention also provides a kind of router, comprises receiving element, computing unit, statistics judging unit and election contest unit:
Described receiving element, for the switching judging parameter that receives VRRP notification packet and configuration, described switching judging parameter comprises statistical parameter N and message threshold value M, N and M are natural number, N 〉=M, M≤3;
Described computing unit is used for being calculated according to the following formula statistic period T according to statistical parameter: T=N* notification time cycle+slope time;
Described statistics judging unit is used for adding up the number of times M ' that does not receive the VRRP notification packet in each measurement period, when judging that M ' equals message threshold value M, to election contest unit transmitted signal;
Described election contest unit is used for initiating active and standby election contest behind the signal that receives the transmission of statistics judging unit.
Further, the described slope time equal=(255-PRIORITY)/255; Wherein, PRIORITY is the priority of backup router.
Further, described statistics judging unit when judging that M ' is not equal to message threshold value M, is proceeded statistics, after a measurement period arrives, re-starts statistics.
Further, the active and standby election contest of described initiation is to point to the message that active router sends active and standby election contest.
The present invention is in Ethernet and IP communication network, with the next determination methods that lost efficacy for active router among the VRRP of dynamic duration threshold value.Can effectively shorten the time that backup router judges whether active router lost efficacy.
Adopt the method for the invention, can in the unsettled situation of active router, prepare in advance active and standby election contest and active and standby switching, prevent simultaneously unnecessary active and standby election contest.And can configure according to network performance the competitive strategy of VRRP, the configuration backup server is initiated the opportunity of main and standby competition neatly.
Description of drawings
Accompanying drawing described herein is used to provide a further understanding of the present invention, consists of the application's a part, and illustrative examples of the present invention and explanation thereof are used for explaining the present invention, do not consist of improper restriction of the present invention.In the accompanying drawings:
Fig. 1 is the flow chart that backup router is initiated active and standby election contest;
Fig. 2 is that active router is received the flow chart that participates in active and standby election contest after the message of active and standby election contest;
Fig. 3 is for realizing the router schematic diagram of the inventive method.
Embodiment
Inventive concept of the present invention is: be each configuration of routers switching judging parameter, comprise statistical parameter N and message threshold value M, N and M are natural number, N 〉=M, M≤3; Each backup router is calculated according to the following formula separately statistic period T according to statistical parameter: T=N* notification time cycle+slope time; Each backup router is added up the number of times of not receiving the VRRP notification packet in measurement period separately, when the number of times accumulative total of not receiving the VRRP notification packet in the measurement period reaches message threshold value M, initiate active and standby election contest.
The parameter N of announcement measurement period and start the threshold value M of active and standby election contest can be determined by the configuration to active and standby router, also can transmit by the expansion to the field of VRRP message.
Receive the message of active and standby election contest when active router after, participate in active and standby election contest.The router of winning in election contest sends VRRP group notification packet, becomes active router.
The flow process of initiating active and standby election contest take a backup router describes as example, and the flow process of other backup routers is identical, as shown in Figure 1, may further comprise the steps:
Step 110 is according to the statistical parameter counting statistics cycle;
Statistic period T: T=N* notification time cycle+slope time;
Wherein, the notification time cycle is generally the fixed value of agreement regulation; Slope time SKEW_TIME=(255-PRIORITY)/255; Wherein PRIORITY is the priority of this backup router;
Step 120, counter O reset;
Step 130, the beginning timing;
Two timers can be set, and a timer is used for the timing notification time cycle, and another is used for the timing measurement period;
Can be carried the time started in message by webmaster, each backup router carries out timing according to the time started of recording in the message, perhaps just begins timing after entering this flow process after the election contest end.
Step 140, through a notification time cycle, backup router judges whether receive notification packet within this cycle, if receive, then returns this step, waits for next notification time cycle arrival, otherwise carries out next step;
Step 150, count value M ' adds 1;
Step 160 judges whether to arrive measurement period, if so, carries out next step, otherwise returns step 140;
Step 170 is judged whether count value M ' equals M, if so, carries out next step, otherwise is returned step 120;
Step 180 is initiated the active and standby election contest of VRRP.
Active router receive after the message of active and standby election contest flow process as shown in Figure 2, comprising:
Step 210, active router receive the message of the active and standby election contest of VRRP;
Step 220 is pressed existing protocol and is adjusted the priority of oneself;
Step 230 participates in active and standby election contest.
By above-mentioned example, can be according to by in measurement period, not receiving the number of times M ' of VRRP notification packet, and when judging that M ' equals threshold value M, start VRRP election contest mechanism.Do not announce unsuccessfully when backup router has occurred M time N announcement phase the inside, then start the competition announcement.Can in announcing unsuccessfully rear 1 announcement cycle for the last time, active router just start competition like this.Having avoided will experiencing in the RFC2338 of VRRP and two versions of RFC3678 3 announcement cycles just starts the disadvantage that the election contest announcement brings: excessive cycle, the service outage duration that brings is long.When active router normally sends the VRRP notification packet, and for some reason, when backup router is not received the VRRP notification packet, can be by adjusting the value of switching judging parameter M and N, adjust backup router and initiate the opportunity of main and standby competition, thereby avoid unnecessary active and standby election contest.And by the number of times of configuration measurement period and the threshold value of the active and standby election contest of startup, can be configured according to network environment.
A kind of router of realizing said method as shown in Figure 3, comprises receiving element, computing unit, statistics judging unit and election contest unit, wherein:
Receiving element, for the switching judging parameter that receives VRRP notification packet and configuration, described switching judging parameter comprises statistical parameter N and message threshold value M, N and M are natural number, N 〉=M, M≤3;
Computing unit is used for being calculated according to the following formula statistic period T according to statistical parameter: T=N* notification time cycle+slope time;
The statistics judging unit is used for adding up the number of times M ' that does not receive the VRRP notification packet in each measurement period, when judging that M ' equals message threshold value M, to election contest unit transmitted signal;
The statistics judging unit is proceeded statistics when judging that M ' is not equal to message threshold value M, after a measurement period arrives, re-start statistics.
The election contest unit is used for initiating active and standby election contest behind the signal that receives the transmission of statistics judging unit.
The above is the preferred embodiments of the present invention only, is not limited to the present invention, and for a person skilled in the art, the present invention can have various modifications and variations.Within the spirit and principles in the present invention all, any modification of doing, be equal to replacement, improvement etc., all should be included within protection scope of the present invention.

Claims (5)

1. the determination methods that active router lost efficacy among the Virtual Router Redundacy Protocol VRRP is characterized in that, comprising:
Be each configuration of routers switching judging parameter, described switching judging parameter comprises statistical parameter N and message threshold value M, and N and M are natural number, N 〉=M, M≤3;
Each backup router is calculated according to the following formula separately statistic period T according to statistical parameter:
T=N* notification time cycle+slope time;
Each backup router is added up the number of times of not receiving the VRRP notification packet in measurement period separately, when the number of times accumulative total of not receiving the VRRP notification packet in the measurement period reaches message threshold value M, initiate active and standby election contest;
The described slope time equals=(255-PRIORITY)/255; Wherein, PRIORITY is the priority of backup router.
2. the method for claim 1 is characterized in that,
Active router receives the message of the active and standby election contest of backup router transmission, adjusts the priority of oneself, participates in active and standby election contest.
3. a router is characterized in that, comprises receiving element, computing unit, statistics judging unit and election contest unit:
Described receiving element, for the switching judging parameter that receives VRRP notification packet and configuration, described switching judging parameter comprises statistical parameter N and message threshold value M, N and M are natural number, N 〉=M, M≤3;
Described computing unit is used for being calculated according to the following formula statistic period T according to statistical parameter: T=N *Notification time cycle+slope time;
Described statistics judging unit is used for adding up the number of times M ' that does not receive the VRRP notification packet in each measurement period, when judging that M ' equals message threshold value M, to election contest unit transmitted signal;
Described election contest unit is used for initiating active and standby election contest behind the signal that receives the transmission of statistics judging unit;
The described slope time equals=(255-PRIORITY)/255; Wherein, PRIORITY is the priority of backup router.
4. router as claimed in claim 3 is characterized in that,
Described statistics judging unit when judging that M ' is not equal to message threshold value M, is proceeded statistics, after a measurement period arrives, re-starts statistics.
5. router as claimed in claim 3 is characterized in that,
The active and standby election contest of described initiation is to point to the message that active router sends active and standby election contest.
CN2009101519537A 2009-07-08 2009-07-08 Judging method for failure of main router of virtual route redundancy protocol and router Expired - Fee Related CN101945036B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN2009101519537A CN101945036B (en) 2009-07-08 2009-07-08 Judging method for failure of main router of virtual route redundancy protocol and router

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2009101519537A CN101945036B (en) 2009-07-08 2009-07-08 Judging method for failure of main router of virtual route redundancy protocol and router

Publications (2)

Publication Number Publication Date
CN101945036A CN101945036A (en) 2011-01-12
CN101945036B true CN101945036B (en) 2013-02-27

Family

ID=43436819

Family Applications (1)

Application Number Title Priority Date Filing Date
CN2009101519537A Expired - Fee Related CN101945036B (en) 2009-07-08 2009-07-08 Judging method for failure of main router of virtual route redundancy protocol and router

Country Status (1)

Country Link
CN (1) CN101945036B (en)

Families Citing this family (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102387087A (en) * 2011-12-18 2012-03-21 西安安智科技有限公司 Method and system for realizing standby route based on active detection technique
CN103441940B (en) * 2013-08-29 2017-12-15 华为技术有限公司 The network equipment is by the switching method, device and the network equipment for state to major state
CN106254087A (en) * 2015-06-12 2016-12-21 中兴通讯股份有限公司 A kind of method and apparatus checking that VRRP configures
CN105515840A (en) * 2015-11-30 2016-04-20 南京驭环光电科技有限公司 Blade server redundancy protection method
CN107819556B (en) * 2016-09-12 2020-04-28 北京金山云网络技术有限公司 Service state switching method and device
CN112929265A (en) * 2021-02-08 2021-06-08 上海弘积信息科技有限公司 Method for any node to place VRRP any node in main in real time
CN113098721A (en) * 2021-04-07 2021-07-09 上海商米科技集团股份有限公司 Multi-bandwidth backup and superposition strategy and method for router

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1780295A (en) * 2004-11-24 2006-05-31 杭州华为三康技术有限公司 Method for realizing redundant router protocol on elastic packet loop
CN1933442A (en) * 2005-09-15 2007-03-21 华为技术有限公司 Method and system for realizing virtual router redundant protocol master and standby equipment switching

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1780295A (en) * 2004-11-24 2006-05-31 杭州华为三康技术有限公司 Method for realizing redundant router protocol on elastic packet loop
CN1933442A (en) * 2005-09-15 2007-03-21 华为技术有限公司 Method and system for realizing virtual router redundant protocol master and standby equipment switching

Also Published As

Publication number Publication date
CN101945036A (en) 2011-01-12

Similar Documents

Publication Publication Date Title
CN101945036B (en) Judging method for failure of main router of virtual route redundancy protocol and router
US9270524B2 (en) Method and device for LACP link switching and data transmission
US11032205B2 (en) Flow control method and switching device
US7835270B2 (en) Method for managing virtual router redundancy protocol backup groups
CN108306777B (en) SDN controller-based virtual gateway active/standby switching method and device
US8509059B2 (en) Method for operating a virtual router redundancy protocol router and communication system therefor
US9705782B2 (en) Method and system for efficient graceful restart in an open shortest path first (OSPF) network
EP3806417A1 (en) Method, device, and system for realizing disaster tolerance backup
US8462795B2 (en) Method and device for transmitting control message based on multi-ring ethernet
WO2009009977A1 (en) Master backup switch method for route device and backup system for route device
CN105119822A (en) Backup group management method and system based on VRRP (Virtual Router Redundancy Protocol)
JP5784139B2 (en) Communications system
WO2012048585A1 (en) Switching method and router
WO2012088910A1 (en) Method and system for detecting connectivity fault
KR101017540B1 (en) Uninterrupted network control message generation during local node outages
CN115378844B (en) Fault detection method and device for network link
CN101155129B (en) Method for implementing dynamic optimal adjustment of virtual routing notification time
CN101931550A (en) Method and device for synchronizing main and standby main control boards
CN101848157A (en) Method for controlling generation of routing update message and network equipment thereof
CN105939254B (en) The method and device of VRRP backup group state switching
US10382155B2 (en) Data processing
CN101945083B (en) Authentication method and counterfeit judgment method for virtual router redundancy protocol
CN100550845C (en) The method and apparatus that a kind of message sends
CN111934939B (en) Network node fault detection method, device and system
EP3993327A1 (en) Method for processing packet and first network device

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20171229

Address after: 224300 two groups 198 in Fuyu Town, Fuyu Town, Sheyang County, Yancheng City, Jiangsu Province

Patentee after: Liu Delian

Address before: 518057 Nanshan District high tech Industrial Park, Guangdong, South Road, science and technology, ZTE building, legal department

Patentee before: ZTE Corporation

CB03 Change of inventor or designer information
CB03 Change of inventor or designer information

Inventor after: Liu Delian

Inventor before: Liu Zhiwei

Inventor before: Gao Lu

CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20130227

Termination date: 20190708