Abstract:
Disclosed are a path computation element communication protocol (PCEP) session establishment method and device. The technical solution comprises: at a PCC or PCE node device side, before needing to establish a PCEP session, allocating a TCP connection communication end attribute to a PCC or a PCE at either end in the manner of static configuration/dynamic designation or election mechanism automatic allocation; or detecting whether to establish a TCP connection relationship, if not, actively connecting the opposite end, and if a plurality of TCP connection relationships has been established, simultaneously cutting off a plurality of connections at both ends, and reinitiating a TCP connection after waiting a random time respectively. The present invention achieves the establishment of a PCEP session in the multi-PCE cooperation computation scenario under the condition of meeting two constraint conditions which are specified by a protocol.

Description:
TECHNICAL FIELD 
       [0001]    The disclosure relates to the field of Path Computation Element (PCE) Communication Protocol (PCEP) technology, and in particular to a method and device for establishing a PCEP session. 
       BACKGROUND 
       [0002]    Distributed in an Automatically Switched Optical Network (ASON) architecture defined in ITU-T G.8080 are control-plane node equipment each containing a Route Controller (RC) component providing a connection controller with route information for connection inside a domain of responsibility. Such route information is end-to-end, or may be based on next-hop. In addition, to achieve network management, the RC can also respond to topology requesting information. 
         [0003]    With development of a Multi-Protocol Label Switching (MPLS)/Generalized Multi-Protocol Label Switching (GMPLS) network, network topology becomes increasingly complicated with enormous amount of routes, and path computation becomes increasingly complicated as well. Meanwhile, traffic projecting requires a network equipment to perform route computation under complicated constraints. such complicated computation often requires a lot of CPU computing resources and memory resources, impacting hardware performance of the network equipment and stability of the entire network to some extent. 
         [0004]    Accordingly, an IETF PCE workgroup proposes an MPLS/GMPLS network structure based on a Path Computation Element (PCE). In such a structure, based on known network topology and a known constraint, a PCE, as a functional entity dedicated to path computation in a management domain, computes an optimal pat meeting the constraint according to a request of a Path Computation Client (PCC). A PCE may be located anywhere in the network, for example by being integrated in a network equipment such as a Label Switch Route (LSR) or an Operating System (OS), or may be a separate equipment. Communication between a PCC and a PCE as well as between a PCE and a PCE is performed via a PCE Communication Protocol (PCEP). 
         [0005]    RFC 5440 describes in particular a PCEP architecture including a transport layer adopting a TCP, a transport port 4189, with 7 PCEP message type defined. RFC 5440 specifies that what must be accomplished at an initial stage of establishing communication between a PCC and a PCE are: 1) establishment of a TCP connection between the PCC and the PCE via three handshakes; and 2) establishment of a PCEP session based on the TCP connection. RFC 5440 specifies two constraints that: 1) at any time, any pair of PCEP communicating ends can have only one PCEP session; 2) at any time, there can be only one TCP connection between any pair of PCEP communicating ends. 
         [0006]    However, in multi-PCE collaboration, including intra-domain collaborative computation by multiple PCEs, inter-domain collaborative computation by multiple PCEs, and collaborative computation by parent and offspring PCEs in a hierarchic PCE architecture, a PCE will serve as a TCP server in monitoring at a port 4189 a message sent by a PCC, and also will serve as a TCP client in actively seeking connection to another PCE for PCEP message exchange. An implementing mechanism among such PCEs in collaborative computation has to be formulated to meet the two constraints. 
       SUMMARY 
       [0007]    In view of this, it is desired that embodiments of the disclosure provide a method and device for establishing a PCEP session, capable of establishing, in a scenario of multi-PCE collaborative computation, a PCEP session among PCEs in collaborative computation while meeting the two constraints. 
         [0008]    To this end, a technology solution of an embodiment of the disclosure is implemented as follows. 
         [0009]    An embodiment of the disclosure provides a method for establishing a Path Computation Element Communication Protocol (PCEP) session, including steps of: 
         [0010]    at a Path Computation Client (PCC) or a Path computation Element (PCE) node equipment side, when it is required to establish a PCEP session between the PCC and another PCE or between the PCE and another PCC or another PCE, allocating, via static configuration or dynamic designation, an attribute of the PCC or the PCE node equipment as a communicating end of a TCP connection for the PCEP session as a server or a client; or 
         [0011]    at a PCC or a PCE node equipment side, when it is required to establish a PCEP session between the PCC and another PCE or between the PCE and another PCC or another PCE, automatically allocating, via an electing mechanism, an attribute of the PCC or the PCE node equipment as a communicating end of a TCP connection for the PCEP session as a server or a client; or 
         [0012]    at a PCC or a PCE node equipment side, when a requirement for triggering establishment of a PCEP session is met, first detecting whether there is an established TCP connection to a peer PCE or a peer PCC with which the PCEP session is to be established; when there is no established TCP connection, actively seeking, by the PCC or the PCE, a TCP connection to the peer as a client; when there is an established TCP connection, detecting whether there are multiple TCP connections established; when no more than one established TCP connection is detected and no PCEP session has been established with the peer PCE or the peer PCC, activating a flow of PCEP session establishment; otherwise when multiple TCP connections established are detected, simultaneously disconnecting the multiple TCP connections detected, and actively seeking, by the PCC or the PCE, a TCP connection to the peer as a client after waiting a random period of time. 
         [0013]    In an embodiment, the electing mechanism may include at least that of: 
         [0014]    electing a PCC or a PCE with a greater IP address as a server or a client; 
         [0015]    electing in an autonomous domain a PCC or a PCE with a greater area identifier as a server or a client; and 
         [0016]    electing a PCC or a PCE with a greater autonomous domain identifier as a server or a client. 
         [0017]    In an embodiment, the requirement for triggering establishment of a PCEP session may include at least a PCE node activation or a special event; and 
         [0018]    the special event may include at least a timer event or a PCEP message event. 
         [0019]    In an embodiment, after the multiple TCP connections detected are simultaneously disconnected, a PCC or a PCE at one end of one of the disconnected TCP connections may determine a local random period of time, and wait the local random period of time before actively seeking the TCP connection to the peer. 
         [0020]    In an embodiment, the method may further include a step of: 
         [0021]    after the step of actively seeking, by the PCC or the PCE, a TCP connection to the peer, executing again, by the PCC or the PCE, the step of detecting whether there is an established TCP connection to a peer PCE or a peer PCC with which the PCEP session is to be established. 
         [0022]    An embodiment of the disclosure further provides a device for establishing a Path Computation Element Communication Protocol (PCEP) session, applying to a Path Computation Client (PCC) or a Path computation Element (PCE) node equipment side; 
         [0023]    the device including a communicating end attribute configuring element and a PCEP session establishing element;
       the communicating end attribute configuring element being configured for: when it is required to establish a PCEP session between the PCC and another PCE or between the PCE and another PCC or another PCE, allocating, via static configuration or dynamic designation, an attribute of the PCC or the PCE node equipment as a communicating end of a TCP connection for the PCEP session as a server or a client; and   the PCEP session establishing element being configured for: establishing the PCEP session between the PCC and a peer PCE, or establishing the PCEP session between the PCE and a peer PCC or a peer PCE;       
 
         [0026]    or the device including an electing element and a PCEP session establishing element;
       the electing element being configured for: when it is required to establish a PCEP session between the PCC and another PCE or between the PCE and another PCC or another PCE, automatically allocating, via an electing mechanism, an attribute of the PCC or the PCE node equipment as a communicating end of a TCP connection for the PCEP session as a server or a client; and   the PCEP session establishing element being configured for: establishing the PCEP session between the PCC and a peer PCE, or establishing the PCEP session between the PCE and a peer PCC or a peer PCE;       
 
         [0029]    or the device including:
       a first determining element configured for: when a requirement for triggering establishment of a PCEP session is met, detecting whether there is an established TCP connection to a peer PCE or a peer PCC with which the PCEP session is to be established;   an active connection element configured for: when there is no established TCP connection, actively seeking a TCP connection to the peer as a client;   a second determining element configured for: when there is an established TCP connection, detecting whether there are multiple TCP connections established;   a third determining element configured for: when no more than one established TCP connection is detected, determining whether a PCEP session has been established with the peer PCE or the peer PCC;   a PCEP session establishing element configured for: when no more than one established TCP connection is detected and no PCEP session has been established with the peer PCE or the peer PCC, activating a flow of PCEP session establishment; and   a re-connecting element configured for: when multiple TCP connections established are detected, simultaneously disconnecting the multiple TCP connections detected, and actively seeking a TCP connection to the peer as a client after waiting a random period of time.       
 
         [0036]    In an embodiment, the electing mechanism may include at least that of: 
         [0037]    electing a PCC or a PCE with a greater IP address as a server or a client; 
         [0038]    electing in an autonomous domain a PCC or a PCE with an area identifier as a server or a client; and 
         [0039]    electing a PCC or a PCE with a greater autonomous domain identifier as a server or a client. 
         [0040]    In an embodiment, the requirement for triggering establishment of a PCEP session may include at least a PCE node activation or a special event; 
         [0041]    the special event may include at least a timer event or a PCEP message event. 
         [0042]    In an embodiment, after the multiple TCP connections detected are simultaneously disconnected, 
         [0043]    a re-connecting element at one end of one of the disconnected TCP connections may determine a local random period of time, and wait the local random period of time before actively seeking the TCP connection to the peer. 
         [0044]    In an embodiment, the active connection element may be configured for: after actively seeking a TCP connection to the peer, again triggering the first determining element to execute the detecting whether there is an established TCP connection to a peer PCE or a peer PCC with which the PCEP session is to be established. 
         [0045]    Embodiments of the disclosure provide a solution for PCEP session establishment in a scenario of multi-PCE collaborative computation, meeting two protocol-specified constraints that: 1) at any time, any pair of PCEP communicating ends can have only one PCEP session; 2) at any time, there can be only one TCP connection between any pair of PCEP communicating ends. 
     
    
     
       BRIEF DESCRIPTION OF THE DRAWINGS 
         [0046]      FIG. 1  is a schematic diagram of a scenario of PCEP session establishment among three PCEs in multi-PCE collaborative path computation according to an embodiment of the disclosure; 
           [0047]      FIG. 2  is a schematic diagram of inter-PCE exchange in a flow of PCEP session establishment according to Embodiment 2 of the disclosure; 
           [0048]      FIG. 3  is a processing flow of a single PCE in a flow of PCEP session establishment according to Embodiment 3 of the disclosure; and 
           [0049]      FIG. 4  is a schematic diagram of a structure of a device for establishing a PCEP session according to Embodiment 3 of the disclosure. 
       
    
    
     DETAILED DESCRIPTION 
       [0050]    To clearly show a technical problem to be solved, a technical solution, and beneficial effects of the present disclosure, the present disclosure is further elaborated below with reference to the drawings and embodiments. 
         [0051]      FIG. 1  is a schematic diagram of a scenario of PCEP session establishment among three PCEs in multi-PCE collaborative path computation according to an embodiment of the disclosure. In an MPLS/GMPLS network, PCE1, PCE2, and PCE3 are required to perform collaborative path computation. Assuming that path computation is required among all three PCEs, the three PCEs therefore neighbor each other, and a PCEP session is required to be established between each two of the three PCEs. 
       Embodiment 1 
       [0052]    In the embodiment, at a Path Computation Client (PCC) or a Path computation Element (PCE) node equipment side, when it is required to establish a PCEP session between the PCC and another PCE or between the PCE and another PCC or another PCE, an attribute of the PCC or the PCE node equipment as a communicating end of a TCP connection for the PCEP session is allocated, via static configuration or dynamic designation, as a server (intercepting connection of another PCC or PCE at a communication port 4189) or a client (actively seeking connection to a PCC or PCE node performing a monitoring service at a communication port 4189). 
         [0053]    A device for implementing the method for establishing a PCEP session as given by the embodiment is provided accordingly, the device including: 
         [0054]    a communicating end attribute configuring element configured for: at a PCC or a PCE node equipment side, when it is required to establish a PCEP session between the PCC and another PCE or between the PCE and another PCC or another PCE, allocating, via static configuration or dynamic designation, an attribute of the PCC or the PCE node equipment as a communicating end of a TCP connection for the PCEP session as a server or a client; and 
         [0055]    a PCEP session establishing element is configured for: establishing the PCEP session between the PCC and a peer PCE, or establishing the PCEP session between the PCE and a peer PCC or a peer PCE. 
         [0056]    With an example of a scenario as in  FIG. 1 , when it is required to establish a PCEP session between PCE1 and PCE2, the communicating end attribute configuring element allocates, via static configuration or dynamic designation, the attribute of PCE1 as a communicating end of a TCP connection for the PCEP session as a server, and the attribute of PCE2 as a communicating end of a TCP connection for the PCEP session as a client. 
         [0057]    With the static configuration, the attribute as a client or as a server in a PCEP session is designated before a node equipment or device deployed with a PCE function activates the PCE function. 
         [0058]    With the dynamic designation, after a node equipment or device deployed with a PCE function activates the PCE function, the attribute as a client or as a server in a PCEP session is designated in accordance with a preset dynamic designation mechanism. the dynamic designation mechanism may be an electing mechanism, as described in Embodiment 2. 
       Embodiment 2 
       [0059]    A flow of PCEP session establishment according to Embodiment 2 is as shown in  FIG. 2 . At a PCC or a PCE node equipment side, when it is required to establish a PCEP session between the PCC and another PCE or between the PCE and another PCC or another PCE, an attribute of the PCC or the PCE node equipment as a communicating end of a TCP connection for the PCEP session is automatically allocated, via an electing mechanism, as a server (intercepting connection of another PCC or PCE at a communication port 4189) or a client (actively seeking connection to a PCC or PCE node performing a monitoring service at a communication port 4189). 
         [0060]    A device for implementing the method for establishing a PCEP session as given by the embodiment is provided accordingly, the device including: 
         [0061]    an electing element configured for: at a PCC or a PCE node equipment side, when it is required to establish a PCEP session between the PCC and another PCE or between the PCE and another PCC or another PCE, automatically allocating, via an electing mechanism, an attribute of the PCC or the PCE node equipment as a communicating end of a TCP connection for the PCEP session as a server or a client; and 
         [0062]    a PCEP session establishing element configured for: establishing the PCEP session between the PCC and a peer PCE, or establishing the PCEP session between the PCE and a peer PCC or a peer PCE. 
         [0063]    The electing mechanism may include but be not limited to that: 
         [0064]    (1) in accordance with an IP address of a PCC or PCE at either of both ends between which the PCEP session is to be established, a PCC or a PCE with a greater IP address is elected as a server (or as a client); 
         [0065]    (2) in accordance with the size of an area identifier (area ID) of a PCC or PCE at either of both ends between which the PCEP session is to be established in an autonomous domain, a PCC or PCE with a greater area ID in the autonomous domain is elected as a server (or as a client); or 
         [0066]    (3) in accordance with the size of an autonomous domain identifier of an autonomous domain to which a PCC or PCE at either of both ends between which the PCEP session is to be established belongs, a PCC or a PCE with a greater autonomous domain identifier is elected as a server (or as a client). 
         [0067]    In addition, the attribute, as a server or as a client, of either of both ends that are to be in PCEP communication may be elected in accordance with any other unique, comparable parameter. 
         [0068]      FIG. 2  is an example flowchart of implementing the method for establishing a PCEP session given by the embodiment based on the scenario as in  FIG. 1 , the flow including steps as follows. 
         [0069]    In step  1 , after activation, each of PCE1, PCE2, and PCE3 finds, via a finding mechanism, a neighboring PCE per se. PCE1 neighbors PCE2 and PCE3; PCE2 neighbors PCE1 and PCE3; and PCE3 neighbors PCE1 and PCE2. 
         [0070]    In step  2 , PCE1, PCE2, and PCE3 follow a same electing mechanism which, in the embodiment, is that: a PCE with a greater autonomous domain identifier serves as a TCP server in a PCEP session, and a PCE with a smaller autonomous domain identifier serves as a TCP client in a PCEP session. Therefore, a TCP connection table is produced as follows. 
         [0000]    
       
         
               
               
               
               
             
           
               
                   
                   
               
               
                   
                 PCE session 
                 TCP server 
                 TCP client 
               
               
                   
                   
               
             
             
               
                   
                 PCE1&lt;-&gt;PCE2 
                 PCE2 
                 PCE1 
               
               
                   
                 PCE1&lt;-&gt;PCE3 
                 PCE3 
                 PCE1 
               
               
                   
                 PCE2&lt;-&gt;PCE3 
                 PCE3 
                 PCE1 
               
               
                   
                   
               
             
          
         
       
     
         [0071]    In step  3 , one of PCE1, PCE2, and PCE3 initiates a TCP connection request with a respective TCP server according to the TCP connection table produced by election. Here, a process of activation of a TCP monitoring service by a PCE at a communicating port 4189 is omitted; 
         [0072]    In step  4 , PCE1 receives TCP connection succeeds acknowledgements sent respectively by PCE2 and PCE3; and PCE2 receives a TCP connection succeeds acknowledgement sent by PCE3. 
         [0073]    In step  5 , PCE1 establishes a PCEP session respectively with PCE2 and PCE3; and PCE2 establishes a PCEP session with PCE3. 
       Embodiment 3 
       [0074]    In the embodiment, at a PCC or a PCE node equipment side, when meeting a requirement for triggering establishment of a PCEP session, the PCC or the PCE first detects whether there is a TCP connection, established via three handshakes, to a peer PCE or a peer PCC with which the PCEP session is to be established; when there is no established TCP connection, the PCC or the PCE actively seeks a TCP connection to the peer as a client; when there is an established TCP connection, the PCC or the PCE detects whether there are multiple TCP connections established; when no more than one established TCP connection is detected and no PCEP session has been established with the peer PCE or the peer PCC, a flow of PCEP session establishment is activated; otherwise when multiple TCP connections established are detected, the multiple TCP connections detected are simultaneously disconnected, and the PCC or the PCE actively seeks a TCP connection to the peer as a client after waiting a random period of time. Note that no PCEP session can be established between two PCCs; a PCEP session can be established only between a PCC and a PCE, or between two PCEs. 
         [0075]    A device  400  for implementing the method for establishing a PCEP session as given by the embodiment is provided accordingly, the device applying to a PCC or a PCE; as shown in  FIG. 4 , the device  400  includes: 
         [0076]    a first determining element  401  configured for: when a requirement for triggering establishment of a PCEP session is met, detecting whether there is an established TCP connection to a peer PCE or a peer PCC with which the PCEP session is to be established; 
         [0077]    an active connection element  402  configured for: when there is no established TCP connection, actively seeking a TCP connection to the peer as a client; 
         [0078]    a second determining element  403  configured for: when there is an established TCP connection, detecting whether there are multiple TCP connections established; 
         [0079]    a third determining element  404  configured for: when no more than one established TCP connection is detected, determining whether a PCEP session has been established with the peer PCE or the peer PCC; 
         [0080]    a PCEP session establishing element  405  configured for: when no more than one established TCP connection is detected and no PCEP session has been established with the peer PCE or the peer PCC, activating a flow of PCEP session establishment; and 
         [0081]    a re-connecting element  406  configured for: when multiple TCP connections established are detected, simultaneously disconnecting the multiple TCP connections detected, and actively seeking a TCP connection to the peer as a client after waiting a random period of time. 
         [0082]    The requirement for triggering establishment of a PCEP session may include at least a PCE node activation or a special event; the special event may include at least a timer event or a PCEP message event. 
         [0083]      FIG. 3  is an example flowchart of implementing the method for establishing a PCEP session given by the embodiment based on the scenario as in  FIG. 1 , the flow including steps as follows. 
         [0084]    In step  301 , a PCE activates a flow of PCEP session establishment once a requirement for establishing a PCEP session is met, provided that: the PCE finds, via a finding mechanism, a neighboring PCE per se; and a TCP monitoring service has been created for the PCE at a communicating port 4189. 
         [0085]    In step  302 , the PCE detects whether there is an established TCP connection to a peer PCE. 
         [0086]    In step  303 , when the PCE detects that there is an established TCP connection to a peer PCE, the flow goes to step  305 ; or when the PCE detects that there is no established TCP connection to a peer PCE, the flow goes to step  304 . 
         [0087]    In step  304 , the local PCE actively connects the peer PCE as a client of a TCP connection; and the flow goes to step  302 ; 
         [0088]    In step  305 , the PCE detects whether there are multiple TCP connections established with the peer PCE; when the PCE detects multiple TCP connections established, the flow goes to step  306 ; otherwise when the PCE detects no more than one established TCP connection, the flow goes to step  307 . 
         [0089]    In step  306 , any TCP connection between the local PCE and the peer PCE is disconnected; the local PCE waits a random period of time; and then the flow goes to step  304 . 
         [0090]    In the step, each of both TCP connection ends determines a local random period of time, and waits the local random period of time before initiating a TCP connection again. 
         [0091]    In step  307 , the PCE detects whether the PCEP session has been established with the peer PCE; when the PCE detects that the PCEP session has been established, the flow ends; otherwise when the PCE detects that the PCEP session has not been established, the flow goes to step  308 . 
         [0092]    In step  308 , the PCE starts to establish the PCEP session with the peer. 
         [0093]    What described are merely embodiments of the disclosure and are not intended to limit the scope of the disclosure.