The GTP(GPRS Tunneling Protocol) is a communication protocol used by the LTE to deliver IP packets within the EPC. The GTP-C is used to deliver the controlling signals over S11 and S5, whereas the GTP-U is used to deliver application payload over S1 and S5.
The TEID(Tunnel Endpoint IDentifier) is generated by each node during the initial attach procedure. The Create Session Request includes the S11 MME DL TEID and the S5 SGW DL TEID, which are generated and included by MME and Serving GW respectively. The Create Session Response includes the S5 PGW UL TEID and the S11 SGW UL TEID, which are generated and included by PGW and Serving GW respectively.
The following diagram shows the actual call flow and depicts how the TEID is exchanged between NEs. Upon receiving the Create Session Request, the Serving GW establishes the downlink GTP-C tunnel towards the MME using the received S11 MME DL TEID. In the same way the MME establishes the uplink GTP-C tunnel towards the Serving GW using the received S11 SGW UL TEID. The TEID for GTP-U is included in the body of bearer related messages (e.g., Create Bearer Request/Response, Modify Bearer Request/Response).
The following diagram shows the actual call flow and depicts how the TEID is exchanged between NEs. Upon receiving the Create Session Request, the Serving GW establishes the downlink GTP-C tunnel towards the MME using the received S11 MME DL TEID. In the same way the MME establishes the uplink GTP-C tunnel towards the Serving GW using the received S11 SGW UL TEID. The TEID for GTP-U is included in the body of bearer related messages (e.g., Create Bearer Request/Response, Modify Bearer Request/Response).
The newly generated TEID is included in the body of each sending message and delivered to the peer node. The peer node perceives the end point of the GTP based on the received TEID. When the message goes through the existing GTP tunnel, the TEID of the peer node will be included in the GTP header of the sending message. The following example shows the TEID included in the Create Session Request being sent from the MME towards the Serving GW.
II. TEID lifetime
The life time of the GTP-C session lasts along with the life time of the UE's IP-CAN connection. It starts when the UE attaches to network and ends when the UE detaches from the network. In case there are multiple PDNs , there is only one GTP-C session per UE. The following example shows the lifetime of the same GTP-C session, which is defined by same TEIDs. In this example, there are two Create Session Requests, each for different PDNs. Each Create Session Response is followed by the Modify Bearer Request for establishing default EPS bearers. Lastly, the Create Bearer Request is to establish dedicated EPS bearers.
The lifetime of the GTP-U depends on the attributes of the EPS bearer. The GTP-U connection associated with the default EPS bearer has the same lifetime of that of GTP-C connection, whereas the GTP-U connection associated with the dedicated EPS bearer will be dynamically created and deleted within the lifetime of IP-CAN connection.
III. TEID usage
When there are multiple EPS bearers established for the same APN and there needs to verify if specific service data flow goes through the right EPS bearer, the TEID can be a useful tool to figure it out. The following example shows the GTP-U packet of the SIP REGISTER being sent from the UE towards the IMS Core. The TEID in the GTP header indicates "0x005b8422".
The following shows the same TEID appears in the body of a Modify Bearer Request. This Modify Bearer Request is for the EPS bearer of QCI=5.
Red Mouse
nice article ..many thanks :)
ReplyDeletethanks, which tools you use to draw this img? beautiful!!
ReplyDeleteThanks, very informative article.
ReplyDeleteIn the call sequence diagram after steps 6-9 you show an S1-U data plane tunnel from the "MME" to the SGW, shouldnt that tunnel be from the eNodeB to the SGW? The MME only deals with control plane tunnels (GTP-C).
ReplyDeleteI think the author really meant MME simply passed what it received from eNodeB. For Step#6, the protocol is for sure GTPv2C, but if you unpack the Modify Bearer Request, the interface type is S1-U-eNodeB-GTPU-interface and the TEID is what eNodeB has allocated. eNodeB can't pass these info to S-GW, so it gives to MME and MME forwards to S-GW.
DeleteNice Article. Many thanks. In case of Inter-eNB HO using X2, how TEID will be used/exchanged?
ReplyDeleteWell explained.
ReplyDeleteThis comment has been removed by the author.
ReplyDeleteIn 2nd photo, step#5 Create Session Response (S11 MMW UL TEID) has a typo: it should be S11 MME UL TEID.
ReplyDeleteThis comment has been removed by the author.
ReplyDelete