deleted the MM and PDP contexts of the detached UE. Chapter 2 gave the definition of the location area/routing area. However, the routing area update in the context of the PS core means the inter- or intra-SGSN area update. The former one means that the mobile is within the same SGSN area but has changed the BS, while the latter one means that the mobile is now attached to a different SGSN. Until the time that the subscriber is within one routing area, data will pass through the connected SGSN to the GGSN over the Gn interface. However, when the subscriber changes the location area, i.e. attaches itself to the new SGSN, a query is sent to the HLR based on the subscriber IMSI asking for the routing area identity. The SGSN receives the routing data (RD) from the HLR, based on which it makes a query to the DNS to get the IP address of the previous SGSN. Once the IP address is received, the present SGSN contacts the old SGSN to get information that includes the GGSN tunnel ID and encryption key. Now the SGSN contacts the GGSN and establishes the session using the information received. User data information is received by the new SGSN from the previous SGSN. The new SGSN now updates the HLR with RA/LA IDs. Finally, the UE disconnects from the previous SGSN and connects itself completely to the new SGSN. Session Management A packet data user connection in the network is called a Packet Data Protocol (PDP) context. The PDP context is basically a set of configuration data in the UE, SGSN and GGSN, which define and manage the tunnelling of data packets between the UE and GGSN. The function of the PDP context is to transport IP packets from the UE to the GGSN and vice versa while having no knowledge of the application inside the IP packets that it is transporting. Activation of the PDP context is initiated by the UE. Controlling the actual data connections of the UE is called session management. This has two states: inactive and active. Inactive applies to attached UE with no PDP context activated while active is the oppos