⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 draft-ietf-pim-bidir-03.txt

📁 BCAST Implementation for NS2
💻 TXT
📖 第 1 页 / 共 5 页
字号:
election process should be the router on the link with the "best"unicast routing metric to the RP (as reported by the MRIB). Whencomparing metrics from different unicast routing protocols, we use thesame comparison rules used by the PIM-SM assert process [9].The election process needs to take place when information on a new RPinitially becomes available, and can be re-used as new bidir groups forthe same RP are encountered. There are however some conditions where anupdate to the election is required:     o There is a change in unicast metric to reach the RP for any of       the routers on the link.     o The interface on which the RP is reachable changes to an       interface for which the router was previously the DF.     o A new PIM neighbor starts up on a link.Handley/Kouvelas/Speakman/Vicisano             Section 3.5.1.  [Page 19]INTERNET-DRAFT           Expires: December 2001                June 2001     o The elected DF dies.The election process has to be robust enough to ensure with very highprobability that all routers on the link have a consistent view of theDF. This is because with the forwarding rules described in section 3.3if multiple routers end-up thinking that they should be responsible forforwarding, loops may result. To reduce the possibility of thisoccurrence to a minimum, the election algorithm has been biased towardsdiscarding DF information and suspending forwarding during periods ofambiguity.3.5.2.  DF Election descriptionThis section does not provide the definitive specification for the DFelection process. If any discrepancy exists between section 3.5.3 andthis section, the specification in section 3.5.3 is to be assumedcorrect.To perform the election of the DF for a particular RP, routers on a linkneed to exchange their unicast routing metric information (as reportedby the MRIB) for reaching the RP.In the election protocol described below, many message exchanges arerepeated Election_Robustness times for reliability. In all those casesthe message retransmissions are spaced in time by a small randominterval.3.5.2.1.  Bootstrap ElectionInitially when no DF has been elected, routers finding out about a newRP start participating in the election by sending Offer messages.  Offermessages include the router's metric to reach the RP. Offers areperiodically retransmitted with a period of Offer_Interval.If a router hears a better offer than its own from a neighbor, it stopsparticipating in the election for a period of Election_Robustness *Offer_Interval. If during this period no winner is elected, then therouter restarts the election from the beginning. If a router receives anoffer with worse metrics than its own, then it restarts the electionfrom the beginning.The result should be that all routers except the best candidate stopadvertising their offers.A router assumes the role of the DF after having advertised its metricsElection_Robustness times without receiving any offer from any otherHandley/Kouvelas/Speakman/Vicisano           Section 3.5.2.1.  [Page 20]INTERNET-DRAFT           Expires: December 2001                June 2001neighbor. At that point it transmits a Winner message which declares toevery other router on the link the identity of the winner and themetrics it is using.Routers hearing a winner message stop participating in the election andrecord the identity and metrics of the winner. If the local metrics arebetter than those of the winner then the router records the identity ofthe winner but reinitiates the election.3.5.2.2.  Loser Metric ChangesWhenever the unicast metric to a RP changes for a non-DF router to avalue that is better than that previously advertised by the acting DF,the router with the new metric should take action to eventually assumeforwarding responsibility. After the metric change is detected, the non-DF router with the now better metric restarts the DF election process bysending Offer messages with this new metric. If no response is receivedafter Election_Robustness retransmissions, the router assumes the roleof the DF following the usual Winner announcement procedure.Upon receipt of an offer that is worse than its current metric, the DFwill respond with a Winner message declaring its status and advertisingits metric. Upon receiving this message, the originator of the Offerrecords the identity of the DF and aborts the election.Upon receipt of an offer that is better than its current metric, the DFrecords the identity and metrics of the offering router and respondswith a Backoff message. This instructs the offering router to hold offfor a short period of time while the unicast routing stabilises. TheBackoff message includes the offering router's new metric and address.All routers on the link who have pending offers with metrics worse thanthose in the backoff message (including the original offering router)will hold further offers for a period of time defined in the Backoffmessage.If during the Backoff_Period, a third router sends a new better offer,the Backoff message is repeated for the new offer and the Backoff_Periodrestarted.Before the Backoff_Period expires, the acting DF nominates the routerhaving made the best offer as the new DF using a Pass message.  Thismessage includes the IDs and metrics of both the old and new DFs.  Theold DF stops performing its tasks as soon as the transmission is made.The new DF assumes the role of the DF as soon as it receives the Passmessage. All other routers on the link take note of the new DF and itsmetric.Handley/Kouvelas/Speakman/Vicisano           Section 3.5.2.2.  [Page 21]INTERNET-DRAFT           Expires: December 2001                June 20013.5.2.3.  Winner Metric ChangesIf the DF's routing metric to reach the RP changes to a worse value, itsends a set of Election_Robustness randomly spaced Winner messages onthe link, advertising the new metric. Routers who receive thisannouncement but have a better metric may respond with an Offer messagewhich results in the same handoff procedure described above.  Allrouters assume the DF has not changed until they see a Pass or Winnermessage indicating the change.There is no pressure to make this handoff quickly if the acting DF stillhas a path to the RP. The old path may now be suboptimal but it willstill work while the re-election is in progress.If the routing metric at the DF changes to a better value, a singleWinner message is sent advertising the new metric.3.5.2.4.  Winner Loses PathIf a router's RPF_interface to the RP switches to be on a link for whichit is acting as the DF, then it can no longer provide forwardingservices for that link. It therefore immediately stops being the DF andrestarts the election. As its path to the RP is through the link, aninfinite metric is used in the Offer message it sends.Note: At this stage the old DF will have a new RPF neighbor on the link(indicated by unicast routing) which it could use in a Pass message butthis adds unnecessary complication to the election process.3.5.2.5.  Late Router Starting UpA late router starting up after the DF election process has completedwill have no immediate knowledge of the election outcome. As a result,it will start advertising its metric in Offer messages. As soon as thishappens, the currently elected DF will respond with a Winner message ifits metric is better than the metric in the Offer message, or with aBackoff message if its metric worse than the metric in the Offermessage.3.5.2.6.  Winner DiesWhenever the DF dies, a new DF has to be elected. The speed at whichthis can be achieved depends on whether there are any downstream routerson the link.Handley/Kouvelas/Speakman/Vicisano           Section 3.5.2.6.  [Page 22]INTERNET-DRAFT           Expires: December 2001                June 2001If there are downstream routers, typically their RPF_neighbor asreported by the MRIB before the DF dies will be the DF itself. They willtherefore notice either a change in the metric for the route to the RPor a change in RPF_neighbor away from the DF and will restart theelection by transmitting Offer messages.  If according to the MRIB theRP is now reachable through the same link via another upstream router,an infinite metric will be used in the Offer.If no downstream routers are present, the only way for other upstreamrouters to detect a DF failure is by the timeout of the PIM neighborinformation, which will take significantly longer.3.5.3.  Election Protocol SpecificationThis section provides the definitive specification for the DF electionprocess. If any discrepancy exists between section 3.5.2 and thissection, the specification in this section is to be assumed correct.3.5.3.1.  Election StateThe DF election state is maintained per RP for each multicast enabledinterface on the router as introduced in section 3.1:The state machine has the following four states:     Offer          Initial election state. When in the Offer state a router          thinks it can eventually become the winner and periodically          generates Offer messages.     Lose In this state the router knows that there either is a          different election winner or that no router on the link has a          path to the RP.     Winner          The router is the acting DF without any contest.     Backoff          The router is the acting DF but another router has made a bid          to take over.In the state machine a router is considered to be an acting DF if it isin the Win or Backoff states.The operation of the election protocol makes use of the variables andtimers described below:Handley/Kouvelas/Speakman/Vicisano           Section 3.5.3.1.  [Page 23]INTERNET-DRAFT           Expires: December 2001                June 2001     Acting DF information          Used to store the election winner who is the currently acting          DF.     Election-Timer (DFT)          Used to schedule transmission of Offer, Winner and Pass          messages.     Offer-Count (OC)          Used to maintain the number of times an Offer or Winner          message has been transmitted.     Best-Offer          Used by the DF to record who has made the last offer for          sending the Pass message.3.5.3.2.  Election MessagesThe election process uses the following PIM control messages the packetformat of which is described in section 3.7:     Offer (OfferingID, Metric)          Sent by routers that believe they have a better metric to the          RP than the metric that has been on offer so far.     Winner (DF-ID, DF-Metric)          Sent by a router when assuming the role of the DF or when re-          asserting in response to worse offers.     Backoff (DF-ID, DF-Metric, OfferingID, OfferMetric,          BackoffInterval)          Used by the DF to acknowledge better offers. It instructs          other routers with equal or worse offers to wait till the DF          passes responsibility to the sender of the offer.     Pass (Old-DF-ID, Old-DF-Metric, New-DF-ID, New-DF-Metric)          Used by the old DF to pass forwarding responsibility to a          router that has previously made an offer.  The Old-DF-Metric          is the current metric of the DF at the time the pass is sent.3.5.3.3.  Election EventsDuring protocol operation, in addition to the expiration of theElection-Timer and the reception of the four control messages, thefollowing events can take place:Handley/Kouvelas/Speakman/Vicisano           Section 3.5.3.3.  [Page 24]INTERNET-DRAFT           Expires: December 2001                June 2001     o Discovery of new RP     o Metric reported by the MRIB to reach the RP changes     o DF loses path to RP     o Detection of DF failure3.5.3.4.  Election NotationThe DF election state machine description uses the following notation inaddition to the pseudocode notation described earlier in this spec.     ?=  denotes the operation of lowering a timer to a new value. If         the timer is not running then it is started using the new         value. If the timer is running with an expiration lower than         the new value, then the timer is not altered.When a control message is received and actions are specified on acondition that metrics are Better or Worse the comparison must beperformed as follows:     o On receipt of an Offer or Winner message compare our current       metrics for the DF with the metrics advertised for the sender of       the message.     o On receipt of a Backoff or Pass message compare our current       metrics for the DF with the metrics advertised for the target of       the message.When an action of "set DF to Sender or Target" is encountered duringreceipt of a Winner, Pass or Backoff message it means the following:     o On receipt of a Winner message set the DF to be the originator of       the message and record its metrics.     o On receipt of a Pass message set the DF to be the target of the       message and record its metrics.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -