idnits 2.17.1 draft-ietf-mpls-ldp-state-01.txt: ** The Abstract section seems to be numbered Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- ** Looks like you're using RFC 2026 boilerplate. This must be updated to follow RFC 3978/3979, as updated by RFC 4748. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- ** Missing expiration date. The document expiration date should appear on the first and last page. ** The document seems to lack a 1id_guidelines paragraph about 6 months document validity -- however, there's a paragraph with a matching beginning. Boilerplate error? ** The document is more than 15 pages and seems to lack a Table of Contents. == No 'Intended status' indicated for this document; assuming Proposed Standard == It seems as if not all pages are separated by form feeds - found 0 form feeds but 78 pages Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- ** The document seems to lack an Introduction section. ** The document seems to lack an IANA Considerations section. (See Section 2.2 of https://www.ietf.org/id-info/checklist for how to handle the case when there are no actions for IANA.) ** The document seems to lack an Authors' Addresses Section. ** The document seems to lack separate sections for Informative/Normative References. All references will be assumed normative when checking for downward references. ** The abstract seems to contain references ([Ref5]), which it shouldn't. Please replace those with straight textual mentions of the documents in question. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the RFC 3978 Section 5.4 Copyright Line does not match the current year == Line 51 has weird spacing: '...be used for...' == Line 190 has weird spacing: '... blocks in LS...' == Line 1239 has weird spacing: '...eld and from ...' == Line 1433 has weird spacing: '... _Block for U...' == Line 2639 has weird spacing: '...ock and pass ...' -- The document seems to lack a disclaimer for pre-RFC5378 work, but may have content which was first submitted before 10 November 2008. If you have contacted all the original authors and they are all willing to grant the BCP78 rights to the IETF Trust, then this is fine, and you can ignore this comment. If not, you may need to add the pre-RFC5378 disclaimer. (See the Legal Provisions document at https://trustee.ietf.org/license-info for more information.) -- The document date (June 1999) is 9081 days in the past. Is this intentional? Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) -- Missing reference section? 'Ref5' on line 90 looks like a reference -- Missing reference section? 'Ref7' on line 102 looks like a reference -- Missing reference section? 'CR-LDP' on line 102 looks like a reference -- Missing reference section? 'Ref1' on line 112 looks like a reference -- Missing reference section? 'Ref2' on line 1622 looks like a reference -- Missing reference section? 'Ref-5' on line 603 looks like a reference Summary: 10 errors (**), 0 flaws (~~), 8 warnings (==), 8 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 1 MPLS Working Group Liwen Wu 2 Internet Draft Pierrick Cheval 3 Expiration Date: December 1999 Christophe Boscher 4 Alcatel USA 6 Eric Gray 7 Lucent 9 June 1999 11 LDP State Machine 12 draft-ietf-mpls-ldp-state-01.txt 14 0. Status of this Memo 16 This document is an Internet-Draft and is in full conformance with 17 all provisions of Section 10 of RFC2026. 19 Internet-Drafts are working documents of the Internet Engineering 20 Task Force (IETF), its areas, and its working groups. Note that 21 other groups may also distribute working documents as Internet- 22 Drafts. 24 Internet-Drafts are draft documents valid for a maximum of six months 25 and may be updated, replaced, or obsoleted by other documents at any 26 time. It is inappropriate to use Internet- Drafts as reference 27 material or to cite them other than as "work in progress." 29 The list of current Internet-Drafts can be accessed at 30 http://www.ietf.org/ietf/1id-abstracts.txt 32 The list of Internet-Draft Shadow Directories can be accessed at 33 http://www.ietf.org/shadow.html. 35 Distribution of this memo is unlimited. 37 Copyright Notice 39 Copyright (C) The Internet Society (1998). All Rights Reserved. 41 1. Abstract 43 In the current LDP draft [Ref5], there is no state machine specified 44 for processing the LDP messages. We think that defining a common 45 state machine is very important for interoperability between 46 different ldp implementations. 48 This draft provides state machine tables for ATM switch LSRs. We 49 begin in section 2 by defining a list of terminologies. Then in 50 section 3, we propose two sets of state machine tables for ATM switch 51 LSRs which use downstream-on-demand mode, one method can be used for 52 non-vc mergable ATM LSRs, while the other one can be used for the 53 vc-mergable ATM LSRs. In section 4, we provides a state machine for 54 downstream mode ATM LSR. 56 Even though the state machines in this document are specific for 57 ATM-LSR, they can be easily adapted for other types of LSRs. 59 2. Terminologies 61 - LDP-REQUEST: LDP Label Request message 63 - LDP-MAPPING: LDP Label Mapping message 65 - LDP-WITHDRAW: LDP Label Withdraw message 67 - LDP-RELEASE: LDP Label Release message 69 - LDP-ABORT: It is a LDP Abort message which is used to abort a LSP 70 setup. 72 - LDP-NAK: It is a LDP Notification msg which is to reject a LDP 73 message. 75 3. State Machine for Downstream-on-Demand Mode 77 This draft focuses on the LDP state machines and the associated 78 control blocks. It does not describe the "LDP controller" which is 79 in charge of LDP session initialization, address mapping messages 80 management, routing interface, etc. 82 In this draft, we provide two sets of state machines: one for the ATM 83 LSR which does not have VC-merge capability, and the other one for 84 the ATM LSR which does have VC-merge capability. 86 The state machines cover both independent LSP control and ordered LSP 87 control. 89 The loop detection and loop prevention message will be processed in 90 the way as specified in [Ref5]. The impact of loop detection and loop 91 prevention messages on a state transition is left for further study. 93 3.0 An LSR's Behavior in the Case of a Next Hop Change 95 When there is a topology change and an LSR detects a new better next 96 hop for an LSP, it may behave in 2 different ways: 98 1) It tries to do a "local repair". This means that it extends the 99 LSP through the new next hop, releases the old path from this LSR 100 forward and then splices into this newly extended LSP. 102 2) If the LSP is created with the "pinned" option[Ref7,CR-LDP], the 103 LSR ignores the new next hop change, and the LSP stays unchanged. The 104 LSR may decide to send an LDP-MAPPING which contains the attribute 105 about this New Next Hop (NH) change. 107 3.1. ATM Switch LSR with NO VC-merge 109 In an MPLS domain where some ATM LSRs do not have VC-merge 110 capability, downstream-on-demand mode is required for these ATM 111 LSRs[Ref1]. Also, "conservative label retention mode" is required in 112 this case[Ref1]. 114 For each LSP, there are 2 kinds of state machines involves: 116 1) the LSP Control Block and its state machine which can be used to 117 handle normal LSP setup. It is created when the LSR receives a new 118 LDP Request and it is deleted when the LSP of this request is torn 119 down. 121 2) the Next Hop Trigger Control Block and its state machine which is 122 used to handle switching over to a better LSP through a different 123 next hop. It is created when the LSR decides to switch over to a 124 better next hop and it is deleted when the LSR finishes switching 125 over to the better next hop. 127 3.1.1 LSP Control Block 129 For each LSP, an LSP_Control_Block is defined which may contain the 130 following information: 132 - Upstream Label Request ID(assigned by the upstream LSR), which is 133 the 'Message Id' in the Label Request Message received from the 134 upstream LSR. 136 - Downstream Label Request ID (assigned by this LSR itself), which 137 is 'Message Id' in the Label Request Message sent to the 138 downstrearm LSR. 140 - Upstream LDP Identifier 142 - Downstream LDP Identifier 143 - State 145 - FEC 147 - Upstream Label(assigned by this LSR) 149 - Downstream Label(assigned by the downstream LSR) 151 - Trigger Control Block Pointer, (Only used at the ingress LSR of a 152 LSP)which points to the control block that triggers setting up this 153 LSP or tearing down this LSP. 155 - Next Hop Control Block Pointer, which points to the control block 156 which is used for switching over to a better LSP. 158 The following index combinations can be used to locate a unique 159 LSP_Control_Block: 161 - Downstream Label and Downstream LDP Identifier, or 163 - Upstream Label and Upstream LDP Identifier, or 165 - Upstream Label Request ID and Upstream LDP Identifier 167 Here is the relationship between different control blocks, the detail 168 definition of Next Hop Trigger Block is described in section 3.1.6. 170 For example, an LSP which transit through (LSR-A, LSR-B, LSR-C,LSR- 171 D): 173 LSR-A ----> LSR-B ---> LSR-C ---> LSR-D 175 The control blocks in LSR-A are: 177 +-----------------------+ 178 | Trigger Control Block | 179 | (e.g, by config) | 180 +-----------------------+ 181 ^ 182 |(Trigger Control block pointer) 183 | 184 | 185 +-----------------------+ 186 | LSP Control Block | 187 +-----------------------+ 189 When LSR-B detects a better next hop to LSR-D through LSR-E, and it 190 decides to switch over to it, so control blocks in LSR-B are: 192 +-----------------------+ 193 | LSP Control Block | 194 | (original LSP) | 195 +-----------------------+ 196 (LSP ^ | 197 Control | | (Next Hop Control Block Pointer) 198 Block | | 199 Pointer | v 200 +--------------------------------+ 201 | Next Hop Trigger Control Block | 202 +--------------------------------+ 203 ^ | 204 (Trigger | | (New Next Hop LSP 205 Control | | Control Block Pointer) 206 Block | | 207 Pointer)| | 208 | v 209 +------------------------+ 210 | LSP Control Block | 211 | (for LSP: LSR-B,LSR-E, | 212 | LSR-D) | 213 +------------------------+ 215 3.1.2 States 217 This section describes the various states that are used in the state 218 machine for the ATM non VC-merge LSR. 220 -- IDLE 222 This is the initial LSP state, when the LSP_Control_Block is created. 224 -- RESPONSE_AWAITED 226 This state means that the LSR has received and processed an LDP- 227 REQUEST from an upstream LSR, or it has received an internal set up 228 request. It has sent a new LDP-REQUEST towards a downstream LSR. The 229 LSR is waiting for the LDP-MAPPING message from the downstream LSR. 231 -- ESTABLISHED 233 This state means that the LSR has received the LDP-MAPPING message 234 from the downstream LSR and the LSP is up and operational. 236 -- RELEASE_AWAITED 238 This state means that the LSR has sent a LDP-WITHDRAW message 239 upstream and is waiting for the LDP-RELEASE before freeing up the 240 label resource. 242 3.1.3 Events 244 -- LDP Request 246 The LSR receives an LDP-REQUEST from an upstream LSR. 248 -- LDP Mapping 250 The LSR receives an LDP-MAPPING from a downstream LSR. 252 -- LDP Release 254 The LSR receives an LDP-RELEASE from an upstream LSR. 256 -- LDP Withdraw 258 The LSR receives an LDP-WITHDRAW from a downstream LSR. 260 -- LDP Upstream Abort 262 The LSR receives an LDP-ABORT from an upstream LSR. 264 -- LDP Downstream Nak The LSR receives an LDP-NAK(notification) from 265 an downstream LSR. 267 -- Upstream Lost 269 The LSR loses its LDP session with an upstream LDP peer. 271 -- Downstream Lost 273 The LSR loses its LDP session with a downstream LDP peer. 275 -- Internal SetUp 277 For some reason, e.g. a configuration request of a traffic 278 engineering tunnel, or recognizing a new FEC could trigger an 279 Internal SetUp event to set up a new LSP from this node. 281 -- Internal Destroy 282 The LSR send an Internal Destroy event to tear down an LSP. 284 -- Internal Cross-Connect 286 The LSR send an Internal Cross-Connect to splice two LSPs into one 287 LSP. This happens when a LSR switchs over to a better next hop 289 -- Internal New NH 291 The LSR decides to switch over the better next hop. 293 3.1.4 State Transitions 295 The following diagram describes briefly the state transitions. 297 +-------------------+ 298 | | 299 +-------->| IDLE |<--------------+ 300 | | | | 301 | +-------------------+ |(LDP Release) 302 |(LDP Upstream | | 303 | Abort) |(LDP Request) |(LDP Upstream Abort) 304 |(Downstream Lost) |(Internal SetUp) | 305 |(Downstream Nak) | |(LDP Downstream Nak) 306 |(Upstream Lost) v |(Upstream Lost) 307 | +-------------------+ | 308 | | | | 309 +---------| RESPONSE_AWAITED | | 310 | | | 311 +-------------------+ | 312 | | 313 |(LDP Mapping) | 314 | | 315 v | 316 +-------------------+ | 317 | | | 318 | ESTABLISHED |------------>--+ 319 | | | 320 +-------------------+ | 321 | | 322 | | 323 |(LDP Withdraw) | 324 |(Downstream Lost) | 325 | | 326 v | 327 +-------------------+ | 328 | | | 329 | RELEASE_AWAITED |------------>--+ 330 | | 331 +-------------------+ 333 3.1.5 State Machine 335 3.1.5.1 State -- "IDLE" 336 State: IDLE 338 Event: LDP Request 340 New States: Depends upon the action routine 342 Actions: 344 If this LSR is the LSP Egress or Proxy Egress [Ref2] 346 Then: 347 Choose an upstream label, connect this upstream label to the local 348 IP forwarding module, allocate the resources, send the LDP-MAPPING 349 message upstream with the upstream label, and go to the new state 350 `ESTABLISHED'. 352 else 353 Obtain a next hop (or interface) with the FEC specified in the 354 LDP-REQUEST message, propagate the LDP-REQUEST message, with newly 355 assigned Message ID by this LSR, towards the obtained next hop, 356 and go to the new state `RESPONSE_AWAITED'. 358 If the LSR uses the independent control mode[Ref2], choose an 359 upstream label, connect this upstream label to the local IP 360 forwarding module, and send an LDP-MAPPING message upstream with 361 the upstream label. 363 If unable to process the request for any reason, issue an LDP-NAK 364 message to the sender with the appropriate error code and delete the 365 control block. 367 State: IDLE 369 Event: LDP Mapping 371 New State: IDLE 373 Actions: 375 Ignore the event. It is an internal implementation error. 377 State: IDLE 379 Event: LDP Release 381 New State: IDLE 382 Actions: 384 Ignore the event. It is an internal implementation error. 386 State: IDLE 388 Event: LDP Withdraw 390 New State: IDLE 392 Actions: 394 Ignore the event. It is an internal implementation error. 396 State: IDLE 398 Event: LDP Upstream Abort 400 New State: IDLE 402 Actions: 404 Ignore the event. It is an internal implementation error. 406 State: IDLE 408 Event: LDP Downstream Nak 410 New State: IDLE 412 Actions: 414 Ignore the event. It is an internal implementation error. 416 State: IDLE 418 Event: Upstream Lost 420 New State: IDLE 422 Actions: 424 Ignore the event. It is an internal implementation error. 426 State: IDLE 428 Event: Downstream Lost 429 New State: IDLE 431 Actions: 433 Ignore the event. It is an internal implementation error. 435 State: IDLE 437 Event: Internal SetUp 439 New State: RESPONSE_AWAITED 441 Actions: 443 Set up the Trigger Control Block pointer, 445 Obtain a next hop (or interface) with the FEC specified in the 446 Internal SetUp message, send a LDP-REQUEST towards the obtained next 447 hop, and go to the new state 'RESPONSE_AWAITED'. 449 State: IDLE 451 Event: Internal Destroy 453 New State: IDLE 455 Actions: 457 Ignore. It is an internal implementation error. 459 State: IDLE 461 Event: Internal Cross-Connect 463 New State: IDLE 465 Actions: 467 Ignore. It is an internal implementation error. 469 State: IDLE 471 Event: Internal New NH 473 New State: IDLE 475 Actions: 477 Ignore. It is an internal implementaion error. 479 3.1.5.2 State -- "RESPONSE_AWAITED" 481 State: RESPONSE_AWAITED 483 Event: LDP Request 485 New State: RESPONSE_AWAITED 487 Actions: 489 Ignore the event. It is an internal implementation error. A non VC 490 merge ATM LSR must create a new LSP control block for a new LDP 491 request. 493 State: RESPONSE_AWAITED 495 Event: LDP Mapping 497 New State: ESTABLISHED 499 Actions: 501 1) If the LSP is triggered by the local router(Trigger Control Block 502 Pointer is not zero), send event "Internal LSP UP" to the Trigger 503 control block. 505 2) Else If the LSR uses the ordered control mode, choose an upstream 506 label. 508 3) Connect the upstream label to the downstream label. Allocate the 509 resources. propagate the LDP-MAPPING message upstream with the 510 upstream label. 512 If unable to process the message, disconnect the upstream label from 513 the downstream label, free the upstream label, release the resources, 514 send an LDP-RELEASE message downstream and an LDP-Nak upstream with 515 status (No Label Resources[ref-5]), and delete the LSP_Control_Block. 517 State: RESPONSE_AWAITED 519 Event: LDP Release 520 New State: IDLE 522 Actions: 524 If the LSR uses the independent control mode, free the upstream 525 label. 527 Send an LDP-ABORT message downstream and delete the 528 LSP_Control_Block. 530 State: RESPONSE_AWAITED 532 Event: LDP Withdraw 534 New State: RESPONSE_AWAITED 536 Actions: 538 Ignore the event. It's a protocol error from the downstream LSR. 540 State: RESPONSE_AWAITED 542 Event: LDP Upstream Abort 544 New State: IDLE 546 Actions: 548 If the LSR uses the independent control mode, free the upstream 549 label. 551 Send an LDP-ABORT message downstream. 553 Delete the LSP_Control_Block. 555 State: RESPONSE_AWAITED 557 Event: LDP Downstream Nak 559 New State: Depends on the action routine 561 Actions: 563 1. If the LSP is triggered by the local router(Trigger Control Block 564 Pointer is not zero), send event "Internal LSP DOWN" to the Trigger 565 control block. 567 2. Else If the LSR uses the independent control mode, send an LDP- 568 WITHDRAW message upstream and go to state 'RELEASE_AWAITED'. 570 If the LSR uses the ordered control mode, send an LDP-NAK message 571 upstream. Then delete the control block. 573 State: RESPONSE_AWAITED 575 Event: Upstream Lost 577 New State: IDLE 579 Actions: 581 If the LSR uses the independent control mode, free the upstream 582 label. 584 Send an LDP-ABORT downstream and delete the LSP_Control_Block. 586 State: RESPONSE_AWAITED 588 Event: Downstream Lost 590 New State: Depends on the action routine 592 Actions: 594 1. If the LSP is triggered by the local router(Trigger Control Block 595 Pointer is not zero), send event "Internal LSP DOWN" to the trigger 596 control block. 598 2. Else, If the LSR uses the independent control mode, free the 599 upstream label and send an LDP-WITHDRAW upstream and go to state 600 'RELEASE_AWAITED'. 602 If the LSR uses the ordered control mode, send an LDP-NAK 603 upstream(with a status No Route[Ref-5]) and then delete the control 604 block. 606 State: RESPONSE_AWAITED 608 Event: Internal SetUp 610 New State: RESPONSE_AWAITED 612 Actions: 614 Ignore, it is an internal implementation error. 616 State: RESPONSE_AWAITED 618 Event: Internal Destroy 620 New State: IDLE 622 Actions: 624 Send an LDP-ABORT downstream and delete the LSP_Control_Block. 626 State: RESPONSE_AWAITED 628 Event: Internal Cross-Connect 630 New State: RESPONSE_AWAITED 632 Actions: 634 Ignore the event. It is an internal implementation error. 636 State: RESPONSE_AWAITED 638 Event: Internal New NH 640 New State: RESPONSE_AWAITED 642 Actions: 644 Send LDP-ABORT to the old downstream, and send LDP-REQUEST to the new 645 next hop. 647 3.1.5.3 State --"ESTABLISHED" 649 State: ESTABLISHED 651 Event: LDP Request 653 New State: ESTABLISHED 655 Actions: 657 Ignore the event. It's an internal implementation error. For non VC- 658 merge ATM LSR, a new LSP control block is always created for each LDP 659 request. 661 State: ESTABLISHED 662 Event: LDP Mapping 664 New State: ESTABLISHED 666 Actions: 668 Process the LDP-MAPPING message, which may contain the new attributes 669 of the label mapping and then propagate the LDP-MAPPING message 670 upstream. 672 State: ESTABLISHED 674 Event: LDP Release 676 New State: IDLE 678 Actions: 680 Disconnect the upstream label from the downstream label. 682 Free the upstream label. 684 Free the resources. 686 Send event "Internal Destroy" to the Next Hop Trigger Block if it was 687 in the middle of switching over to the better next hop. 689 Propagate the LDP-RELEASE message downstream if the LSR is not the 690 end of LSP and delete the LSP_Control_Block. 692 State: ESTABLISHED 694 Event: LDP Withdraw 696 New State: Depends on the action routine. 698 Actions: 700 1) Free the resources and send LDP-RELEASE downstream. 702 2) If it is independent control mode, set the state to 'IDLE', create 703 a internal LDP Request with the information in the LSP_Control_Block, 704 and pass event 'LDP Request' to its own state machine. 706 3) Else for the ordered control mode 708 3.1)If the LSP is triggerd to be setup by itself(e.g it is the 709 ingress LSR of this LSP), send event "Internal LSP NAK" to the 710 trigger control block and delete the control block 712 3.2) else, if it is triggered by the incoming LDP Request, 713 Disconnect the upstream label from the downstream label. And 714 Propagate the LDP-WITHDRAW message upstream and go to state 715 'RELEASE_AWAITED'. 717 3.3) If the LSP is in the middle of switching over to a better LSP, 718 send event 'Internal Destroy' to the state machine of its New Next 719 Hop LSP Control Block. 721 State: ESTABLISHED 723 Event: LDP Upstream Abort 725 New State: IDLE 727 Actions: 729 Disconnect the upstream label from the downstream label. 731 Free the upstream label. 733 Send event "Internal Destroy" if the LSR was in the middle of 734 switching over to the better next hop. 736 Propagate an LDP-RELEASE message downstream and delete the 737 LSP_Control_Block. 739 State: ESTABLISHED 741 Event: LDP Downstream Nak 743 New State: ESTABLISHED 745 Actions: 747 Ignore the event. It is a protocol error from the downstream LSR. 748 The downstream LSR should always LSP-WITHDRAW msg to tear down the 749 LSP when the LSP is established. 751 State: ESTABLISHED 753 Event: Upstream Lost 755 New State: IDLE 757 Actions: 759 Disconnect the upstream label from the downstream label. 761 Free the upstream label. 763 Send event "Internal Destroy" to the Next Hop Trigger Control Block 764 if it was in the middle of switching over to the better next hop. 766 Free the resources. 768 Propagate an LDP-RELEASE message downstream and delete the 769 LSP_Control_Block. 771 State: ESTABLISHED 773 Event: Downstream Lost 775 New State: Depends on the actions 777 Actions: 779 1) If the LSP is triggered by the local router(Trigger Control Block 780 Pointer is not zero), send event "Internal LSP NAK" to the Trigger 781 control block and delete the control block. 783 2) Else, disconnect the upstream label from the downstream label. 784 Propagate an LDP-WITHDRAW message upstream and go to state 785 'RELEASE_AWAITED' state. 787 3) Send event "Internal Destroy" to the Next Hop Trigger Control 788 Block if it was in the middle of switching over to the better next 789 hop. 791 State: ESTABLISHED 793 Event: Internal Setup 795 New State: ESTABLISHED 797 Actions: 799 Ignore, it is an internal implementation error. 801 State: ESTABLISHED 803 Event: Internal Destroy 805 New State: IDLE 806 Actions: 808 Disconnect the upstream label from the downstream label if it is not 809 the ingress of the LSP. 811 Free the resources. 813 Send an LDP-RELEASE message downstream and delete the 814 LSP_Control_Block. 816 State: ESTABLISHED 818 Event: Internal Cross-Connect 820 New State: ESTABLISHED 822 Actions: 824 Connect the upstream label to the downstream label 826 May need to send a new LDP-MAPPING upstream with the attributes from 827 the new next hop. 829 Reset Trigger Control Block Pointer to zero. 831 State: ESTABLISHED 833 Event: Internal New NH 835 New State: ESTABLISHED 837 Actions: 839 1) If the LSR was in the middle of switching over to a better next 840 hop(Next Hop Trigger Control Block Pointer is not zero), it send 841 "Internal New NH" to that control block. 843 2) Else, create a new Next Hop Trigger Control Block, set Next Hop 844 Trigger Control Block pointer which points this control block. And 845 then pass "Internal New NH" to this control block. 847 3.1.5.4 State --"RELEASE_AWAITED" 849 State RELEASE_AWAITED 851 Event LDP Request 852 New State: RELEASE_AWAITED 854 Actions: 856 Ignore the event. It is an internal implementation error. 858 State RELEASE_AWAITED 860 Event LDP Mapping 862 New State: RELEASE_AWAITED 864 Actions: 866 It is an protocol error from the downstream LDP peer, but anyway send 867 a LDP-RELEASE downstream. 869 State RELEASE_AWAITED 871 Event LDP Release 873 New State: IDLE 875 Actions: 877 1) Free the upstream label 879 2) Delete the control block. 881 State RELEASE_AWAITED 883 Event LDP Withdraw 885 New State: RELEASE_AWAITED 887 Actions: 889 It is an protocol error from the downstream LDP peer, but send a 890 LDP-RELEASE anyway. 892 State RELEASE_AWAITED 894 Event LDP Upstream Nak 896 New State: IDLE 898 Actions: 900 1) Free the upstream label 902 2) Delete the control block. 904 State RELEASE_AWAITED 906 Event LDP Downstream Nak 908 New State: RELEASE_AWAITED 910 Actions: 912 Ignore the event. Continue waiting for the LDP-RELEASE from upstream. 914 State RELEASE_AWAITED 916 Event Upstream Lost 918 New State: IDLE 920 Actions: 922 1) Free the upstream label 924 2) Delete the control block. 926 State RELEASE_AWAITED 928 Event Downstream Lost 930 New State: RELEASE_AWAITED 932 Actions: 934 Ignore the event. Continue waiting for the LDP-RELEASE from upstream. 936 State RELEASE_AWAITED 938 Event Internal SetUp 940 New State: RELEASE_AWAITED 942 Actions: 944 Ignore the event. It is an internal implementation error. 946 State RELEASE_AWAITED 948 Event Internal Destroy 950 New State: RELEASE_AWAITED 952 Actions: 954 Ignore the event. It is an internal implementation error. 956 State RELEASE_AWAITED 958 Event Internal Cross-Connect 960 New State: RELEASE_AWAITED 962 Actions: 964 Ignore the event. It is an internal implementation error. 966 3.1.6 Handling the Next Hop Change 968 When an LSR detects a better next hop, it may decides to establish a 969 new LSP through this next hop. For example, an LSR is configured as 970 "local repair", or the LSR is configured as "global repair" and it is 971 the ingress end of a LSP. It can then create a Next Hop Trigger 972 Control Block and use the state machine of Next Hop Trigger Control 973 Block to establish a new LSP through the better next hop. 975 3.1.6.1 Next Hop Trigger Control Block 977 -- LSP Control Block Pointer, which points to the original LSP 978 control block. 980 -- New Next Hop LSP Control Block Pointer, which points to the LSP 981 Control Block that is setting up an LSP through the new next hop. 983 3.1.6.2 States 985 -- IDLE 987 This is the initial LSP state, when the Trigger_Control_Block is 988 created. 990 -- NEW_NH_RETRY 991 This is the state where an LSR waits for a retry timer to expire and 992 then tries to establish an LSP through a new next hop. 994 -- NEW_NH_RESPONSE_AWAITED 996 This is the state where an LSR is in the middle of establishing a new 997 LSP through a new next hop. It has triggered a LSP control block to 998 send an LDP-REQUEST towards the new next hop and is waiting for the 999 LDP-MAPPING message. 1001 3.1.6.3 Events 1003 -- Internal New NH 1005 The LSR detects there is a new next hop for a FEC. 1007 -- Internal Retry Timeout 1009 The LSP retry timer expires. 1011 -- Internal LSP UP 1013 The LSP to the new Next Hop is UP 1015 -- Internal LSP NAK 1017 The LSP through the new next hop could not get set up 1019 -- Internal Destroy 1021 This event is triggered when the LSR lost the LDP session with its 1022 upstream neighbor. 1024 3.1.6.4 State Transition for next hop change 1026 | 1027 | 1028 | 1029 | Internal New NH 1030 | 1031 v 1032 +---------------------+ 1033 | | Internal destroy 1034 | NEW_NH_RETRY |-------------- 1035 | | | 1036 +---------------------+ | 1037 | | 1038 | | 1039 | (Internal retry timeout) | 1040 | | 1041 v | 1042 +---------------------+ | 1043 | | Internal | 1044 | NEW_NH_RESPONSE | Destroy | 1045 | _AWAITED |-------------| 1046 | | | 1047 +---------------------+ | 1048 | | 1049 | (Internal LSP UP) | 1050 | (Internal LSP NAK) | 1051 v v 1052 the control block is deleted 1054 3.01.3 State Machine 1056 3.01.3.1 State -- "IDLE" 1058 State: IDLE 1060 Event: Internal New NH 1062 New States: NEW_NH_RETRY 1064 Actions: 1066 Start the LSP retry timer and go to the 'NEW_NH_RETRY' state. 1068 State: IDLE 1070 Event: Internal retry timeout 1071 New States: IDLE 1073 Actions: 1075 Ignore. It is an internal implementation error. 1077 State: IDLE 1079 Event: Internal LSP UP 1081 New States: IDLE 1083 Actions: 1085 Ignore. It is an internal implementation error. 1087 State: IDLE 1089 Event: Internal LSP NAK 1091 New States: IDLE 1093 Actions: 1095 Ignore. It is an internal implementation error. 1097 State: IDLE 1099 Event: Internal destroy 1101 New States: IDLE 1103 Actions: 1105 Ignore. It is an internal implementation error. 1107 3.01.3.2 State -- "NEW_NH_RETRY" 1109 State: NEW_NH_RETRY 1111 Event: Internal New NH 1113 New States: NEW_NH_RETRY 1115 Actions: 1117 Restart the LSP retry timer. 1119 State: NEW_NH_RETRY 1121 Event: Internal retry timeout 1123 New States: NEW_NH_RESPONSE_AWAITED 1125 Actions: 1127 If the new next hop is the same one as the old next hop, delete the 1128 control block. 1130 Otherwise, create an LSP control block which will try to establish a 1131 new LSP through the new next hop. And send event "Internal Setup" to 1132 its state machine. 1134 State: NEW_NH_RETRY 1136 Event: Internal LSP UP 1138 New States: NEW_NH_RETRY 1140 Actions: 1142 Ignore. It is an internal implementation error. 1144 State: NEW_NH_RETRY 1146 Event: Internal LSP NAK 1148 New States: NEW_NH_RETRY 1150 Actions: 1152 Ignore. It is an internal implementation error. 1154 State: NEW_NH_RETRY 1156 Event: Internal destroy 1158 New States: IDLE 1160 Actions: 1162 Stop the timer and delete the control block. 1164 3.01.3.3 State -- "NEW_NH_RESPONSE_AWAITED" 1165 State: NEW_NH_RESPONSE_AWAITED 1167 Event: Internal New NH 1169 New States: NEW_NH_RETRY 1171 Actions: 1173 Restart the LSP retry timer, send "Internal destroy" to the control 1174 block of the LSP for the new next hop and go to the 'NEW_NH_RETRY' 1175 state. 1177 State: NEW_NH_RESPONSE_AWAITED 1179 Event: Internal retry timeout 1181 New States: NEW_NH_RESPONSE_AWAITED 1183 Actions: 1185 Ignore. It is an internal implementation error. 1187 State: NEW_NH_RESPONSE_AWAITED 1189 Event: Internal LSP UP 1191 New States: IDLE 1193 Actions: 1195 Send event "Internal cross-connect" event to the LSP control block of 1196 the new next hop. 1198 Send event "Internal destroy" event to the original LSP control 1199 block. 1201 Then delete the control block. 1203 State: NEW_NH_RESPONSE_AWAITED 1205 Event: Internal LSP NAK 1207 New States: IDLE 1209 Actions: 1211 Delete the control block. 1213 State: NEW_NH_RESPONSE_AWAITED 1215 Event: Internal destroy 1217 New States: IDLE 1219 Actions: 1221 Send event "Internal destroy" the control block for the new LSP 1222 through the new next hop. 1224 3.1.7 LDP Related Message Handling 1226 - If an LSR receives an LDP-REQUEST from an upstream LSR: 1228 a) If this is a duplicate request, discard the msg. A duplicate 1229 request means that there is a LSP_Control_Block which has same FEC, 1230 same Upstream Label Request ID and same Upstream LDP Session 1231 Identifier. 1233 b) Otherwise, create a new LSP_Control_Block, store the relevant 1234 information from the message into the control block, then pass the 1235 event `LDP Request' to its state machine. 1237 - If an LSR receives an LDP-MAPPING from a downstream LSR: 1239 a) Extract the 'Label Request Message ID' field and from the LDP- 1240 MAPPING message. 1242 b) Find an LSP_Control_Block which has the same Downstream Label 1243 Request ID and the same Downstream LDP Session Identifier. 1245 c) If an LSP_Control_Block is found, pass the event `LDP Mapping' to 1246 its state machine. 1248 d) If there is no matching LSP_Control_Block found, then try to find 1249 an LSP_Control_Block which has the same Downstream Lable and the same 1250 Downstream LDP Session Identifier. 1252 e) If an LSP_Control_Block is found, pass the event 'LDP Mapping' to 1253 its state machine. 1255 f) Otherwise, ignore the LDP-MAPPING message and send a LDP-RELEASE 1256 message downstream. 1258 - If an LSR receives an LDP-RELEASE from an upstream LSR: 1260 a) Find an LSP_Control_Block which has the same Upstream Label and 1261 the same Upstream LDP Session Identifier. 1263 b) If an LSP_Control_Block is found, pass the event 'LDP Release' to 1264 its state machine. 1266 c) Otherwise, ignore the message. 1268 - If an LSR receives an LDP-WITHDRAW from a downstream LSR: 1270 a) Find an LSP_Control_Block which has the same Downstream Label and 1271 the same Downstream LDP Session Identifier. 1273 b) If an LSP_Control_Block is found, pass the event 'LDP Withdraw' to 1274 its state machine. 1276 c) Otherwise, ignore the LDP-WITHDRAW message and send a LDP-RELEASE 1277 message downstream. 1279 - If an upstream LDP peer is lost: 1281 a) Find all the LSP_Control_Blocks whose upstream LDP peer is that 1282 LSR. 1284 b) Then pass the event 'Upstream Lost' to their state machines. 1286 - If a downstream LDP peer is lost: 1288 a) Find all the LSP_Control_Blocks whose downstream LDP peer is that 1289 LSR. 1291 b) Then pass the event 'Downstream Lost' to their state machines. 1293 - If the LSR detects a new next hop for an FEC: 1295 For each LSP which needs "local repair", or it needs "global repair" 1296 and it is the ingress of the LSP, pass event "Internal New NH" to its 1297 state machine. 1299 - If an LSR receives an LDP-Abort from an upstream LSR: 1301 a) Extract the LDP Request ID value from the LDP-Abort message. 1303 b) Find an LSP_Control_Block which has the same Upstream Label 1304 Request ID and the same Upstream LDP Session Identifier. 1306 c) If an LSP_Control_Block is found, pass the event 'LDP Upstream 1307 Abort' to its state machine. 1309 d) Otherwise, ignore the message. 1311 - If the LSR receives an LDP-NAK from a downstream LSR: 1313 a) Extract the LDP Request ID value from the LDP-NAK. 1315 b) Find an LSP_Control_Block which has the same Downstream Label 1316 Request ID and the same Downstream LDP Session Identifier. 1318 c) If an LSP_Control_Block is found, pass the event 1320 d) Otherwise, ignore the message. 1322 3.2. ATM Switch LSR with VC-merge 1324 3.2.1 VC-merge 1326 A VC-merge capable LSR can map multiple incoming labels(VPI/VCI) into 1327 one outgoing label. It is possible that this LSR can only merge a 1328 limited number of incoming labels into a single outgoing label. As 1329 described in [Ref2], suppose, for example, that due to some hardware 1330 limitation a node is capable of merging four incoming labels into a 1331 single outgoing label. Suppose however, that this particular node has 1332 six incoming labels arriving at it for a particular FEC. In this 1333 case, this node may merge these into two outgoing labels. 1335 When an upstream LSR has a limited merging capability, it is 1336 difficult for a downstream LSR to know how many labels should be 1337 assigned to each FEC. In this case, downstream-on-demand is 1338 recommended. 1340 3.2.2 Control Block 1342 There are 3 types of control blocks involved: 1343 Upstream_LSP_Control_Block, Downstream_LSP_Control_Block, and Next 1344 Hop Trigger Control Block. 1346 There is one Upstream_LSP_Control_Block for each LDP-REQUEST 1347 received. 1349 There is one Downstream_LSP_Control_Block for each unique LDP- 1350 REQUEST sent to a downstream LSR. There can be multiple 1351 Downstream_LSP_Control_Blocks per FEC in an LSR. This can be the 1352 result of an upstream LSR asking for a label of an FEC. This LSR must 1353 assign a unique upstream label and it can not merge this upstream 1354 label into an existing downstream label of this FEC. 1356 There is one Next Hop Trigger Control Block for each FEC which was 1357 detected with a better next hop and the LSR decides to switch over to 1358 this better next hop. It could be the result of "local repair" or 1359 "global repair" if the LSR is the ingress LSR of the LSP. 1361 A Downstream_LSP_Control_Block contains a list of pointers to 1362 Upstream_LSP_Control_Blocks or the Next Hop Trigger Control Block. 1363 This means that this LSR has decided to map the multiple labels 1364 listed in the Upstream_LSP_Control_Blocks and the Next Hop Trigger 1365 Control Block into a single label listed in the 1366 Downstream_LSP_Control_Block. 1368 An Upstream_LSP_Control_Block may contain the following information: 1370 - Upstream LDP Session Identifier 1372 - State 1374 - Upstream Label(assigned by this LSR) 1376 - Downstream_LSP_Control_Block pointer 1378 - Upstream LDP Request ID (assigned by the Upstream LSR in 1379 downstream-on-demand mode) 1381 - Next_Hop_Trigger_Block pointer 1383 Upstream Label and Upstream LDP Session Identifier can be used to 1384 locate a unique Upstream_LSP_Control_Block. 1386 If an LSR is using downstream-on-demand mode, it can use the Upstream 1387 LDP Request ID and the Upstream LDP Session Identifier to locate a 1388 unique Upstream_LSP_Control_Block. 1390 An Next_Hop_Trigger_LSP_Control_Block may contain the following 1391 information: 1393 - Upstream_LSP_Control_Block pointer, which points to the one 1394 which is needed to switch over to the better next hop 1396 - State 1398 - Downstream_LSP_Control_Block pointer 1400 A Downstream_LSP_Control_Block may contain the following information: 1402 - FEC 1403 - State 1405 - Downstream LDP Session Identifier 1407 - list of pointers to the Upstream_LSP_Control_Blocks or the 1408 Trigger_Control_Blocks which are merged at this LSR for this 1409 FEC 1411 - Downstream Label(assigned by the downstream LSR) 1413 - Downstream Label Request ID (assigned by the LSR itself if 1414 it is using downstream-on-demand mode) 1416 Downstream Label, Downstream LDP Session Identifier can be used to 1417 locate a unique Downstream_LSP_Control_Block. 1419 If an LSR is using downstream-on-demand mode, it can also use the 1420 Downstream Label Request ID and the Downstream LDP Session Identifier 1421 to locate a unique Downstream_LSP_Control_Block. 1423 The following diagram details the relationship between these 2 types 1424 of control blocks: 1426 For example, the LSR has decided to merge 3 LDP-REQUESTs of a FEC 1427 from upstream LSR1,LSR2,LSR3 into one LDP-REQUEST and sent it to a 1428 downstream LSR4. 1430 +---------------------+ 1431 | | 1432 | Upstream_LSP_Control| 1433 | _Block for Upstream|-------+ 1434 | LSR1 | | 1435 +---------------------+ | 1436 | 1437 | 1438 | 1439 | 1440 | 1441 +---------------------+ | 1442 | | | 1443 | Upstream_LSP_Control| | (merged into) 1444 | _Block for Upstream |-------+ 1445 | LSR2 | | 1446 +---------------------+ | 1447 | 1448 | 1449 | 1450 | +------------------------------+ 1451 | | | 1452 +-->| Downstream_LSP_Control_Block | 1453 | | for Downstream LSR4 | 1454 | | | 1455 | +------------------------------+ 1456 | 1457 +---------------------+ | 1458 | Next_Hop_Trigger_ | | 1459 | LSP_Control_Block | | 1460 | |-------+ 1461 | | 1462 +---------------------+ 1464 3.2.3 State Machines for Downstream-on-demand Mode 1466 The following sections describe the state machines used in 1467 downstream-on-demand mode. 1469 3.2.3.1 State of the Upstream_LSP_Control_Block's State Machine 1470 for Downstream-on-demand Mode 1472 -- IDLE 1474 This is the initial LSP state. 1476 -- RESPONSE_AWAITED 1477 This state means that the LSR has received and processed an LDP- 1478 REQUEST from an upstream LSR, and has sent a new LDP-REQUEST towards 1479 a downstream LSR. The LSR is waiting for the LDP-MAPPING message from 1480 the downstream LSR. 1482 -- ESTABLISHED 1484 This state means that the LSR has received the LDP-MAPPING message 1485 from the downstream LSR and the LSP is up and operational. 1487 -- RELEASE_AWAITED 1489 This state means that the LSR has sent a LDP-WITHDRAW message 1490 upstream and is waiting for the LDP-RELEASE before freeing up the 1491 label resource. 1493 3.2.3.2 Events of the Upstream_LSP_Control_Block's State Machine 1494 for Downstream-on-demand Mode 1496 -- LDP Request 1498 The LSR receives an LDP-REQUEST from an upstream LSR. 1500 -- Internal Downstream Mapping 1502 This event is sent by one Downstream_LSP_Control_Block's state 1503 machine. This Downstream_LSP_Control_Block is the merged 1504 Downstream_LSP_Control_Block of this Upstream_LSP_Control_Block. The 1505 event is the result of receiving an LDP-MAPPING message by the 1506 Downstream_LSP_Control_Block's state machine. 1508 -- LDP Release 1510 The LSR receives an LDP-RELEASE from an upstream LSR. 1512 -- Internal Downstream Withdraw 1514 This event is sent by one Downstream_LSP_Control_Block's state 1515 machine. This Downstream_LSP_Control_Block is the merged 1516 Downstream_LSP_Control_Block of this Upstream_LSP_Control_Block. The 1517 event is the result of receiving an LDP-WITHDRAW message by the 1518 Downstream_LSP_Control_Block's state machine. 1520 -- LDP Upstream Abort 1522 The LSR receives an LDP-ABORT from an upstream LSR. 1524 -- Internal Downstream Nak 1526 This event is sent by one Downstream_LSP_Control_Block's state 1527 machine. This Downstream_LSP_Control_Block is the merged 1528 Downstream_LSP_Control_Block of this Upstream_LSP_Control_Block. The 1529 event is the result of receiving an LDP-NAK message by the 1530 Downstream_LSP_Control_Block's state machine, or it detects an error. 1532 -- Upstream Lost 1534 The LSR loses the LDP session with its upstream LDP peer. 1536 -- Internal New NH 1538 The LSR detects there is better next hop and decides to establish the 1539 lsp through this better next hop 1541 -- Internal Re-Cross-Connect 1543 This event is used to trigger splicing into a different downstream 1544 LSP. This can happens when it is switched over to a better LSP 1545 through the new next hop. 1547 3.2.3.3 State Transitions of the Upstream_LSP_Control_Block's State 1548 Machine for Downstream-on-demand Mode 1550 +-------------------+ 1551 | | 1552 +-------->| IDLE |<------------+ 1553 | | | | 1554 | +-------------------+ | 1555 |(LDP Abort) | | 1556 |(Internal |(LDP Request) | 1557 | Downstream Nak) | | 1558 |(Upstream Lost) | | 1559 | v | 1560 | +-------------------+ | 1561 | | | | 1562 +---------| RESPONSE_AWAITED | | 1563 | | |(Upstream Lost) 1564 +-------------------+ | 1565 | | 1566 |(Internal Downstream | 1567 | mapping) |(LDP Release) 1568 | | 1569 v | 1570 +-------------------+ | 1571 | | |(LDP Abort) 1572 | ESTABLISHED |------->-----+ 1573 | | | 1574 +-------------------+ | 1575 | | 1576 | | 1577 |(Internal Downstream Withdraw) 1578 |(Internal Downstream Nak) 1579 v 1580 +-------------------+ | 1581 | | | 1582 |RELEASE_AWAITED |------->-----+ 1583 | | 1584 +-------------------+ 1586 3.2.3.4 Upstream_LSP_Control_Block's State Machine 1587 for Downstream-on-demand Mode 1589 3.2.3.4.1 State -- "IDLE" 1590 State: IDLE 1592 Event: LDP Request 1594 New State: Depends upon the action routine. 1596 Actions: 1598 If this LSR is the LSP Egress or Proxy Egress [Ref2], 1600 Then: 1602 choose an upstream label, allocate the resources, connect this 1603 upstream label to the local IP forwarding module, send an LDP- 1604 MAPPING upstream with the upstream label and go to the state 1605 'ESTABLISHED'. 1607 else 1609 Obtain a next hop(or interface). Find a 1610 Downstream_LSP_Control_Block which has the same FEC and the same 1611 next hop and also is able to merge more input labels. If not found, 1612 create a new Downstream_LSP_Control_Block with the state 'IDLE'. 1614 If the state of the Downstream_LSP_Control_Block is `ESTABLISHED', 1615 choose an upstream label, connect the upstream label with the 1616 downstream label and send an LDP-MAPPING message upstream with the 1617 upstream label, and go to the state `ESTABLISHED'. 1619 If the state of Downstream_LSP_Control_Block is not `ESTABLISHED', 1620 set the state of the Upstream_LSP_Control_Block to 1621 'RESPONSE_AWAITED'. If the LSR use the independent control 1622 mode[Ref2], choose an upstream label, and send an LDP-MAPPING 1623 message upstream. 1625 Pass the event `Internal AddUpstream' to the 1626 Downstream_LSP_Control_Block's state machine. 1628 If unable to process the request for any reason, issue an LDP-NAK 1629 message to the sender with the appropriate error code and delete the 1630 control block. 1632 State: IDLE 1634 Event: Internal Downstream Mapping 1636 New State: IDLE 1637 Actions: 1639 Ignore the event. It is an internal implementation error. 1641 State: IDLE 1643 Event: LDP Release 1645 New State: IDLE 1647 Actions: 1649 Ignore the event. It is an internal implementation error. 1651 State: IDLE 1653 Event: Internal Downstream Withdraw 1655 New State: IDLE 1657 Actions: 1659 Ignore the event. It is an internal implementation error. 1661 State: IDLE 1663 Event: LDP Upstream Abort 1665 New State: IDLE 1667 Actions: 1669 Ignore the event. It is an internal implementation error. 1671 State: IDLE 1673 Event: Internal Downstream Nak 1675 New State: IDLE 1677 Actions: 1679 Ignore the event. It is an internal implementation error. 1681 State: IDLE 1683 Event: Upstream Lost 1684 New State: IDLE 1686 Actions: 1688 Ignore the event. It is an internal implementation error. 1690 State: IDLE 1692 Event: Internal Re-Cross-Connect 1694 New State: IDLE 1696 Actions: 1698 Ignore the event. It is an internal implementation error. 1700 State: IDLE 1702 Event: Internal New NH 1704 New State: IDLE 1706 Actions: 1708 Ignore the event. It is an internal implementation error. 1710 3.2.3.4.2 State -- "RESPONSE_AWAITED" 1712 State: RESPONSE_AWAITED 1714 Event: LDP Request 1716 New State: RESPONSE_AWAITED 1718 Actions: 1720 Ignore the event. It is an internal implementation error. 1722 State: RESPONSE_AWAITED 1724 Event: Internal Downstream Mapping 1726 New State: Depends on the action routine 1728 Actions: 1730 If the LSR uses the ordered control mode, assign an upstream label. 1732 Connect the upstream label to the downstream label and allocate the 1733 resources. 1735 Send an LDP-MAPPING message upstream with the upstream label. 1737 Then go to the state 'ESTABLISHED'. 1739 If unable to process the message for any reason, issue an LDP-NAK 1740 message upstream and an LDP-RELEASE message downstream and delete the 1741 control block. 1743 State: RESPONSE_AWAITED 1745 Event: LDP Release 1747 New State: RESPONSE_AWAITED 1749 Actions 1751 Ignore the event. It is an protocol error from the upstream peer. 1753 State: RESPONSE_AWAITED 1755 Event: Internal Downstream Withdraw 1757 New State: RESPONSE_AWAITED 1759 Actions 1761 Ignore the event. It is an internal implementation error. 1763 State: RESPONSE_AWAITED 1765 Event: LDP Upstream Abort 1767 New State: IDLE 1769 Actions 1771 If the LSR uses the independent control mode, free the upstream label 1772 and the resources. 1774 Send the event 'Internal DeleteUpstream' to its 1775 Downstream_LSP_Control_Block's state machine. 1777 Delete the control block. 1779 State: RESPONSE_AWAITED 1781 Event: Internal Downstream Nak 1783 New State: IDLE 1785 Actions: 1787 If the LSR uses the independent control mode, free the upstream label 1788 and the resources. Then, send an LDP-WITHDRAW message upstream. 1790 If the LSR uses the ordered control mode, propagate the LDP-NAK 1791 message upstream. 1793 Delete the control block. 1795 State: RESPONSE_AWAITED 1797 Event: Upstream Lost 1799 New State: IDLE 1801 Actions 1803 If the LSR uses the independent control mode, free the upstream label 1804 and the resources. 1806 Send the event 'Internal DeleteUpstream' to its 1807 Downstream_LSP_Control_Block's state machine. 1809 Delete the control block. 1811 State: RESPONSE_AWAITED 1813 Event: Internal Re-Cross-Connect 1815 New State: RESPONSE_AWAITED 1817 Actions: 1819 Ignore the event. It is an internal implementation error. 1821 State: RESPONSE_AWAITED 1823 Event: Internal New NH 1825 New State: depends on the actions 1826 Actions: 1828 Send event "Internal DeleteUpstream" to its old downstream control 1829 block. 1831 Find a Downstream_LSP_Control_Block which has the same FEC and the 1832 same next hop and also is able to merge more input labels. If not 1833 found, create a new Downstream_LSP_Control_Block with the state 1834 'IDLE'. 1836 If the state of the Downstream_LSP_Control_Block is `ESTABLISHED', 1837 choose an upstream label, connect the upstream label with the 1838 downstream label and send an LDP-MAPPING message upstream with the 1839 upstream label, and go to the state `ESTABLISHED'. 1841 If the state of Downstream_LSP_Control_Block is not `ESTABLISHED', 1842 set the state of the Upstream_LSP_Control_Block to 1843 'RESPONSE_AWAITED'. 1845 Pass the event `Internal AddUpstream' to the new 1846 Downstream_LSP_Control_Block's state machine. 1848 3.2.3.4.3 State -- "ESTABLISHED" 1850 State: ESTABLISHED 1852 Event: LDP Request 1854 New State: ESTABLISHED 1856 Actions 1858 Ignore the event. It is an internal implementation error. 1860 State: ESTABLISHED 1862 Event: Internal Downstream Mapping 1864 New State: ESTABLISHED 1866 Actions 1868 Process the new attributes of the mapping and then propagate the 1869 LDP-MAPPING message upstream. 1871 State: ESTABLISHED 1872 Event: LDP Release 1874 New State: IDLE 1876 Actions 1878 Disconnect the upstream label from the downstream label, free the 1879 upstream label and resources. 1881 Send the event 'Internal DeleteUpstream' to its 1882 Downstream_LSP_Control_Block's state machine. 1884 Send the event "Internal Destroy' to the Next_Hop_Trigger_Block's 1885 state machine if the LSR was in the middle of switching over to the 1886 better next hop. 1888 Delete the control block. 1890 State: ESTABLISHED 1892 Event: Internal Downstream Withdraw 1894 New State: Depends on the action routine 1896 Actions 1898 If it uses independent mode,set its state to 'IDLE' and create a 1899 internal 'LDP Request' and send to its own state machine. 1901 Else 1902 Disconnect the upstream label from the downstream label. 1904 Propagate the LDP-WITHDRAW upstream and go to state 1905 'RELEASE_AWAITED'. 1907 Send the event "Internal Destroy' to the Next_Hop_Trigger_Block's 1908 state machine if the LSR was in the middle of switching over to the 1909 better next hop. 1911 State: ESTABLISHED 1913 Event: LDP Upstream Abort 1915 New State: IDLE 1917 Actions 1919 Disconnect the upstream label from the downstream label, free the 1920 upstream label and the resources. 1922 Send the event 'Internal DeleteUpstream' to its 1923 Downstream_LSP_Control_Block's state machine. 1925 Send the event "Internal Destroy' to the Next_Hop_Trigger_Block's 1926 state machine if the LSR was in the middle of switching over to the 1927 better next hop. 1929 Delete the control block. 1931 State: ESTABLISHED 1933 Event: Internal Downstream Nak 1935 New State: Depends on the actions 1937 Actions: 1939 If it uses independent mode,set its state to 'IDLE' and create a 1940 internal 'LDP Request' and send to its own state machine. 1942 Else 1943 Disconnect the upstream label from the downstream label 1945 Send an LDP-WITHDRAW upstream and go to state 'RELEASE_AWAITED'. 1947 Send the event "Internal Destroy' to the Next_Hop_Trigger_Block's 1948 state machine if the LSR was in the middle of switching over to the 1949 better next hop. 1951 State: ESTABLISHED 1953 Event: Upstream Lost 1955 New State: IDLE 1957 Actions: 1959 Disconnect the upstream label from the downstream label, free the 1960 upstream label and the resources. 1962 Send the event 'Internal DeleteUpstream' to its 1963 Downstream_LSP_Control_Block's state machine. 1965 Send the event "Internal Destroy' to the Next_Hop_Trigger_Block's 1966 state machine if the LSR was in the middle of switching over to the 1967 better next hop. 1969 Delete the control block. 1971 State: ESTABLISH 1973 Event: Internal Re-Cross-Connect 1975 New State: ESTABLISH 1977 Actions: 1979 Reconnect the upstream lable to the new downstream lable. 1981 Send the event 'Internal DeleteUpstream' to its old 1982 Downstream_LSP_Control_Block's state machine. 1984 State: ESTABLISH 1986 Event: Internal New NH 1988 New State: ESTABLISH 1990 Actions: 1992 Create a new Next_Hop_Trigger_Control_Block and pass event 1994 3.2.3.4.4 State -- "RELEASE_AWAITED" 1996 State: RELEASE_AWAITED 1998 Event: LDP Request 2000 New State: RELEASE_AWAITED 2002 Actions: 2004 Ignore the event. It is a protocol error from the upstream LSR. 2006 State: RELEASE_AWAITED 2008 Event: Internal Downstream Mapping 2010 New State: RELEASE_AWAITED 2012 Actions: 2014 Ignore the event. It is an internal implementatin error. 2016 State: RELEASE_AWAITED 2017 Event: LDP Release 2019 New State: IDLE 2021 Actions: 2023 Free the upstream lable resource. and delete the control block. 2025 State: RELEASE_AWAITED 2027 Event: Internal Downstream Withdraw 2029 New State: RELEASE_AWAITED 2031 Actions: 2033 Ignore the event. It is a protocol error from the downstream LSR. 2035 State: RELEASE_AWAITED 2037 Event: LDP Upstream Abort 2039 New State: IDLE 2041 Actions: 2043 Free the upstream lable resource. and delete the control block. 2045 State: RELEASE_AWAITED 2047 Event: Internal Downstream Nak 2049 New State: RELEASE_AWAITED 2051 Actions: 2053 Ignore the event. And continue waiting for the LDP-RELEASE msg. 2055 State: RELEASE_AWAITED 2057 Event: Upstream Lost 2059 New State: IDLE 2061 Actions: 2063 Free the upstream lable resource. and delete the control block. 2065 State: RELEASE_AWAITED 2067 Event: Internal New NH 2069 New State: RELEASE_AWAITED 2071 Actions: 2073 Ignore the event. And continue waiting for the LDP-RELEASE msg. 2075 State: RELEASE_AWAITED 2077 Event: Internal Re-Cross-Connect 2079 New State: RELEASE_AWAITED 2081 Actions: 2083 Ignore the event. It is an internal implementation error. 2085 3.2.3.5 State of the Downstream_LSP_Control_Block's State Machine 2086 for Downstream-on-demand Mode 2088 -- IDLE 2090 This is the initial LSP state. 2092 -- RESPONSE_AWAITED 2094 This state means that the LSR has received an LDP-REQUEST from an 2095 upstream LSR, has processed the LDP-REQUEST, and has sent a new LDP- 2096 REQUEST towards a downstream LSR. The LSR is waiting for the LDP- 2097 MAPPING message from the downstream LSR. 2099 -- ESTABLISHED 2101 This state means that the LSR has received the LDP-MAPPING message 2102 from the downstream LSR and the LSP is up and operational. 2104 3.2.3.6 Events of the Downstream_LSP_Control_Block's State Machine 2105 for Downstream-on-demand Mode 2107 -- Internal AddUpstream 2109 This event is sent by an Upstream_LSP_Control_Block's state machine 2110 when it is created. 2112 -- Internal DeleteUpstream 2114 This event is sent by an Upstream_LSP_Control_Block's state machine 2115 when it is deleted. 2117 -- LDP Mapping 2119 The LSR receives an LDP-MAPPING message from a downstream LSR. 2121 -- LDP Withdraw 2123 The LSR receives an LDP-WITHDRAW message from a downstream LSR. 2125 -- LDP Downstream Nak 2127 The LSR receives an LDP-NAK from a downstream LSR. 2129 -- Downstream Lost 2131 The LSR loses the LDP session with its downstream LSR. 2133 3.2.3.7 State Transitions of the Downstream_LSP_Control_Block'S 2134 State Machine for Downstream-on-demand mode 2136 +-------------------+ 2137 | | 2138 | IDLE |<--------------+ 2139 | | |(last Internal 2140 +-------------------+ | DeleteUpstream) 2141 | |(LDP Withdraw) 2142 |(1st Internal AddUpstream)| 2143 | |(LDP Downstream 2144 v | Nak) 2145 +-------------------+ |(Downstream 2146 | | | Lost) 2147 | RESPONSE_AWAITED |---------->----^ 2148 | | | 2149 +-------------------+ | 2150 | | 2151 |(LDP Mapping) | 2152 | | 2153 v | 2154 +-------------------+ | 2155 | | | 2156 | ESTABLISHED |-------->------^ 2157 | | 2158 +-------------------+ 2160 3.2.3.8 Downstream_LSP_Control_Block'S State Machine for 2161 Downstream-on-demand Mode. 2163 3.2.3.8.1 State -- "IDLE" 2165 State: IDLE 2167 Event: Internal AddUpstream 2169 New State: RESPONSE_AWAITED 2171 Actions 2173 Initialize the list of pointers in the Upstream_LSP_Control_Block to 2174 contain the newly added upstream pointer. 2176 Send a new LDP-REQUEST downstream and go to the state 2177 'RESPONSE_AWAITED'. 2179 State: IDLE 2181 Event: Internal DeleteUpstream 2183 New State: IDLE 2185 Actions 2187 Ignore the event. It is an internal implementation error. 2189 State: IDLE 2191 Event: LDP Mapping 2193 New State: IDLE 2195 Actions 2197 Ignore the event. It is an internal implementation error. 2199 State: IDLE 2201 Event: LDP Withdraw 2203 New State: IDLE 2205 Actions 2207 Ignore the event.It is an internal implementation error. 2209 State: IDLE 2211 Event: LDP Downstream Nak 2213 New State: IDLE 2215 Actions 2217 Ignore the event. It is an internal implementation error. 2219 State: IDLE 2221 Event: Downstream Lost 2223 New State: IDLE 2225 Actions 2226 Ignore the event. It is an internal implementation error. 2228 3.2.3.8.2 State -- "RESPONSE_AWAITED" 2230 State: RESPONSE_AWAITED 2232 Event: Internal AddUpstream 2234 New State: RESPONSE_AWAITED 2236 Actions 2238 Add the pointer to new Upstream_LSP_Control_Block to the 2239 Upstream_LSP_Control_Blocks pointer list. 2241 State: RESPONSE_AWAITED 2243 Event: Internal DeleteUpstream 2245 New State: Depend on the action routine 2247 Actions 2249 Delete the Upstream_LSP_Control_Block pointer from the 2250 Upstream_LSP_Control_Block pointers list. 2252 If the list becomes empty, release the resources, send an LDP-Abort 2253 downstream, and then delete the control block. 2255 State: RESPONSE_AWAITED 2257 Event: LDP Mapping 2259 New State: ESTABLISHED 2261 Actions 2263 For each Upstream_LSP_Control_Block in the Upstream_LSP_Control_Block 2264 pointers list, pass the event 'Internal Downstream Mapping' to its 2265 state machine. 2267 State: RESPONSE_AWAITED 2269 Event: LDP Withdraw 2271 New State: RESPONSE_AWAITED 2273 Actions 2274 It is a protocol error from the downstream LDP peer and send a LDP- 2275 RELEASE msg downstream 2277 State: RESPONSE_AWAITED 2279 Event: LDP Downstream Nak 2281 New State: IDLE 2283 Actions 2285 For each Upstream_LSP_Control_Block in the Upstream_LSP_Control_Block 2286 pointers list, pass the event 'Internal Downstream Nak' to its state 2287 machine. 2289 Release the resources, and delete the control block. 2291 State: RESPONSE_AWAITED 2293 Event: Downstream Lost 2295 New State: IDLE 2297 Actions 2299 For each Upstream_LSP_Control_Block in the 2300 Upstream_LSP_Control_Block pointers list, pass the event 'Internal 2301 Downstream Nak' to its state machine. 2303 Release the resources, and delete the control block. 2305 3.2.3.8.3 State -- "ESTABLISHED" 2307 State: ESTABLISHED 2309 Event: Internal AddUpstream 2311 New State: ESTABLISHED 2313 Actions 2315 Add the pointer to new Upstream_LSP_Control_Block to the 2316 Upstream_LSP_Control_Block pointers list. 2318 State: ESTABLISHED 2320 Event: Internal DeleteUpstream 2321 New State: Depends on the action routine 2323 Actions 2325 Delete the pointer of Upstream_LSP_Control_Block from its 2326 Upstream_LSP_Control_Block pointers list. 2328 If the list becomes empty, release the resources, send an LDP-RELEASE 2329 downstream, and then delete the control block. 2331 State: ESTABLISHED 2333 Event: LDP Mapping 2335 New State: ESTABLISHED 2337 Actions 2339 For each Upstream_LSP_Control_Block in the Upstream_LSP_Control_Block 2340 pointers list, pass the event 'Internal Downstream mapping' to its 2341 state machine. 2343 State: ESTABLISHED 2345 Event: LDP Withdraw 2347 New State: IDLE 2349 Actions 2351 For each Upstream_LSP_Control_Block in the Upstream_LSP_Control_Block 2352 pointers list, pass the event 'Internal Downstream withdraw' to its 2353 state machine. 2355 Release the resources, and delete the control block and send LDP- 2356 RELEASE downstream. 2358 State: ESTABLISHED 2360 Event: LDP Downstream Nak 2362 New State: ESTABLISHED 2364 Actions 2366 It is a protocol error from the downstream LDP peer. 2368 3.2.3.9 State of the Next_Hop_Trigger_Control_Block's State Machine 2369 for Downstream-on-demand Mode 2371 -- IDLE 2373 This is the initial LSP state. 2375 -- NEW_NH_RETRY 2377 This is the state where an LSR waits for a retry timer to expire and 2378 then tries to establish an LSP through a new next hop. 2380 -- NEW_NH_RESPONSE_AWAITED 2382 This state means that the LSR has sent a new LDP-REQUEST towards a 2383 downstream LSR. The LSR is waiting for the LDP-MAPPING message from 2384 the downstream LSR. 2386 3.2.3.10 Events of the Next_Hop_Trigger_Control_Block's State Machine 2387 for Downstream-on-demand Mode 2389 -- Internal New NH 2391 Trigger to setup an LSP through a better next hop. 2393 -- Internal Downstream Mapping 2395 This event is sent by one Downstream_LSP_Control_Block's state 2396 machine. This Downstream_LSP_Control_Block is the merged 2397 Downstream_LSP_Control_Block of this Upstream_LSP_Control_Block. The 2398 event is the result of receiving an LDP-MAPPING message by the 2399 Downstream_LSP_Control_Block's state machine. 2401 -- Internal Downstream Nak 2403 This event is sent by one Downstream_LSP_Control_Block's state 2404 machine. This Downstream_LSP_Control_Block is the merged 2405 Downstream_LSP_Control_Block of this Upstream_LSP_Control_Block. The 2406 event is the result of receiving an LDP-NAK message by the 2407 Downstream_LSP_Control_Block's state machine, or it detects an error. 2409 -- Internal Destroy This event is used to stop the procedure of 2410 switching over to the better next hop. 2412 3.2.3.11 State Transitions of the Next_Hop_Trigger_Control_Block's State 2413 Machine for Downstream-on-demand Mode 2415 | 2416 | 2417 | 2418 | Internal New NH 2419 | 2420 v 2421 +---------------------+ 2422 | | Internal destroy 2423 | NEW_NH_RETRY |-------------- 2424 | | | 2425 +---------------------+ | 2426 | | 2427 | | 2428 | (Internal retry timeout) | 2429 | | 2430 v | 2431 +---------------------+ | 2432 | | Internal | 2433 | NEW_NH_RESPONSE | Destroy | 2434 | _AWAITED |-------------| 2435 | | | 2436 +---------------------+ | 2437 | | 2438 | (Internal Downstream | 2439 | Mapping | 2440 | (Internal Downstream | 2441 | Nak) | 2442 v v 2443 the control block is deleted 2445 3.2.3.12 State Machine 2447 3.2.3.12.1 State -- "IDLE" 2449 State: IDLE 2451 Event: Internal New NH 2453 New States: NEW_NH_RETRY 2455 Actions: 2457 Start the LSP retry timer and go to the 'NEW_NH_RETRY' state. 2459 State: IDLE 2461 Event: Internal retry timeout 2463 New States: IDLE 2465 Actions: 2467 Ignore. It is an internal implementation error. 2469 State: IDLE 2471 Event: Internal Downstream Mapping 2473 New States: IDLE 2475 Actions: 2477 Ignore. It is an internal implementation error. 2479 State: IDLE 2481 Event: Internal Downstream Nak 2483 New States: IDLE 2485 Actions: 2487 Ignore. It is an internal implementation error. 2489 State: IDLE 2491 Event: Internal destroy 2493 New States: IDLE 2495 Actions: 2497 Ignore. It is an internal implementation error. 2499 3.2.3.12.2 State -- "NEW_NH_RETRY" 2501 State: NEW_NH_RETRY 2503 Event: Internal New NH 2505 New States: NEW_NH_RETRY 2506 Actions: 2508 Restart the LSP retry timer. 2510 State: NEW_NH_RETRY 2512 Event: Internal retry timeout 2514 New States: NEW_NH_RESPONSE_AWAITED 2516 Actions: 2518 If the new next hop is the same one as the old next hop, delete the 2519 control block. 2521 Otherwise, find an downstream LSP control block which go through the 2522 same next hop for the same FEC, if there is no one, create one, and 2523 pass "Internal AddUpstream'event to its state machine. 2525 State: NEW_NH_RETRY 2527 Event: Internal Downstream Mapping 2529 New States: NEW_NH_RETRY 2531 Actions: 2533 Ignore. It is an internal implementation error. 2535 State: NEW_NH_RETRY 2537 Event: Internal Downstream NAK 2539 New States: NEW_NH_RETRY 2541 Actions: 2543 Ignore. It is an internal implementation error. 2545 State: NEW_NH_RETRY 2547 Event: Internal destroy 2549 New States: IDLE 2551 Actions: 2553 Stop the timer and delete the control block. 2555 3.2.3.12.3 State -- "NEW_NH_RESPONSE_AWAITED" 2557 State: NEW_NH_RESPONSE_AWAITED 2559 Event: Internal New NH 2561 New States: NEW_NH_RETRY 2563 Actions: 2565 Restart the LSP retry timer, send "Internal destroy" to the control 2566 block of the LSP for the new next hop and go to the 'NEW_NH_RETRY' 2567 state. 2569 State: NEW_NH_RESPONSE_AWAITED 2571 Event: Internal retry timeout 2573 New States: NEW_NH_RESPONSE_AWAITED 2575 Actions: 2577 Ignore. It is an internal implementation error. 2579 State: NEW_NH_RESPONSE_AWAITED 2581 Event: Internal Downstream Mapping 2583 New States: IDLE 2585 Actions: 2587 Send event "Internal Re-cross-connect" event to the Upstream LSP 2588 control block of the new next hop. 2590 Send event "DeleteUpstream" event to the downstream LSP control block 2591 of the the new next hop, since the upstream has spliced into the new 2592 next hop. 2594 Then delete the control block. 2596 State: NEW_NH_RESPONSE_AWAITED 2598 Event: Internal Downstream NAK 2600 New States: IDLE 2601 Actions: 2603 Delete the control block. 2605 State: NEW_NH_RESPONSE_AWAITED 2607 Event: Internal destroy 2609 New States: IDLE 2611 Actions: 2613 Send event "Internal DeleteUpstream" the control block for the new 2614 LSP through the new next hop. 2616 3.2.4 LDP Related Message Processing 2618 - If an LSR receives an LDP-REQUEST message: 2620 a) If this is a duplicate request, discard the msg. A duplicate 2621 request means that there is a LSP_Control_Block which has same FEC, 2622 same Upstream Label Request ID and same Upstream LDP Session 2623 Identifier. 2625 b) Otherwise, create a new Upstream_LSP_Control_Block. Then pass the 2626 event `LDP Request' to this Upstream_LSP_Control_Block's state 2627 machine. 2629 - If an LSR receives an LDP-MAPPING message: 2631 Locate a Downstream_LSP_Control_Block which has the same FEC, the 2632 same Downstream LDP Session Identifier and the same Downstream Label. 2633 If a Downstream_LSP_Control_Block is found, pass the event `LDP 2634 Mapping' to its state table. This could mean that the attributes of 2635 label binding have changed. 2637 Otherwise, use the Downstream LDP request ID(the 'Lable Request 2638 Message ID' field in the LDP-MAPPING MSG) and Downstream LDP Session 2639 Identifier to locate the Downstream_LSP_Control_Block and pass the 2640 event `LDP Mapping' to its state machine. If no 2641 Downstream_LSP_Control_Block is found, ignore the message. 2643 - If an LSR receives an LDP-RELEASE message: 2645 Locate an Upstream_LSP_Control_Block which has the same FEC, the same 2646 Upstream Label, the same Upstream LDP Session Identifier. If no 2647 Upstream_LSP_Control_Block is found, ignore the message. If an 2648 Upstream_LSP_Control_Block is found, send the event `LDP Release' to 2649 its state machine. 2651 - If an LSR receives an LDP-WITHDRAW message: 2653 Find a Downstream_LSP_Control_Block which has the same FEC, the same 2654 Downstream LDP Session Identifier and the same Downstream Label. Pass 2655 the event `LDP Withdraw' to its state machines. 2657 - If an Upstream LDP peer is lost: 2659 Pass the event `Upstream Lost' to the state machines of all the 2660 Upstream_LSP_Control_Blocks whose upstream LDP peer is that LSR. 2662 - If a Downstream LDP peer is lost: 2664 Pass the event `Downstream Lost' to the state machines of all the 2665 Downstream_LSP_Control_Blocks whose the downstream LDP peer is that 2666 LSR. 2668 - If a next hop of an FEC is changed: 2670 For all the Upstream_LSP_Control_Blocks which are infected by this 2671 change, pass the event 'Internal New NH' to their state machines. 2673 - If an LSR receives an LDP-ABORT from an Upstream LSR: 2675 Use the Upstream LDP Request ID and Upstream LDP Session Identifier 2676 to locate the Upstream_LSP_Control_Block and pass the event `LDP 2677 Abort' to its state machine. 2679 - If an LSR receives an LDP-NAK from a downstream LSR: 2681 Use the Downstream LDP Request ID and Downstream Session Identifier 2682 to locate a Downstream_LSP_control_block and pass the event `LDP 2683 Downstream Nak' to its state machine. 2685 4. State Machine for Downstream Unsolicited 2687 The following sections describe the state machines for the ATM-LSR 2688 which uses downstream unsolicited mode. 2690 While both independent LSP control and ordered LSP control modes are 2691 possible, only the ordered mode is taken into account, because the 2692 independant LSP control mode uses the liberal label retention mode 2693 and so is considered burning too many ATM resources. 2695 In downstream unsolicited mode, multiple path is not allowed in this 2696 version and will be For Further Study(FFS). We suspect with multiple 2697 next hops and Downstream mode, it is easy to get into loop condition. 2699 4.0 Control Block 2701 There are 2 types of control blocks involved: 2702 Upstream_LSP_Control_Block, Downstream_LSP_Control_Block. 2704 There is a list of Upstream_LSP_Control_Blocks for each FEC in the 2705 routing table, with each one correspondng to a LDP peer. A 2706 Upstream_LSP_Control_Block is created for each FEC when there is a 2707 label ready to be distributed to that upstream. It is deleted when 2708 the FEC is deleted from the FEC table, or the LDP peer disappears, or 2709 the downstream label is withdrawed. 2711 There is one Downstream_LSP_Control_Blocks for each FEC in the 2712 routing table. It is created when the FEC is inserted into the 2713 forwarding table and deleted when the FEC is removed from the 2714 forwarding table. 2716 An Upstream_LSP_Control_Block may contain the following information: 2718 - Upstream LDP Session Identifier 2720 - State 2722 - Upstream Label(assigned by this LSR) 2724 - FEC 2726 Upstream Label and Upstream LDP Session Identifier, or FEC and 2727 Upstream LDP Session Identifier can be used to locate a unique 2728 Upstream_LSP_Control_Block. 2730 A Downstream_LSP_Control_Block may contain the following information: 2732 - FEC 2734 - State 2736 - Downstream LDP Session Identifier 2738 - Downstream Label(assigned by the downstream LSR) 2740 - Downstream Label Request ID (assigned by the LSR itself) 2742 Downstream Label and Downstream LDP Session Identifier, or FEC and 2743 Downsteam LDP Session Identifier can be used to locate a unique 2744 Downstream_LSP_Control_Block. 2746 4.1 States of the Upstream_LSP_Control_Block's State Machine 2747 for Downstream Mode 2749 -- IDLE 2751 This is the initial LSP state. 2753 -- ESTABLISHED 2755 This state means that the LSR has received the LDP-MAPPING message 2756 from the downstream LSR and the LSP is up and operational. 2758 -- RELEASE_AWAITED 2760 This state means that the LSR is waiting for the LDP-RELEASE msg in 2761 respond to the LDP-WITHDRAW sent by this LSR. 2763 -- RESOUCES_AWAITED 2765 This state means that the LSR is waiting for the label resources. 2767 4.2 Events of the Upstream_LSP_Control_Block's State Machine 2768 for Downstream Mode 2770 -- Internal Downstream Mapping 2772 This event is sent by one Downstream_LSP_Control_Block's state 2773 machine. The event is the result of receiving an LDP-MAPPING message 2774 by the Downstream_LSP_Control_Block's state machine. Or when the LDP 2775 peer is discovered and there is a downstream Label available for this 2776 FEC. 2778 -- LDP Release 2780 The LSR receives an LDP-RELEASE from an upstream LSR. 2782 -- Internal Withdraw 2784 This event is sent by Downstream_LSP_Control_Block's state machine. 2785 The event is the result of receiving an LDP-WITHDRAW message by the 2786 Downstream_LSP_Control_Block's state machine. 2788 -- Resource Available 2790 This event means the local resource(such as label) becomes available. 2792 -- Delete FEC 2794 This event means that either the FEC is removed from the forwarding 2795 table. 2797 -- Upstream Lost 2799 This event means that the upstream LDP peer is lost. 2801 4.3 State Transitions of Upstream_LSP_Control_Block's State 2802 Machine for Downstream Mode 2804 | 2805 |(created when 2806 |a label is to be distributed 2807 | to the LDP peer) 2808 v 2809 +-------------------+ 2810 | | 2811 | IDLE |<--------------+ 2812 | | | 2813 +-------------------+ | 2814 | |(LDP Release) 2815 | | 2816 | | 2817 | | 2818 |(Internal Downstream | 2819 +-------------------| Mapping) | 2820 | | | 2821 |(no label resource)v | 2822 | +-------------------+ | 2823 | | | | 2824 | +-----| ESTABLISHED |---------------+ 2825 | | | | ^ 2826 | | +-------------------+ | 2827 | |(delete FEC) ^ | 2828 | |(Internal |(Resource Available) | (LDP Release) 2829 | | Withdraw) | | (Internal 2830 | | | | Downstraem 2831 | | | | Withdraw) 2832 | | +-------------------+ | 2833 +--------->| | | 2834 | |RESOURCES_AWAITED |---------------+ 2835 | | | | 2836 | +-------------------+ | 2837 | | 2838 | (Internal Downstream Withdraw) |(LDP Release) 2839 | +-------------------+ | 2840 | | | | 2841 +---->| RELEASE_AWAITED |---------------+ 2842 | | 2843 +-------------------+ 2845 4.4 Upstream_LSP_Control_Block's State Machine for 2846 Downstream Mode 2848 4.4.1 : State -- "IDLE" 2850 State: IDLE 2852 Event: Internal Downstream mapping 2854 New State: Depends on the action. 2856 Actions 2858 Choose an upstream label, connect the upstream label with the 2859 downstream label. And go to state 'ESTABLISHED' 2861 Propagate the LDP-MAPPING upstream. 2863 If there is no resource for the upstream label, go to state 2864 'RESOURCE_AWAITED'. 2866 State: IDLE 2868 Event: LDP Release 2870 New State: IDLE 2872 Actions 2874 Ignore the event. It is an internal implementation error. 2876 State: IDLE 2878 Event: Internal Downstream Withdraw 2880 New State: IDLE 2882 Actions 2884 Ignore the event. It is an internal implementation error. 2886 State: IDLE 2888 Event: Resource Available 2890 New State: IDLE 2892 Actions 2894 Ignore the event. It is an internal implementation error. 2896 State: IDLE 2898 Event: Delete FEC 2900 New State: IDLE 2902 Actions 2904 Delete the control block. 2906 State: IDLE 2908 Event: Upstream Lost 2910 New State: IDLE 2912 Actions 2914 Delete the control block. 2916 4.4.2 : State -- "ESTABLISHED" 2918 State: ESTABLISHED 2920 Event: Internal Downstream Mapping 2922 New State: ESTABLISHED 2924 Actions 2926 Process the new attributes of the new mapping msg. 2928 Propagate the LDP-MAPPING upstream. 2930 State: ESTABLISHED 2932 Event: LDP Release 2934 New State: IDLE 2936 Actions 2938 Disconnect upstream label from downstream label. 2940 Release the upstream label resource 2942 Delete the control block. 2944 State: ESTABLISHED 2946 Event: Internal Downstream Withdraw 2948 New State: RELEASE_AWAITED 2950 Actions 2952 Disconnect upstream label from downstream label. 2954 Propagate the LDP-WITHDRAW upstream. 2956 State: ESTABLISHED 2958 Event: Resource Available 2960 New State: ESTABLISHED 2962 Actions 2964 Ignore the event. It is an internal implementation error. 2966 State: ESTABLISHED 2968 Event: Delete FEC 2970 New State: RELEASE_AWAITED 2972 Actions 2974 Send a LDP-WITHDRAW upstream. 2976 State: ESTABLISHED 2978 Event: Upstream Lost 2980 New State: IDLE 2982 Actions 2984 Release the upstream label and delete the control block. 2986 4.4.2 : State -- "RELEASE_AWAITED" 2988 State: RELEASE_AWAITED 2990 Event: Internal Downstream Mapping 2991 New State: RELEASE_AWAITED 2993 Actions 2995 Ignore the msg. 2997 State: RELEASE_AWAITED 2999 Event: LDP Release 3001 New State: IDLE 3003 Actions 3005 Release the upstream label and delete the control block. 3007 State: RELEASE_AWAITED 3009 Event: Internal Downstream Withdraw 3011 New State: RELEASE_AWAITED 3013 Actions 3015 Ignore the event. 3017 State: RELEASE_AWAITED 3019 Event: Resource Available 3021 New State: RELEASE_AWAITED 3023 Actions 3025 Ignore the event. It is an internal implementation error. 3027 State: RELEASE_AWAITED 3029 Event: Delete FEC 3031 New State: RELEASE_AWAITED 3033 Actions 3035 Do nothing. 3037 State: RELEASE_AWAITED 3038 Event: Upstream Lost 3040 New State: IDLE 3042 Actions 3044 Release the upstream label and delete the control block. 3046 4.4.2 : State -- "RESOURCE_AWAITED" 3048 State: RESOURCE_AWAITED 3050 Event: Internal Downstream Mapping 3052 New State: RESOURCE_AWAITED 3054 Actions 3056 Ignore the msg. 3058 State: RESOURCE_AWAITED 3060 Event: LDP Release 3062 New State: RESOURCE_AWAITED 3064 Actions 3066 Ignore the msg. It is an internal implementation error. 3068 State: RESOURCE_AWAITED 3070 Event: Internal Downstream Withdraw 3072 New State: IDLE 3074 Actions 3076 Delete the control block. 3078 State: RESOURCE_AWAITED 3080 Event: Resource Available 3082 New State: ESTABLISHED 3084 Actions 3085 Allocate an upstream label, connect the upstream label with the 3086 downstream label, and send LDP-MAPPING upstream. 3088 State: RESOURCE_AWAITED 3090 Event: Delete FEC 3092 New State: IDLE 3094 Actions 3096 Delete the control block. 3098 State: RESOURCE_AWAITED 3100 Event: Upstream Lost 3102 New State: IDLE 3104 Actions 3106 Delete the control block. 3108 4.5 State of the Downstream_LSP_Control_Block's State Machine 3109 for Downstream Mode 3111 -- IDLE 3113 This is the initial LSP state. 3115 -- ESTABLISHED 3117 This state means that the LSR has received the LDP-MAPPING msg from 3118 the downstream LSR. 3120 3.2.4.6 Events of the Downstream_LSP_Control_Block's State Machine 3121 for Downstream Mode 3123 -- LDP Mapping 3125 The LSR receives an LDP-MAPPING msg from a downstream LSR. 3127 -- LDP Withdraw 3129 The LSR receives an LDP-WITHDRAW msg from a downstream LSR. 3131 -- Delete FEC 3133 The FEC is deleted from the forwarding table. 3135 -- Next Hop Change 3137 The next hop for this FEC is change to different LSR. 3139 -- Downstream Lost 3141 The downstream peer is gone. 3143 4.7 State Transitions of Downstream_LSP_Control_Block's State 3144 Machine for Downstream Mode 3146 | 3147 |(FEC is being added into the forwarding 3148 table) 3149 v 3150 +-------------------+ 3151 | | 3152 | IDLE |<--------------+ 3153 | | | 3154 +-------------------+ | 3155 | | 3156 | |(LDP Withdraw) 3157 | |(Internal New NH) 3158 | |(Downstream Lost) 3159 | (LDP Mapping) | 3160 | | 3161 v | 3162 +-------------------+ | 3163 | | | 3164 | ESTABLISHED |---------------+ 3165 | | 3166 +-------------------+ 3167 | 3168 |(FEC is deleted from the forwarding table) 3169 v 3171 4.8 Downstream_LSP_Control_Block's State Machine 3172 for Downstream Mode 3174 4.8.1 : State -- "IDLE" 3176 State: IDLE 3178 Event: LDP mapping 3180 New State: ESTABLISHED 3182 Actions 3184 For all the LDP peers except the downstream LSR which assigned the 3185 label, create an Upstream_LSP_Control_Block, and pass the event 3186 `Internal Downstream Mapping' to each of the 3187 Upstream_LSP_Control_Block's state machines. 3189 State: IDLE 3190 Event: LDP withdraw 3192 New State: IDLE 3194 Actions 3195 Ignore the event. It is an internal implementation error. 3197 State: IDLE 3199 Event: Delete FEC 3201 New State: IDLE 3203 Actions 3205 Delete the control block. 3207 State: IDLE 3209 Event: Next Hop Change 3211 New State: IDLE 3213 Actions 3215 Ignore the event. 3217 State: IDLE 3219 Event: Downstream Lost 3221 New State: IDLE 3223 Actions 3225 Ignore the event. 3227 4.8.1 : State -- "ESTABLISHED" 3229 State: ESTABLISHED 3231 Event: LDP mapping 3233 New State: ESTABLISHED 3235 Actions 3237 For each Upstream_LSP_control_block of this FEC, pass event `Internal 3238 downstream mapping' to its state machine. 3240 State: ESTABLISHED 3242 Event: LDP withdraw 3244 New State: IDLE 3246 Actions 3248 For each Upstream_LSP_control_block for this FEC, pass event 3249 `Internal downstream Withdraw' to its state machine. 3251 Send a LDP Withdraw downstream. 3253 State: ESTABLISHED 3255 Event: Delete FEC 3257 New State: IDLE 3259 Actions 3261 Send LDP-RELEASE downstream and delete the control block. 3263 State: ESTABLISHED 3265 Event: Next Hop Change 3267 New State: IDLE 3269 Actions 3271 For each Upstream_LSP_control_block for this FEC, pass event 3272 `Internal downstream Withdraw' to its state machine. 3274 Send LDP-REQUEST to the new next hop. 3276 State: ESTABLISHED 3278 Event: Downstream Lost 3280 New State: IDLE 3282 Actions 3284 Send LDP-WITHDRAW to all Upstream_Control_Block's state machine of 3285 this FEC. 3287 4.5 LDP Related Message Processing for downstream mode. 3289 - If an LSR receives an LDP-REQUEST message: 3291 If there is a next hop for this FEC and there is a 3292 Downstream_Control_Block for this FEC whose state is 'ESTABLISHED', 3293 create a new Upstream_Control_Block and pass 'internal Mapping' event 3294 to its state machine. 3296 - If an LSR receives an LDP-MAPPING message: 3298 Locate a Downstream_LSP_Control_Block which has the same FEC, the 3299 same Downstream LDP Session Identifier and the same Downstream Label. 3300 If a Downstream_LSP_Control_Block is found, pass the event `LDP 3301 Mapping' to its state table. This could mean that the attributes of 3302 label binding have changed. 3304 Otherwise, if there is no matching Downstream_LSP_Control_Block 3305 found, find a Downstream_LSP_Control_Block of this FEC and its next 3306 hop is the this downstream peer, pass the event `LDP Mapping' to its 3307 state machine. 3309 - If an LSR receives an LDP-RELEASE message: 3311 Locate an Upstream_LSP_Control_Block which has the same FEC, the same 3312 Upstream Label, the same Upstream LDP Session Identifier. If no 3313 Upstream_LSP_Control_Block is found, ignore the message. If an 3314 Upstream_LSP_Control_Block is found, send the event `LDP Release' to 3315 its state machine. 3317 - If an LSR receives an LDP-WITHDRAW message: 3319 Find a Downstream_LSP_Control_Block which has the same FEC, the same 3320 Downstream LDP Session Identifier and the same Downstream Label. Pass 3321 the event `LDP Withdraw' to its state machines. 3323 - If an Upstream LDP peer is lost: 3325 Pass the event `Upstream Lost' to the state machines of all the 3326 Upstream_LSP_Control_Blocks whose upstream LDP peer is that LSR. 3328 - If a Downstream LDP peer is lost: 3330 Pass the event `Label Withdraw' to the state machines of all the 3331 Downstream_LSP_Control_Blocks whose the downstream LDP peer is that 3332 LSR. 3334 - If a next hop of an FEC is changed: 3336 Find all the Downstream_LSP_Control_Blocks which has the same FEC and 3337 the same next hop and pass the event `Next Hop Change' to their state 3338 machine 3340 - If there is a FEC being added to the forwarding table 3342 Create a new Downstream_LSP_Control_Block with state 'IDLE' 3344 - If the FEC is deleted from the forwarding table 3346 Send the 'Delete FEC' event to the its control block. 3348 - If an LSR receives an LDP-NAK from an Upstream LSR: 3350 Ignore the msg. An LDP-NAK should never appear in the downstream-mode 3351 LSR 3353 - If an LSR receives an LDP-NAK from a downstream LSR: 3355 Ignore the msg. It is an protocol error from the downstream LSR. 3357 5. Security Considerations 3359 Security considerations will be addressed in a future revision of 3360 this document. 3362 6. Acknowledgements 3364 The authors would like to acknowledge the helpful comments and 3365 suggestions of the following people: Bob Thomas 3367 7. Authors's Address 3369 Liwen Wu 3371 Alcatel 3372 44983 Knoll Square 3373 Ashburn, VA. 20147 3374 U.S.A 3375 Phone: 703-724-2619 3376 Email:liwen.wu@adn.alcatel.com 3378 Pierrick Cheval 3380 Alcatel 3381 44983 Knoll Square 3382 Ashburn, VA. 20147 3383 U.S.A 3384 Phone: 703-724-2080 3385 Email: pierrick.cheval@adn.alcatel.com 3387 Christophe Boscher 3389 Alcatel CIT 3390 Le Mail 3391 44700 Nantes-Orvault 3392 France 3393 Phone: (33) 251781828 3394 Email: christophe.boscher@or.cit.alcatel.fr 3396 Eric Gray 3398 Lucent Technologies, Inc. 3399 1600 Osgood Street 3400 North Andover, MA 01845 3401 Email: ewgray@lucent.com 3403 8. References 3405 1."Use of Label Switching With ATM", Bruce Davie, Jeremy Lawrence, 3406 Keith McCloghrie, Yakov Rekhter, Eric Rosen, George Swallow, Paul 3407 Doolan, work in progress, Internet Draft, 3409 2."Multiprotocol Label Switching Architecture", Eric C Rosen, Arun 3410 Viswanathan, Ross Callon, work in progress, Internet Draft, 3413 3."Definition of Managed Objects for the Multiprotocol Label Switching, 3414 Label Distribution Protocol (LDP)", Joan Cucchiara, Hans Sjostrand, 3415 James V. Luciani, work in progress, Internet Draft, 3418 4."Requirements for Traffic Engineering Over MPLS", Daniel O.Awduche, 3419 Joe Malcolm, Johnson Agogbua, Mike O'Dell, Jim McMaus, work in 3420 progress,Internet Draft, 3422 5. "LDP Specification", Loa Andersson, Paul Doolan,Nancy Feldman, Andre 3423 Fredette, Bob Thomas, work in progress, Internet Draft, 3426 6. "MPLS Loop Prevention Mechanism", Yoshihiro Ohba, Yasuhiro Katsube, 3427 Eric Rosen, Paul Doolan, work in progress, Internet Draft, 3429 7. "Constraint-Based LSP Set up Using LDP", Bilel Jamoussi, et.al., 3430 work in progress, Internet Draft,