WO2015062287A1 - Local exchange method and system of terminal - Google Patents

Local exchange method and system of terminal Download PDF

Info

Publication number
WO2015062287A1
WO2015062287A1 PCT/CN2014/080344 CN2014080344W WO2015062287A1 WO 2015062287 A1 WO2015062287 A1 WO 2015062287A1 CN 2014080344 W CN2014080344 W CN 2014080344W WO 2015062287 A1 WO2015062287 A1 WO 2015062287A1
Authority
WO
WIPO (PCT)
Prior art keywords
terminal
enb
message
local
rrc connection
Prior art date
Application number
PCT/CN2014/080344
Other languages
French (fr)
Chinese (zh)
Inventor
马书宇
谢峰
陈琳
罗宇民
Original Assignee
中兴通讯股份有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 中兴通讯股份有限公司 filed Critical 中兴通讯股份有限公司
Publication of WO2015062287A1 publication Critical patent/WO2015062287A1/en

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W76/00Connection management
    • H04W76/10Connection setup
    • H04W76/14Direct-mode setup

Definitions

  • the present invention relates to the field of communications, and in particular to a local switching method and system for a terminal.
  • BACKGROUND OF THE INVENTION With the development of wireless multimedia services, the demand for high data rates and user experiences is increasing, and higher requirements are placed on the system capacity and coverage of traditional cellular networks. Moreover, the popularity of applications such as social networking, near-field data sharing, and local advertising has led to an increasing demand for PS (Proximity Services) that understands and communicates with people or things of interest nearby.
  • PS Proximity Services
  • the traditional base station-centric cellular network has obvious limitations in supporting high data rates and proximity services.
  • D2D Device-to-Device, device to the new direction of future communication technology development
  • Equipment came into being.
  • the application of D2D technology can reduce the burden on the cellular network, reduce the battery power consumption of the user equipment, increase the data rate, and improve the robustness of the network infrastructure, which satisfies the requirements of the above high data rate services and proximity services.
  • the local switching technology belongs to a branch of the D2D technology.
  • the two terminals communicate, the user data does not need to go through the complete core network process, but the base station directly forwards the user data.
  • the two terminals performing the local exchange may perform data forwarding by the base station under the coverage of the same base station, or may be jointly performed by the two base stations under the coverage of two adjacent base stations.
  • LTE Long Term Evolution
  • SGW Serving Gateway
  • P PGW Packet Data
  • SGW Serving Gateway
  • P PGW Packet Data Gateway
  • This data exchange method increases the load on the SGW and the PGW gateway and the transmission network.
  • the data needs to undergo complicated processing at the base station, and the delay of the user data transmission is large, and the transmission speed is affected.
  • the method of data forwarding by the LTE technology in the related art increases the load of the network equipment of the core network and the transmission delay of the user data.
  • no effective solution has been proposed.
  • a method for local switching of a terminal including: the evolved base station e B cooperates with the first terminal and the second terminal to establish a local bearer, where the local bearer refers to a dedicated need to be used in the local exchange process.
  • the bearer of the device to the device D2D; the eNB forwards the service data between the first terminal and the second terminal through the local bearer to implement local exchange.
  • the evolved base station eNB cooperates with the first terminal and the second terminal to establish a local bearer, including: after the packet data gateway PGW initiates a local bearer setup procedure, the eNB initiates a first radio resource control RRC to the first terminal and the second terminal respectively.
  • the connection reconfiguration process the second radio resource control RRC connection reconfiguration procedure; in the case that both the first RRC connection reconfiguration and the second RRC connection reconfiguration are successful, the eNB determines that the establishment of the local bearer has been completed, otherwise, according to the first
  • the establishment failure message fed back by the terminal and/or the second terminal re-initiates the RRC connection reconfiguration process to the first terminal and/or the second terminal until the establishment of the local bearer is completed.
  • the packet data gateway PGW initiates a local bearer setup procedure, including: after receiving the local bearer setup request message sent by the first terminal, the PGW generates a first transport stream template TFT for the first terminal, and adds a local to the first TFT.
  • the exchanged address type and the IP address of the second terminal where the local bearer setup request message includes: an IP address of the first terminal and an IP address of the second terminal; and the PGW generates a second second terminal according to the IP address of the second terminal a TFT, and adding a locally exchanged address type and an IP address of the first terminal in the second TFT; the PGW generates a first local bearer setup message, where the first local bearer setup message is a message from the PGW to the mobility management entity MME,
  • the local bearer setup message includes: an IP address of the first terminal, a local switching TFT pair composed of the first TFT and the second TFT, and a quality of service QoS parameter;
  • the PGW sends a first local bearer setup message to the MME through the serving gateway SGW, Generating, by the MME, a second local bearer setup message according to the first local bearer setup message, where
  • the local bearer setup message is a message from the MME to the eNB, and the second local bear
  • the eNB initiates a first radio resource control RRC connection reconfiguration procedure and a second radio resource control RRC connection reconfiguration procedure to the first terminal and the second terminal, respectively, including: the eNB initiating the first radio resource control RRC to the first terminal
  • the connection reconfiguration process includes: the eNB generates a first data radio bearer DRB of the first terminal to the eNB according to the first E-RAB ID, and generates a first DRB ID, a first logical channel, and the first corresponding to the first DRB.
  • An LC ID where the reserved value of the first LC ID is used to identify the first logical channel in the process of performing local switching; the eNB generates a first RRC connection reconfiguration message corresponding to the first terminal, where the first RRC connection is heavy
  • the configuration message includes: a first DRB ID, a first LC ID, and a first NAS message corresponding to the first terminal, where the first NAS message carries the first TFT; the eNB sends a first RRC connection reconfiguration message to the first terminal, and initiates The first RRC connection reconfiguration process; And the eNB sends a second radio resource control RRC connection reconfiguration procedure to the second terminal, where: the eNB generates a second data radio bearer DRB of the second terminal to the eNB according to the second E-RAB ID, and generates a second DRB corresponding to the second DRB.
  • the eNB generates a second RRC corresponding to the second terminal
  • the second RRC connection reconfiguration message includes: a second DRB ID, a second LC ID, and a second NAS message corresponding to the second terminal, where the second NAS message carries the second TFT;
  • the second terminal sends a second RRC connection reconfiguration message, and initiates a second RRC connection reconfiguration process.
  • the first DRB and the second DRB have a fixed binding relationship, and the first DRB ID and the second DRB ID are fixedly bound.
  • the method includes: the first terminal binding the first TFT to the first terminal The first DRB, and performing other operations of the first RRC connection reconfiguration; the second terminal binding the second TFT to the second DRB, and performing other operations of the second RRC connection reconfiguration.
  • the method includes: the first terminal sends a first RRC connection reconfiguration complete message to the eNB; and the second terminal sends the second RRC connection to the eNB.
  • Rematch complete message when the eNB receives the first RRC connection reconfiguration complete message and the second RRC connection reconfiguration complete message, the method includes: the eNB sends a first RRC configuration end message to the first terminal, and sends a second message to the second terminal. RRC configuration end message.
  • the eNB forwards the service data between the first terminal and the second terminal by using the local bearer to implement the local exchange, including: after receiving the call request SR signaling sent by the first terminal, the eNB sends the UL grant message to the first terminal.
  • the UL grant signaling carries the uplink resource used when the first terminal sends the service data; the eNB receives the service data from the first terminal through the air interface, and processes the service data by the PHY layer, the MAC layer, and the RLC layer, The service data is sent to the PDCP layer; the eNB allocates a buffer for using the second terminal to receive the service data; and the eNB sends the service data to the second terminal by using the cache.
  • the eNB sends the service data to the second terminal by using the buffer, in one of the following manners: In the first mode, after the eNB service data is placed in the PDCP layer, the eNB is sent to the second terminal by using the buffer; After being above the PDCP layer, it will be sent to the second terminal through the cache;
  • the method of performing encryption on the service data when the data is sent by using the mode 1 includes: when the uplink data packet count value of the first data radio bearer DRB of the first terminal to the eNB reaches a first counting threshold, the eNB sends the first terminal to the first terminal.
  • the method further includes: the eNB or the packet data gateway PGW determining whether local switching is possible.
  • the eNB determines whether the local exchange is possible, the method includes: in the process of attaching by the first terminal, the eNB receives the IP address of the first terminal sent by the mobility management entity MME, and saves the IP address of the first terminal; During the process of attaching the terminal, the eNB receives the IP address of the second terminal sent by the MME, and saves the IP address of the second terminal; when receiving the local exchange request message that is sent by the first terminal and carries the IP address of the second terminal, The eNB determines whether the IP address of the second terminal has been saved locally. If the determination result is yes, it is determined that the first terminal and the second terminal can perform local exchange; if the determination result is negative, the eNB approaches the neighbor.
  • the eNB queries whether the neighboring eNB has saved the IP address of the second terminal. If the query result is yes, it is determined that the first terminal and the second terminal can perform local exchange. If the query result is no, the first terminal and the second terminal cannot be determined. Perform local exchange.
  • the method includes: the eNB sends a local exchange request response message to the first terminal, where the local exchange request response message is used to indicate that the first terminal can The two terminals perform local exchange and initiate the establishment process of the local bearer.
  • the PGW determines whether the local terminal can be exchanged, the method includes: after the first terminal succeeds and the second terminal successfully attaches, the PGW establishes an LTE bearer between the first terminal and the second terminal; and the PGW receives the service sent by the first terminal.
  • Data where the service data includes: an IP address of the first terminal and an IP address of the second terminal; and the PGW determines, according to the IP address of the first terminal and the IP address of the second terminal, whether the first terminal and the second terminal are located.
  • the eNB and the eNB support the local switching function, or whether the first terminal and the second terminal are respectively located under the eNB and the neighboring eNB, and the eNB and the neighboring eNB support the local switching function.
  • a local switching system of a terminal including: an evolved base station e B, a first terminal, a second terminal, a packet data gateway PGW, a serving gateway SGW, and a mobility management entity MME, where
  • the eNB includes: an establishing module, configured to establish a local bearer in cooperation with the first terminal and the second terminal, where The local bearer refers to a bearer dedicated to the device to the device D2D that needs to be used in the local switching process.
  • the forwarding module is configured to forward the service data between the first terminal and the second terminal through the local bearer to implement local exchange.
  • the establishing module includes: an initiating module, configured to: after the PGW initiates the local bearer setup process, initiate a first radio resource control RRC connection reconfiguration process to the first terminal and the second terminal, and the second radio resource control RRC connection weight a processing module, configured to determine that the establishment of the local bearer has been completed if the first RRC connection reconfiguration and the second RRC connection reconfiguration are successful, otherwise, according to the feedback of the first terminal and/or the second terminal A failure message is established, and the RRC connection reconfiguration process is re-initiated to the first terminal and/or the second terminal until the establishment of the local bearer is completed.
  • the PGW is configured to initiate a local bearer setup process
  • the PGW includes: a first receiving module, configured to receive a local bearer setup request message sent by the first terminal; and a first generating module, configured to generate a first transport stream for the first terminal a template TFT, and adding a locally exchanged address type and an IP address of the second terminal in the first TFT, where the local bearer setup request message includes: an IP address of the first terminal and an IP address of the second terminal; And generating, according to the IP address of the second terminal, a second TFT for the second terminal, and adding a locally exchanged address type and an IP address of the first terminal in the second TFT; and a third generation module, configured to generate the first local a bearer setup message, where the first local bearer setup message is a message from the PGW to the MME, and the local bearer setup message includes: an IP address of the first terminal, a local exchange TFT pair composed of the first TFT and the second TFT, and a service a quality Q
  • the initiating module includes: a first generating unit, configured to generate a first data radio bearer DRB of the first terminal to the eNB according to the first E-RAB ID, and generate a first DRB ID corresponding to the first DRB, first a logical channel, and a first LC ID, where the reserved value of the first LC ID is used to identify the first logical channel in a process of performing local switching; and the second generating unit is configured to generate a first RRC corresponding to the first terminal a first RRC connection reconfiguration message, where the first RRC connection reconfiguration message includes: a first DRB ID, a first LC ID, and a first NAS message corresponding to the first terminal, where the first NAS message carries the first TFT; a unit, configured to send a first RRC connection reconfiguration message to the first terminal, to initiate a first RRC connection reconfiguration process, and a third generating unit, configured to generate second data from the second terminal to the eNB according to the second E-RAB ID Radio
  • the first terminal includes: a first binding module, configured to bind the first TFT to the first DRB and perform the first RRC connection after the initiating module initiates the first RRC connection reconfiguration process to the first terminal
  • the second terminal includes: a second binding module, configured to bind the second TFT to the second DRB after the initiating module initiates the second RRC connection reconfiguration process to the second terminal, and perform the Two other operations of RRC connection reconfiguration.
  • the first terminal further includes: a second sending module, configured to: when the first RRC connection reconfiguration succeeds, send a first RRC connection reconfiguration complete message to the e B; the second terminal further includes: the third sending And a module, configured to send a second RRC connection reconfiguration complete message to the eNB if the second RRC connection reconfiguration succeeds.
  • the establishing module further includes: a fourth sending module, configured to send the first RRC configuration end message to the first terminal, when the first RRC connection reconfiguration complete message and the second RRC connection reconfiguration complete message are received Sending a second RRC configuration end message to the second terminal.
  • the forwarding module includes: a second receiving module, configured to receive the call request SR signaling sent by the first terminal; and a fifth sending module, configured to send the UL grant signaling to the first terminal, where the UL grant signaling is Carrying the uplink resource used when the first terminal sends the service data;
  • the third receiving module is configured to receive the service data from the first terminal by using the air interface, and perform processing on the PHY layer, the MAC layer, and the RLC layer of the service data to enable the service data Arriving at the PDCP layer; an allocation module, configured to allocate a buffer for use in receiving the service data to the second terminal; and a sixth sending module, configured to send the service data to the second terminal by using the cache.
  • the sixth sending module sends the service data to the second terminal by using a buffer, in one of the following manners: mode 1, the sixth sending module sends the service data to the PDCP layer, and then sends the data to the second terminal by using the buffer; After the service module is placed on the PDCP layer, the sixth sending module sends the data to the second terminal by using the cache.
  • the data is sent by the sixth sending module to encrypt the service data, including: When the uplink data packet count value of the first data radio bearer DRB of the first terminal to the eNB reaches the first counting threshold, the sixth sending module sends a first Countercheck message to the first terminal to make the first terminal according to the LTE. The process performs a check on the service data.
  • the sixth sending module sends a second Countercheck message to the second terminal.
  • the second terminal performs counting check on the service data according to the LTE process.
  • the e B further includes: a first determining module, configured to determine whether the local exchange can be performed before the establishing module establishes the local bearer; or the PGW further includes: a second determining module, configured to: before the establishing module establishes the local bearer , to determine whether local exchange is possible.
  • the first determining module includes: a first receiving unit, configured to receive an IP address of the first terminal sent by the MME and save the IP address of the first terminal in the process of attaching the first terminal; In the process of attaching the second terminal, receiving the IP address of the second terminal sent by the MME, and saving the IP address of the second terminal; the first determining unit is configured to receive when the first terminal sends the When the local exchange request message of the IP address of the second terminal is used, it is determined whether the IP address of the second terminal has been saved locally; the first determining unit is configured to determine the first terminal and the second terminal if the determination result is yes The local exchange can be performed; the query unit is configured to, if the judgment result is negative, query the neighboring eNB whether the neighboring eNB has saved the IP address of the second terminal; the second determining unit is set to be when the query result is Determining that the first terminal and the second terminal can perform local exchange, and when the query result is no, determining the first terminal and the first Terminal can be locally switched.
  • the eNB further includes: a seventh sending module, configured to send a local exchange request response message to the first terminal, where the first determining module determines that the first terminal and the second terminal can perform local exchange, where the local exchange The request response message is used to indicate that the first terminal can perform local exchange with the second terminal, and initiates a setup process of the local bearer.
  • a seventh sending module configured to send a local exchange request response message to the first terminal, where the first determining module determines that the first terminal and the second terminal can perform local exchange, where the local exchange The request response message is used to indicate that the first terminal can perform local exchange with the second terminal, and initiates a setup process of the local bearer.
  • the second determining module includes: an establishing unit, configured to: after the first terminal succeeds and the second terminal successfully attaches, establish an LTE bearer between the first terminal and the second terminal; and the third receiving unit is configured to receive The service data sent by the first terminal, where the service data includes: an IP address of the first terminal and an IP address of the second terminal; and a second determining unit, configured to be based on the IP address of the first terminal and the IP address of the second terminal Determining whether the first terminal and the second terminal are both located under the eNB and the eNB supports the local switching function, or whether the first terminal and the second terminal are respectively located under the eNB and the neighboring eNB, and the eNB and the neighboring eNB support the local switching function, If the determination result is yes, it is determined that the first terminal and the second terminal can perform local exchange, and if the determination result is no, it is determined that the first terminal and the second terminal cannot perform local exchange.
  • the eNB when the eNB or the PGW determines that the first terminal and the second terminal are capable of local switching, the eNB may establish a local device in cooperation with the first terminal and the second terminal of the eNB or one of the neighboring eNBs. Carrying, and then forwarding the service data between the first terminal and the second terminal by using the local bearer.
  • the method solves the problem that the data forwarding by the LTE technology in the related art increases the load of the network equipment of the core network and the transmission delay of the user data, thereby reducing the load of the network equipment of the core network and shortening the data transmission. Delay, the effect of increasing the speed of data transmission.
  • FIG. 1 is a flow chart of a local switching method of a terminal according to an embodiment of the present invention
  • FIG. 2 is a schematic structural diagram of a local switching system of a terminal according to an embodiment of the present invention
  • FIG. 3 is a schematic diagram of a local switching system of a terminal according to an embodiment of the present invention
  • FIG. 4 is a flow chart of a local exchange according to a preferred embodiment of the present invention
  • FIG. 5 is a flow chart of local bearer establishment according to a preferred embodiment of the present invention
  • FIG. 6 is a preferred embodiment of the present invention.
  • the e B of the example determines whether a message flow chart of the local exchange can be performed
  • FIG. 7 is a message block diagram of the local bearer setup message of the MME to the e B according to a preferred embodiment of the present invention
  • FIG. 8 is a local bearer according to a preferred embodiment of the present invention.
  • FIG. 9 is a block diagram of a locally switched MAC header in accordance with a preferred embodiment of the present invention
  • Figure 10 is a flowchart of an RRC Connection Reconfiguration message in accordance with a preferred embodiment of the present invention
  • Figure 11 is a preferred embodiment in accordance with the present invention.
  • Figure 12 is a flow diagram of a local exchange message in accordance with a preferred embodiment of the present invention
  • 3 is a flow chart of local exchange data processing (PDCP layer forwarding) according to a preferred embodiment of the present invention
  • FIG. 14 is a flow chart of a ConterCheck base station message for preventing illegal intrusion according to a preferred embodiment of the present invention
  • FIG. 15 is a preferred embodiment of the present invention.
  • FIG. 16 is a flow diagram of local exchange data processing (for forwarding over the PDCP layer) in accordance with a preferred embodiment of the present invention.
  • BEST MODE FOR CARRYING OUT THE INVENTION will be described in detail with reference to the accompanying drawings. It should be noted that the embodiments in the present application and the features in the embodiments may be combined with each other without conflict.
  • the embodiment of the present invention mainly provides a method for implementing local exchange of a terminal, and the method can also be used to implement local exchange of a wireless device having similar functions to the terminal in the embodiment of the present invention.
  • the SGW Serving Gateway
  • the PGW Packet Data Gateway
  • the problem of increasing the load of the network equipment of the core network and the transmission delay of the user data may reduce the load of the network equipment of the core network, shorten the transmission delay of the data, and increase the speed of data transmission.
  • the embodiment of the invention provides a local exchange method of a terminal. 1 is a flowchart of a local switching method of a terminal according to an embodiment of the present invention. As shown in FIG.
  • the method mainly includes the following steps (step S102 to step S104): Step S102, an evolved base station (e B ) cooperates with A terminal and a second terminal establish a local bearer, where the local bearer refers to a device-to-device (D2D)-specific bearer that needs to be used in the local switching process; and in step S104, the e B forwards the first terminal and the second terminal by using the local bearer. Business data between to achieve local exchange.
  • the eNB can establish a local bearer in cooperation with the first terminal and the second terminal located in the eNB or one of the neighboring eNBs, and then use the local bearer to forward the service data between the first terminal and the second terminal, which can be reduced.
  • step S102 may be implemented in the following manner: After the packet data gateway PGW initiates a local bearer setup process, the eNB initiates a first radio resource control RRC connection reconfiguration process to the first terminal and the second terminal, respectively.
  • the second radio resource control RC connection reconfiguration process in the case that both the first RC connection reconfiguration and the second RRC connection reconfiguration are successful, the eNB determines that the establishment of the local bearer has been completed, otherwise, according to the first terminal and/or the second The establishment failure message sent by the terminal re-initiates the RRC connection reconfiguration process to the first terminal and/or the second terminal until the establishment of the local bearer is completed.
  • the packet data gateway PGW initiates a local bearer setup process, which may include: after receiving the local bearer setup request message sent by the first terminal, the PGW generates a first transport stream template TFT for the first terminal, And adding the locally exchanged address type and the IP address of the second terminal to the first TFT, where the local bearer setup request message includes: an IP address of the first terminal and an IP address of the second terminal; and the PGW is configured according to the IP address of the second terminal.
  • the second terminal generates a second TFT, and adds a locally exchanged address type and an IP address of the first terminal in the second TFT.
  • the PGW generates a first local bearer setup message, where the first local bearer setup message is from the PGW.
  • the message to the mobility management entity MME includes: an IP address of the first terminal, a local switching TFT pair composed of the first TFT and the second TFT, and a quality of service QoS parameter; the PGW will first through the serving gateway SGW
  • the local bearer setup message is sent to the MME, and the MME generates a second local bearer setup message according to the first local bearer setup message, where the second local bearer setup message is a message from the MME to the eNB, and the second local bearer setup message includes: a first UE ID of a terminal, a second UE ID of the second terminal, a first E-RAB ID of the first terminal, and a second terminal A second E-RAB ID, and QoS parameters.
  • the eNB initiates a first radio resource control RRC connection reconfiguration process and a second radio resource control RRC connection reconfiguration process to the first terminal and the second terminal, which may be implemented in the following manner: Initiating the first radio resource control RRC connection reconfiguration procedure, the method includes: the eNB generates a first data radio bearer DRB of the first terminal to the eNB according to the first E-RAB ID, and generates a first DRB ID corresponding to the first DRB, a logical channel, and a first LC ID, where the reserved value of the first LC ID is used to identify the first logical channel in the process of performing local switching; the eNB generates a first RRC connection reconfiguration message corresponding to the first terminal, The first RRC connection reconfiguration message includes: a first DRB ID, a first LC ID, and a first NAS message corresponding to the first terminal, where the first NAS message carries the first TFT; the eNB sends the first to the first terminal
  • the first DRB ID and the second DRB ID have a fixed binding relationship.
  • the first DRB ID and the second DRB ID form a DRB ID pair.
  • the first terminal may use the first TFT. Binding to the first DRB, and performing other operations of the first RRC connection reconfiguration; the second terminal may bind the second TFT to the second DRB and perform other operations of the second RRC connection reconfiguration.
  • the first terminal may send a first RRC connection reconfiguration complete message to the eNB; the second terminal may send the first eNB to the eNB.
  • the second RRC connection reconfiguration complete message when the eNB receives the first RRC connection reconfiguration complete message and the second RRC connection reconfiguration complete message, the eNB may send a first RRC configuration end message to the first terminal, and send the message to the second terminal.
  • the second RRC configuration end message when both the first RRC connection reconfiguration and the second RRC connection reconfiguration are successful, the first terminal may send a first RRC connection reconfiguration complete message to the eNB; the second terminal may send the first eNB to the eNB.
  • the second RRC connection reconfiguration complete message when the eNB receives the first RRC connection reconfiguration complete message and the second RRC connection reconfiguration complete message, the eNB may send a first RRC configuration end message to the first terminal, and send the message to the second terminal.
  • the second RRC configuration end message when the eNB receives the first R
  • the step S104 may be implemented by: after receiving the call request SR signaling sent by the first terminal, the eNB sends the UL grant signaling to the first terminal, where the UL grant signaling carries the first The uplink resource used by the terminal to send the service data; the eNB receives the service data from the first terminal through the air interface, and processes the service data by the PHY layer, the MAC layer, and the RLC layer, so that the service data reaches the PDCP layer; the eNB is the second terminal. Allocating a buffer for use in receiving service data; the eNB transmits the service data to the second terminal through the cache.
  • the eNB sends the service data to the second terminal by using the buffer, in one of the following manners:
  • the eNB In the first mode, after the eNB service data is placed in the PDCP layer, the eNB sends the data to the second terminal through the buffer. After the data is placed on the PDCP layer, the data is sent to the second terminal by using the buffer. The data is sent to the eNB by the first method.
  • the eNB sends a first Countercheck message to the first terminal to enable the first terminal to check the service data according to the LTE process; when the second terminal sends the second data radio bearer to the eNB.
  • the eNB When the downlink packet count value of the DRB reaches the second technical threshold, the eNB sends a second Countercheck message to the second terminal, so that the second terminal performs the check check on the service data according to the LTE process.
  • the method before the evolved base station eNB cooperates with the first terminal and the second terminal to establish a local bearer, the method further includes: determining, by the eNB or the packet data gateway PGW, whether local exchange is possible.
  • the eNB determines whether the local exchange can be performed, and may be implemented in the following manner: In the process of attaching by the first terminal, the eNB receives the IP address of the first terminal sent by the mobility management entity MME, and saves the first The IP address of the terminal; in the process of attaching the second terminal, the eNB receives the IP address of the second terminal sent by the MME, and saves the IP address of the second terminal; When the local exchange request message of the IP address of the terminal is used, the eNB determines whether the IP address of the second terminal has been saved locally.
  • the method includes: the eNB sends a local exchange request response message to the first terminal, where the local exchange request response message is used to indicate the first terminal.
  • the local terminal can be exchanged with the second terminal, and the establishment process of the local bearer is started.
  • the PGW determines whether the local bearer can be established, and can be implemented in the following manner: After the first terminal succeeds and the second terminal successfully attaches, the PGW establishes an LTE bearer between the first terminal and the second terminal; The PGW receives the service data sent by the first terminal, where the service data includes: an IP address of the first terminal and an IP address of the second terminal; and the PGW determines the first according to the IP address of the first terminal and the IP address of the second terminal.
  • the embodiment of the present invention provides a local switching system for a terminal, which is used to implement the local switching method of the terminal provided by the foregoing embodiment.
  • 2 is a schematic structural diagram of a local switching system of a terminal according to an embodiment of the present invention. As shown in FIG.
  • the system mainly includes: an evolved base station (e B), a first terminal, a second terminal, and a packet data gateway (PGW). ), the Serving Gateway (SGW) and the Mobility Management Entity (MME).
  • the eNB may include: an establishing module 12, configured to establish a local bearer in cooperation with the first terminal and the second terminal, where the local bearer refers to a bearer dedicated to the device to the device D2D that needs to be used in the local switching process; and the forwarding module 14 It is configured to forward the service data between the first terminal and the second terminal by using the local bearer to implement local exchange.
  • the system can be further optimized to obtain a preferred embodiment. This preferred embodiment is further described below in conjunction with FIG.
  • the establishing module 12 may include: an initiating module 122, which is configured. After the local bearer establishment process is initiated on the PGW, the first radio resource control RRC connection reconfiguration process and the second radio resource control RRC connection reconfiguration process are respectively initiated to the first terminal and the second terminal; and the processing module 124 is set to be in the first When both the RRC connection reconfiguration and the second RRC connection reconfiguration are successful, determining the local bearer The establishment has been completed.
  • the PGW is configured to initiate a local bearer setup process, and the PGW includes: a first receiving module 21, configured to receive a local bearer setup request message sent by the first terminal; 22, the first transport stream template TFT is configured to be generated for the first terminal, and the locally exchanged address type and the IP address of the second terminal are added to the first TFT, where the local bearer setup request message includes: the IP of the first terminal The address and the IP address of the second terminal; the second generating module 23 is configured to generate a second TFT for the second terminal according to the IP address of the second terminal, and add the locally exchanged address type and the first terminal in the second TFT
  • the third generation module 24 is configured to generate a first local bearer setup message, where the first local bearer setup message
  • the initiating module 122 includes: a first generating unit 1221, configured to generate a first data radio bearer DRB of the first terminal to the eNB according to the first E-RAB ID, and generate Corresponding to the first DRB ID of the first DRB, the first logical channel, and the first LC ID, where the reserved value of the first LC ID is used to identify the first logical channel in the process of performing local switching; 1222.
  • the first RRC connection reconfiguration message is configured to generate a first RRC connection reconfiguration message, where the first RRC connection reconfiguration message includes: a first DRB ID, a first LC ID, and a first NAS message corresponding to the first terminal.
  • the first NAS message carries the first TFT.
  • the first sending unit 1223 is configured to send a first RRC connection reconfiguration message to the first terminal, and initiate a first RRC connection reconfiguration process.
  • the third generating unit 1224 is configured to Generating, by the second E-RAB ID, a second data radio bearer DRB of the second terminal to the eNB, and generating a second DRB ID, a second logical channel, and a second LC I corresponding to the second DRB D, wherein the reserved value of the second LC ID is used to identify the second logical channel in the process of performing local exchange;
  • the fourth generating unit 1225 is configured to generate a second RRC connection reconfiguration message corresponding to the second terminal, where
  • the second RRC connection reconfiguration message includes: a second DRB ID, a second LC ID, and a second NAS message corresponding to the second terminal, where the second NAS message carries the second TFT;
  • the second sending unit 1226 is configured to Sending a second
  • the first terminal includes: a first binding module 32, configured to: after the initiating module 122 initiates a first RRC connection reconfiguration process to the first terminal, Binding to the first DRB, and performing other operations of the first RRC connection reconfiguration;
  • the second terminal includes: a second binding module 42, configured to: after the initiating module 122 initiates the second RRC connection reconfiguration procedure to the second terminal Binding the second TFT to the second DRB, and performing other operations of the second RRC connection reconfiguration.
  • the first terminal further includes: a second sending module 34, configured to send the first RRC connection reconfiguration to the e B if the first RRC connection reconfiguration succeeds
  • the second terminal further includes: a third sending module 44, configured to send a second RRC connection reconfiguration complete message to the eNB if the second RRC connection reconfiguration succeeds.
  • the establishing module 12 further includes: a fourth sending module 126, configured to receive the first RRC connection reconfiguration complete message and the second RRC connection reconfiguration complete message And sending a first RRC configuration end message to the first terminal, and sending a second RRC configuration end message to the second terminal.
  • the forwarding module 14 includes: a second receiving module 141, configured to receive the call request SR signaling sent by the first terminal; and a fifth sending module 142, configured to be the first The terminal sends the UL grant signaling, where the UL grant signaling carries the uplink resource used by the first terminal to send the service data.
  • the third receiving module 143 is configured to receive the service data from the first terminal through the air interface, and the service data is received.
  • the sixth sending module 145 performs processing on the PHY layer, the MAC layer, and the RLC layer to enable service data to reach the PDCP layer; 44 And being configured to allocate, to the second terminal, a buffer used for receiving the service data; and the sixth sending module 145 is configured to send the service data to the second terminal by using the cache.
  • the sixth sending module 145 sends the service data to the second terminal by using the cache, in one of the following manners: In the first mode, the sixth sending module 145 places the service data in the PDCP. After the layer is sent to the second terminal by using the buffer, the second sending module 145 sends the service data to the second terminal by using the buffer, and then sends the data to the second terminal by using the buffer.
  • the sixth sending module 145 performs the encryption processing on the service data, including: when the uplink data packet count value of the first data radio bearer DRB of the first terminal to the eNB reaches the first counting threshold, the sixth sending module 145 sends the first sending module 145 to the first terminal. a first Countercheck message to enable the first terminal to check the service data according to the LTE process; when the second terminal to the eNB's second data radio bearer DRB When the downlink packet count value reaches the second technical threshold, the sixth sending module 145 sends a second Countercheck message to the second terminal, so that the second terminal performs the check check on the service data according to the LTE process.
  • the e B further includes: a first judging module 16, configured to determine whether the local exchange can be performed before the establishing module 12 establishes the local bearer; or the PGW further includes: The second determining module 26 is configured to determine whether local switching is possible before the establishing module 12 establishes a local bearer.
  • the first determining module 16 includes: a first receiving unit 161, configured to receive an IP address of the first terminal sent by the MME in the process of attaching the first terminal, And storing the IP address of the first terminal; the second receiving unit 162 is configured to receive the IP address of the second terminal sent by the MME and save the IP address of the second terminal in the process of attaching the second terminal;
  • the unit 163 is configured to: when receiving the local exchange request message that is sent by the first terminal and carrying the IP address of the second terminal, determine whether the IP address of the second terminal has been saved locally;
  • the first determining unit 164 is configured to be If the determination result is yes, it is determined that the first terminal and the second terminal can perform local exchange;
  • the query unit 165 is configured to, if the determination result is negative, query the neighboring eNB whether the neighboring eNB has saved the second The IP address of the terminal;
  • the second determining unit 166 is configured to: when the query result is yes, determine that the first terminal and the second terminal
  • the eNB further includes: a seventh sending module 18, configured to: when the first determining module 16 determines that the first terminal and the second terminal are capable of local switching, A terminal sends a local exchange request response message, where the local exchange request response message is used to indicate that the first terminal can perform local exchange with the second terminal, and initiates a local bearer establishment process.
  • the second determining module 26 includes: an establishing unit 262, configured to establish the first terminal and the second terminal after the first terminal succeeds and the second terminal successfully attaches
  • the third receiving unit 264 is configured to receive the service data sent by the first terminal, where the service data includes: an IP address of the first terminal and an IP address of the second terminal; and a second determining unit 266, setting In order to determine whether the first terminal and the second terminal are both located under the eNB according to the IP address of the first terminal and the IP address of the second terminal, and whether the eNB supports the local switching function, or whether the first terminal and the second terminal are respectively located in the eNB and The neighboring eNB and the eNB and the neighboring eNB support the local switching function.
  • the eNB can cooperate with the eNB or one of the first terminals located in the neighboring eNB. Establishing a local bearer with the second terminal, and then using the local bearer to forward the service data between the first terminal and the second terminal, thereby reducing the load on the network device of the core network, shortening the data transmission delay, and improving the data. The effect of the transmission speed.
  • Step 1 A local bearer is established between the first terminal and the second terminal.
  • Step 2 The eNB completes a local exchange process between the first terminal and the second terminal by using a local bearer. Step 1 may further subdivide the following three steps.
  • FIG. 4 A local bearer is established between the first terminal and the second terminal.
  • Step 2 The eNB completes a local exchange process between the first terminal and the second terminal by using a local bearer. Step 1 may further subdivide the following three steps.
  • Step 11 The eNB or the PGW determines whether it is OK. Establish a local bearer.
  • Step 12 The PGW initiates a process of establishing a local bearer.
  • Step 13 The eNB completes the RRC connection reconfiguration and completes the establishment of the local bearer.
  • the eNB or the PGW can first determine whether the local exchange can be performed.
  • data exchange at the PDCP layer and data exchange on the PDCP layer can be adopted.
  • the preferred embodiment of the present invention provides a specific embodiment in which the first terminal and the second terminal establish a local bearer and perform local exchange.
  • the eNB determines whether the local bearer can be established.
  • the first terminal and the second terminal serve the same e B.
  • the locally exchanged data is exchanged at the PDCP layer. Step 1: The eNB determines whether a local bearer can be established.
  • FIG. 6 is a message flow diagram of an eNB determining whether a local exchange can be performed according to a preferred embodiment of the present invention.
  • the specific process of the eNB determining whether a bearer can be established is as follows: The first terminal performs attaching. In the process of attaching, the MME transmits the IP address of the first terminal to the e B through the initial context setup request message, and after receiving the message, the eNB records the IP address of the first terminal, and the second terminal attaches, and is attached. In the process, the MME transmits the IP address of the second terminal to the eNB through the initial context setup request message, and after receiving the message, the eNB records the IP address of the second terminal.
  • the first terminal When the first terminal has data to send to the second terminal, the first terminal sends a local exchange request message to the eNB.
  • the message carries the IP address of the second terminal.
  • the eNB obtains the IP address of the second terminal from the message, and determines whether the local terminal can be exchanged.
  • the determining method is as follows: The eNB determines whether the eNB records the IP address of the second terminal, and if the judgment result is that the eNB records the second terminal. The eNB considers that the first terminal and the second terminal can perform local exchange. If the eNB determines that the eNB does not record the IP address of the second terminal, the eNB sends an IP address query to the neighboring eNB through the X2 interface.
  • the message carries the IP address of the second terminal, and the neighboring eNB determines whether the IP address of the second terminal is recorded after receiving the message. If the neighboring eNB supports the local exchange and records the IP address of the second terminal, and then returns an IP address query response message, indicating that the IP address is queried, the eNB considers that the first terminal and the second terminal can perform localization after receiving the message. Exchange, otherwise the neighboring eNB returns an IP address query response message, indicating that the IP address is not queried. After receiving the message, the eNB considers that the first terminal and the second terminal cannot perform the exchange.
  • the eNB records the IP address of the second terminal, and after obtaining the IP address of the second terminal, the eNB determines the IP address of the second terminal recorded by the local eNB, and the eNB considers that A terminal and a second terminal can perform local exchange.
  • the eNB returns a local exchange request response message to the first terminal, indicating that the first terminal and the second terminal can perform local exchange.
  • the first terminal sends a local exchange bearer setup request message to the PGW, where the message carries the IP address of the first terminal and the IP address of the second terminal.
  • Step 2 The PGW initiates a process of establishing a local bearer.
  • the PGW After receiving the local exchange bearer setup request message of the first terminal, the PGW generates a TFT of the first terminal for local exchange, and first generates a TFT of the first terminal (that is, the first TFT) according to a normal process, and then A new type (ie, a locally exchanged address type) is added to the packet filter content unit of the packet filter of the TFT of the first terminal.
  • a new type ie, a locally exchanged address type
  • the address type exchanged locally is followed by the IP address of the target UE, that is, the IP address of the second terminal, and can only contain the IP address of the second terminal.
  • the PGW also generates a TFT for the second terminal for local exchange (ie, the second TFT described above), first generates a TFT of the second terminal according to a normal flow, and then performs a packet filter content unit of the packet filter of the second terminal TFT.
  • a new type has been added (that is, the address type of the local exchange).
  • the address type exchanged locally is followed by the IP address of the target UE, that is, the IP address of the first terminal, and can only contain the IP address of the first terminal.
  • the local switching TFT of the first terminal and the local switching TFT of the second terminal form a TFT pair.
  • the PGW generates a local bearer setup message, which contains the parameters contained in the normal bearer setup message. It also includes the local exchange TFT pair and the IP address of the second terminal.
  • the PGW generates a local bearer setup message from the PGW to the MME, and the message is sent to the MME through the SGW.
  • the MME determines, according to the IP address of the second terminal, the second terminal, and obtains the MME UE SIAP ID value and the eNB UE SIAP ID value of the second terminal according to the context information of the second terminal, and the UE Aggregate Maximum Bit Rate of the second terminal. value.
  • the MME generates an E-RAB ID of the first terminal (ie, the first E-RAB ID) and an E-RAB ID of the second terminal (ie, the second E-RAB ID) according to the message.
  • the MME also generates a NAS message and packs it into the NAS PDU and the NAS PDU2 parameters, and includes the first terminal NAS message in the NAS PDU parameter, which includes the local switching TFT corresponding to the first terminal, and is included in the NAS PDU2 parameter.
  • the second terminal NAS message includes a local switching TFT corresponding to the second terminal.
  • the MME generates a local bearer setup message from the MME to the eNB.
  • 7 is a message block diagram of a local bearer setup message of an MME to an eNB according to a preferred embodiment of the present invention. As shown in FIG.
  • the message includes the following parameters: MME UE S1AP ID, eNB UE SIAP ID, UE Aggregate Maximum Bit Rate, E-RAB ID, NAS-PDU, E-RAB Level QoS Parameters, MME UE S1AP ID2, eNB UE S1AP ID2, UE Aggregate Maximum Bit Rate2, E-RAB ID2, NAS-PDU2 where MME UE SIAP ID, eNB UE SIAP ID , UE Aggregate Maximum Bit Rate, E-RAB ID is a parameter related to the first terminal, MME UE SIAP ID2, eNB UE S1AP ID2, UE Aggregate Maximum Bit Rate2, E-RAB ID2, NAS-PDU2 is a second terminal related parameter .
  • FIG. 8 is a flow chart of establishing a local bearer according to a preferred embodiment of the present invention. As shown in FIG. 8, the PGW is generated to
  • the local bearer setup message of the MME includes the TFT pair, the IP address of the second terminal, and parameters such as Qos.
  • the message is sent to the MME via the SGW.
  • the MME After receiving the message, the MME generates a local bearer setup message of the MME to the eNB, where the message includes the UE ID of the first terminal and the second terminal, and the E-RAB ID and Qos parameters of the first terminal and the second terminal.
  • the MME sends the message to e B.
  • Step 3 The eNB completes the RRC connection reconfiguration and completes the establishment of the local bearer.
  • the eNB After receiving the local bearer setup message sent by the MME, the eNB generates a DRB pair and generates a corresponding DRB ID pair and an LCID pair according to the E-RAB ID pair of the message.
  • the eNB generates a data radio bearer (DRB) of the first terminal to the eNB according to the E-RAB ID parameter corresponding to the first terminal in the message, and generates a data radio bearer identifier DRB ID.
  • DRB data radio bearer
  • the eNB generates a data radio bearer (DRB) of the second terminal to the eNB according to the E-RAB ID2 parameter corresponding to the second terminal in the message, and generates a data radio bearer identifier DRB ID2, where the two DRBs have a fixed binding relationship, and the same
  • the DRB ID and DRB ID2 also have a fixed binding relationship.
  • the DRB ID and DRB ID2 form a DRB ID pair.
  • the eNB generates a logical channel corresponding to the DRB of the first terminal to the eNB, and generates an LCID
  • the eNB generates a logical channel corresponding to the DRB of the second terminal to the eNB, and generates an LCID2.
  • FIG. 9 is a block diagram of a locally exchanged MAC header according to a preferred embodiment of the present invention. As shown in FIG. 9, when generating a MAC subheader, the eNB may use the original R bit, that is, a reserved bit, to indicate that it is a locally switched Mac. Sub-header format, you can change the R bit to the T bit, that is, the type bit.
  • the eNB adds an LSdrb-ToAddModList field in the RadioResourceConfigDedicated field in the RRC Connection Reconfiguration message, which field contains the DRB ID used by the local exchange. After generating the locally exchanged DRB pair and the logical channel and generating the DRB ID pair and the LCID, the eNB separately generates an RRC connection reconfiguration message from the eNB to the first terminal and an RRC connection reconfiguration message from the eNB to the second terminal.
  • the RRC connection reconfiguration message of the eNB to the first terminal includes parameters such as a DRB ID and an LCID corresponding to the DRB of the eNB to the first terminal, and the eNB obtains the NAS message included in the NAS PDU parameter of the bearer setup message of the MME to the eNB, and The NAS message is carried by the RRC connection reconfiguration message, and the NAS message includes the locally exchanged TFT corresponding to the first terminal.
  • the RRC connection reconfiguration message of the eNB to the second terminal includes parameters such as DRB ID2 and LCID2 corresponding to the DRB of the second terminal to the eNB, and the eNB obtains the NAS message included in the NAS PDU parameter of the bearer setup message from the MME to the eNB, and The NAS message is carried by the connection reconfiguration message, where the NAS message includes a local switching TFT corresponding to the second terminal.
  • the eNB After the eNB generates an RRC connection reconfiguration message, the RRC connection reconfiguration is initiated.
  • FIG. 10 is a flowchart of an RRC connection reconfiguration message according to a preferred embodiment of the present invention. As shown in FIG.
  • the eNB sends an RRC connection reconfiguration message from the eNB to the first terminal to the first terminal, and sends the eNB to the second terminal.
  • the RRC connection reconfiguration message of the second terminal After receiving the connection reconfiguration message, the first terminal will generate a local exchange DRB of the first terminal to the eNB, and the DRB will be identified by the DRB ID, and the local switching TFT will be bound to the local exchange DRB, and the first terminal will be first.
  • the local switching TFT of the terminal is bound to the local exchange DRB of the first terminal to the eNB.
  • complete other operations of RRC connection reconfiguration After completing the RRC connection reconfiguration, the first terminal returns an RRC connection reconfiguration complete message to the eNB.
  • the second terminal After receiving the RRC connection reconfiguration message, the second terminal performs TFT bonding, and generates a local switching DRB of the second terminal to the eNB, where the DRB is identified by DRB ID2, and the local switching TFT is switched to the local switching DRB. Binding, binding the local switching TFT of the second terminal to the second terminal to the local exchange DRB of the eNB. And complete other operations of RRC connection reconfiguration.
  • the first terminal After completing the RRC connection reconfiguration, the first terminal returns an RRC connection reconfiguration complete message to the eNB.
  • the eNB After receiving the RRC connection reconfiguration complete message of the first terminal and the RRC connection reconfiguration complete message of the second terminal, the eNB. And sending an RRC configuration end message to the first terminal and the second terminal respectively.
  • the first terminal After receiving the RRC configuration end message, the first terminal starts local data exchange with the second terminal, and after receiving the RRC configuration end message, the second terminal starts local data exchange with the first terminal.
  • the above is the normal flow of the RRC connection reconfiguration and the configuration is successful. If the RRC connection reconfiguration fails, the RRC connection reconfiguration exception procedure is entered.
  • 11 is a flowchart of an RRC connection reconfiguration failure message according to a preferred embodiment of the present invention. As shown in FIG. 11, after the eNB sends an RRC connection reconfiguration message to the first terminal, if the first terminal is performing RRC connection reconfiguration, The reconfiguration failure fails.
  • an RRCConnectionConfigurationFailure message is added in the RRC connection reconfiguration exception procedure of the local exchange, and the message indicates that the RRC connection configuration of the local exchange fails.
  • the first terminal sends the message to e B, and the first terminal may carry an RRCConnectionConfigurationFigurationCause unit in the message, the unit indicating the reason for the failure.
  • the eNB may re-allocate the RRC connection reconfiguration related parameter for the local exchange communication according to the failure reason, and resend the RRCConnectionReconfiguration message.
  • the first terminal returns the RRCConnectionReconfigurationComplete message, and the eNB performs the following process, after receiving the first terminal and The RRCConnectionReconfigurationComplete message of the second terminal sends a bearer setup response to the MME, indicating that the local bearer is successfully established. If the configuration is successful, the first terminal will return the RRCConnectionConfigurationFailure message a second time, and the eNB sends a bearer setup response to the MME, where the message is E. In the -RAB Failed to Setup List unit, it indicates that the local bearer setup failed due to the RRC connection reconfiguration failure with the first terminal.
  • the eNB further sends an RRC connection reconfiguration recovery message to the second terminal, and restores the second terminal to the state before the connection reconfiguration.
  • Step four the local exchange process. After the local exchange bearer is established, local data exchange will take place.
  • 12 is a flow chart of a local exchange message according to a preferred embodiment of the present invention. As shown in FIG. 12, when the first terminal has data to transmit, the first terminal sends scheduling request signaling, that is, SR signaling, and the eNB receives the SR. After the signaling, the UL grant signaling is sent, where the signaling includes the uplink transmission resource allocated for the first terminal, but the uplink resource allocated by the UL grant is very limited.
  • the first terminal after receiving the UL grant signaling, the first terminal sends a BSR message to the eNB for the uplink resource allocated by the eNB, where the message carries the buffer (ie, cache) of the data to be sent by the first terminal. size.
  • eNB After the message, the buffer size of the data to be sent by the first terminal will be obtained.
  • the eNB checks the size of the space left by the forwarding buffer used for the local exchange. If the remaining space of the forwarding buffer is greater than the buffers of the data to be sent by the first terminal, the eNB allocates uplink resources to the first terminal and sends UL grant signaling. After receiving the uplink signaling, the first terminal sends the service data on the uplink resource allocated by the eNB.
  • FIG. 13 is a flowchart of local exchange data processing (PDCP layer forwarding) according to a preferred embodiment of the present invention.
  • the first terminal sends service data to the second terminal.
  • the switching TFT is mapped to the locally switched DRB of the first terminal, and after being processed by the PDCP layer, the RLC layer, the MAC layer, and the PHY layer, is sent out through the air interface.
  • the eNB After receiving the data sent by the first terminal, the eNB passes through the PHY layer, the MAC layer, and the RLC layer to reach the PDCP layer.
  • locally exchanged data is forwarded at the PDCP layer.
  • the eNB After the data passes through the RLC layer, among the DRBs corresponding to the DRB ID exchanged locally by the eNB, the eNB reads data from the DRB, writes it into the forwarding buffer, and records the packet read from the DRB. Number, record it as countMSB-Uplink.
  • the eNB allocates downlink resources to the second terminal, and reads data from the forwarding buffer, and writes the data into the DRB corresponding to the local exchange DRB ID2 of the eNB. And record the number of packets written to the DRB, and record it as countMSB-Downlink.
  • the data After the data is written into the DRB corresponding to the DRB ID2 of the eNB, it is processed by the RLC layer, the MAC layer, and the PHY layer, and is sent to the second terminal. After receiving the data, the second terminal passes the PHY layer and the MAC layer. After the RLC layer and the PDCP layer are processed, the data is written into the DRB corresponding to the second terminal local exchange DRB ID2, and the data is mapped to the service layer through the mapping of the second terminal local switching TFT. Forwarding at the PDCP layer, data encryption and decryption processing is performed between the first terminal and the second terminal. However, in order to prevent the data between the first terminal and the eNB from being attacked by the intruder.
  • the local exchange countercheck mechanism is adopted between the eNB and the first terminal, and the local exchange countercheck mechanism is also adopted between the eNB and the second terminal.
  • 14 is a message flow diagram of a ConterCheck base station for preventing illegal intrusion according to a preferred embodiment of the present invention.
  • the eNB A Countercheck message is sent to the first terminal, and the drb-CountMSB-InfoList field of the message will contain the value of countMSB-Uplink.
  • the first terminal performs a Countercheck check according to the normal LTE procedure. And return the CounterCheckResponse message.
  • the eNB When the value of the countMSB-Downlink of the DRB corresponding to the DRB ID2 of the eNB reaches a certain value, the eNB sends a Countercheck message to the second terminal, and the drb-CountMSB-InfoList field of the message will contain the value of countMSB-Uplink.
  • the second terminal performs a CountCheck check according to a normal LTE process. And return the CounterCheckResponse message. Only when the eNB and the first terminal and the eNB and the second terminal are both correct, it is considered that the local switching link between the first terminal and the second terminal passes the Countercheck check.
  • the preferred embodiment of the present invention provides a specific embodiment in which the first terminal and the second terminal establish a local bearer and perform local exchange.
  • the PGW determines whether the local bearer can be established.
  • the first terminal and the second terminal are served by the same eNB, and are also under the management of the same PGW.
  • the locally exchanged data is exchanged over the PDCP layer.
  • Step 1 The PGW determines whether a local bearer can be established.
  • FIG. 15 is a message flow diagram of a PGW determining whether a local exchange can be performed according to a preferred embodiment of the present invention. As shown in FIG. 15, the specific process of the PGW determining whether a bearer can be established is as follows: The first terminal performs attaching. The second terminal performs the attaching.
  • the PGW When the first terminal has data to be sent to the second terminal, the PGW is requested to establish a normal bearer. After the normal LTE bearer is established, the first terminal sends data to the second terminal through the bearer. The data packet sent by the first terminal to the second terminal will pass through the PGW, and the PGW obtains the destination address of the data packet from the data packet sent by the first terminal. In this embodiment, the destination address of the first terminal data packet is the IP address of the second terminal. The PGW can obtain, according to the IP address of the second terminal, that the destination of the data packet sent by the first terminal is the second terminal. The PGW determines whether the first terminal and the second terminal are in the same eNB.
  • the PGW considers that the first terminal and the second terminal can perform the If the first terminal and the second terminal are not in the same eNB, the first terminal and the second terminal are determined to be in the neighboring eNB, and the two neighboring eNBs support the local switching function. Condition, the first terminal and the second terminal can perform local exchange. If the above two conditions are not met, the first terminal and the second terminal cannot perform local exchange. In this embodiment, the first terminal and the second terminal serve the same e B, so that local exchange can be performed, and the PGW will initiate a local bearer establishment process. Step 2: The PGW initiates a process of establishing a local bearer.
  • the PGW initiates a process of establishing a local bearer, and the PGW generates a TFT for the first terminal for local exchange (ie, the first TFT), first generates a TFT of the first terminal according to a normal process, and then filters the packet of the TFT in the first terminal.
  • a new type ie, the locally exchanged address type
  • the locally exchanged address type is followed by the IP address of the target UE (ie, the IP address of the second terminal), and Contains the IP address of the second terminal.
  • the PGW also generates a TFT for the second terminal for local exchange (ie, the above second TFT), first generates a TFT of the second terminal according to a normal flow, and then a packet filter content unit of the packet filter of the second terminal TFT , A new type (ie, the locally exchanged address type) is added, and the locally exchanged address type is followed by the IP address of the target UE (ie, the IP address of the first terminal), and can only contain the IP address of the first terminal.
  • the local switching TFT of the first terminal and the local switching TFT of the second terminal constitute a TFT pair.
  • the PGW generates a local bearer setup message, which contains the parameters contained in the normal bearer setup message. It also includes the local exchange TFT pair and the IP address of the second terminal.
  • the PGW generates a local bearer setup message from the PGW to the MME, and the message is sent to the MME through the SGW.
  • the MME determines, according to the IP address of the second terminal, the second terminal, and obtains the MME UE SIAP ID value and the eNB UE SIAP ⁇ ) value of the second terminal according to the context information of the second terminal. And the value of the UE Aggregate Maximum Bit Rate of the second terminal.
  • the MME generates an E-RAB ID (ie, the first E-RAB ID) of the first terminal and a second terminal E-RAB ID (ie, the second E-RAB ID) according to the message.
  • the MME also generates a NAS message and packs it into the NAS PDU and NAS PDU2 parameters, and includes the first terminal NAS message in the NAS PDU parameter, which includes the local switching TFT corresponding to the first terminal, and is included in the NAS PDU2 parameter.
  • the second terminal NAS message includes a local switching TFT corresponding to the second terminal.
  • the MME generates a local bearer setup message of the MME to the eNB.
  • 7 is a message block diagram of a local bearer setup message of an MME to an eNB according to a preferred embodiment of the present invention. As shown in FIG.
  • the message includes the following parameters: MME UE S1AP ID, eNB UE SIAP ID, UE Aggregate Maximum Bit Rate, E-RAB ID, NAS-PDU, E-RAB Level QoS Parameters, MME UE S1AP ID2, eNB UE S1AP ID2, UE Aggregate Maximum Bit Rate2, E-RAB ID2, NAS-PDU2 where MME UE SIAP ID, eNB UE SIAP ID , UE Aggregate Maximum Bit Rate, E-RAB ID is a parameter related to the first terminal, MME UE SIAP ID2, eNB UE S1AP ID2, UE Aggregate Maximum Bit Rate2, E-RAB ID2, NAS-PDU2 is a second terminal related parameter .
  • FIG. 8 is a flowchart of a local bearer setup according to a preferred embodiment of the present invention.
  • the PGW initiates a local bearer setup process.
  • the PGW generates a local bearer setup message to the MME, where the message includes a TFT pair, and the second terminal. IP address, and parameters such as Qos.
  • the message is sent to the MME via the SGW.
  • the MME After receiving the message, the MME generates a local bearer setup message of the MME to the eNB, where the message includes the UE ID of the first terminal and the second terminal, and the E-RAB ID and Qos parameters of the first terminal and the second terminal.
  • the MME sends the message to the eNB.
  • Step 3 The eNB completes the RRC connection reconfiguration and completes the establishment of the local bearer.
  • the eNB After receiving the local bearer setup message sent by the MME, the eNB generates a DRB pair and generates a corresponding DRB ID pair and an LCID pair according to the E-RAB ID pair of the message.
  • the eNB generates a data radio bearer (DRB) of the first terminal to the eNB according to the E-RAB ID parameter corresponding to the first terminal in the message, and generates a data radio bearer identifier DRB. ID.
  • the eNB generates a data radio bearer (DRB) of the second terminal to the eNB according to the E-RAB ID2 parameter corresponding to the second terminal in the message, and generates a data radio bearer identifier DRB ID2, where the two DRBs have a fixed binding relationship.
  • the DRB ID and the DRB ID2 also have a fixed binding relationship, and the DRB ID and the DRB ID2 form a DRB ID pair.
  • the eNB generates a logical channel corresponding to the DRB of the first terminal to the eNB, and generates an LCID
  • the eNB generates a logical channel corresponding to the DRB of the second terminal to the eNB, and generates an LCID2.
  • e B can break the limit of the number of radio bearer identifiers specified in the current protocol.
  • the eNB can also break the limit of the number of logical channel identifiers specified by the current protocol.
  • 9 is a block diagram of a locally exchanged MAC header according to a preferred embodiment of the present invention. As shown in FIG.
  • the eNB when generating a MAC subheader, the eNB may use the original R bit, that is, a reserved bit, to indicate that it is a locally switched Mac. Sub-header format, you can change the R bit to the T bit, that is, the type bit. You can use 1 to indicate the MAC sub-header of the local exchange, and 0 to indicate the normal MAC header. And when performing local exchange, the reserved value of the LCID can be used to identify the logical channel of the local exchange to reach the extension of the number of LCIDs.
  • the eNB adds an LSdrb-ToAddModList field in the RadioResourceConfigDedicated field in the RRC Connection Reconfiguration message, which field contains the DRB ID used by the local exchange.
  • an RRC connection reconfiguration message from the eNB to the first terminal and an RRC connection reconfiguration message from the eNB to the second terminal are generated.
  • the RRC connection reconfiguration message of the eNB to the first terminal includes parameters such as a DRB ID and an LCID corresponding to the DRB of the eNB to the first terminal, and the eNB obtains the NAS message included in the NAS PDU parameter of the bearer setup message of the MME to the eNB, and
  • the NAS message is carried by the RRC connection reconfiguration message, and the NAS message includes the locally exchanged TFT corresponding to the first terminal.
  • the RRC connection reconfiguration message of the eNB to the second terminal includes parameters such as DRB ID2 and LCID2 corresponding to the DRB of the second terminal to the lj eNB, and the eNB obtains the NAS message included in the NAS PDU parameter of the bearer setup message of the MME to the eNB, And the NAS message is carried by the connection reconfiguration message, where the NAS message includes the local switching TFT corresponding to the second terminal.
  • the RRC connection reconfiguration is initiated.
  • FIG. 10 is a flowchart of the RRC connection reconfiguration message according to the preferred embodiment of the present invention. As shown in FIG.
  • the RRC connection reconfiguration process includes: A terminal sends an RRC connection reconfiguration message of the eNB to the first terminal, and sends an RRC connection reconfiguration message of the eNB to the second terminal to the second terminal.
  • the first terminal After receiving the connection reconfiguration message, the first terminal generates a local exchange DRB of the first terminal to the eNB, and the DRB identifies the DRB ID, and performs binding of the local switching TFT to the local exchange DRB, and the first The local switching TFT of the terminal is bound to the local exchange DRB of the first terminal to the eNB. And complete other operations of RRC connection reconfiguration. After completing the RRC connection reconfiguration, the first terminal returns an RRC connection reconfiguration complete message to the eNB.
  • the second terminal After receiving the RRC connection reconfiguration message, the second terminal will perform TFT binding, and will generate a local exchange DRB of the second terminal to the eNB, the DRB will be identified by DRB ID2, and the local switching TFT will be performed to the local exchange DRB. Binding, binding the local switching TFT of the second terminal to the second terminal Go to the local exchange DRB of the eNB. And complete other operations of RRC connection reconfiguration.
  • the first terminal After completing the RRC connection reconfiguration, the first terminal returns an RRC connection reconfiguration complete message to the eNB.
  • the eNB After receiving the RRC connection reconfiguration complete message of the first terminal and the RRC connection reconfiguration complete message of the second terminal, the eNB. And sending an RRC configuration end message to the first terminal and the second terminal respectively.
  • the first terminal After receiving the RRC configuration end message, the first terminal starts to perform local data exchange with the second terminal, and after receiving the RRC configuration end message, the second terminal starts to perform local data exchange with the first terminal, where the RRC connection reconfiguration is configured. If the RRC connection reconfiguration configuration fails, the RRC connection reconfiguration exception procedure is entered.
  • 11 is a flowchart of an RRC connection reconfiguration failure message according to a preferred embodiment of the present invention. As shown in FIG. 11, after the eNB sends an RRC connection reconfiguration message to the first terminal, if the first terminal is performing RRC connection reconfiguration, The reconfiguration failure fails.
  • an RRCConnectionConfigurationFailure message is added in the RRC connection reconfiguration exception procedure of the local exchange, and the message indicates that the RRC connection configuration of the local exchange fails.
  • the first terminal sends the message to e B, and the first terminal may carry an RRCConnectionConfigurationFigurationCause unit in the message, the unit indicating the reason for the failure.
  • the eNB may re-allocate the RRC connection reconfiguration related parameter for the local exchange communication according to the failure reason, and resend the RRCConnectionReconfiguration message.
  • the first terminal returns the RRCConnectionReconfigurationComplete message, and the eNB performs the following process, after receiving the first terminal and The RRCConnectionReconfigurationComplete message of the second terminal sends a bearer setup response to the MME, indicating that the local bearer is successfully established. If the configuration is successful, the first terminal will return the RRCConnectionConfigurationFailure message a second time, and the eNB sends a bearer setup response to the MME, where the message is E. In the -RAB Failed to Setup List unit, it indicates that the local bearer setup failed due to the RRC connection reconfiguration failure with the first terminal.
  • FIG. 12 is a flow chart of a local exchange message according to a preferred embodiment of the present invention. As shown in FIG.
  • the message flow of the local data exchange includes: when the first terminal has data to send, the first terminal sends a scheduling request signaling, that is, The SR signaling, after receiving the SR signaling, the eNB sends the UL grant signaling, where the signaling includes the uplink transmission resource allocated for the first terminal, but the uplink resource allocated by the UL grant is very limited.
  • the first terminal after receiving the UL grant signaling, the first terminal sends a BSR message to the eNB for the uplink resource allocated by the eNB, where the message carries the size of the buffer of the data to be sent by the first terminal. After receiving the message, the eNB obtains the buffer size of the data to be sent by the first terminal.
  • FIG. 16 is a flowchart of local exchange data processing (for forwarding on the PDCP layer) according to a preferred embodiment of the present invention. As shown in FIG. 16, in the preferred embodiment, the service data of the first terminal to the second terminal is shown in FIG.
  • the local switching TFT is mapped to the DRB corresponding to the DRB ID of the local exchange of the first terminal, and then sent out through the air interface.
  • the eNB After receiving the data sent by the first terminal, the eNB passes through the PHY layer, the MAC layer, and the RLC layer to reach the PDCP layer.
  • the eNB After the data passes through the PDCP layer, it is already in the DRB corresponding to the DRB ID exchanged locally by the eNB, and the data of the first terminal to the eNB has been protected by the encryption and decryption processing of the PDCP layer and countercheck, and the eNB processes the data security. It can be processed according to the current agreement.
  • the eNB reads data from the DRB and writes it into the forwarding buffer.
  • the eNB allocates downlink resources to the second terminal, and reads data from the forwarding buffer, and writes the data to the local exchange DRB ID2 corresponding to the eNB. DRB.
  • the data After the data is written into the DRB corresponding to the DRB ID2, it is processed by the PDCP layer, the RLC layer, the MAC layer, and the PHY layer, and is sent to the second terminal.
  • the data between the eNB and the second terminal has been encrypted and decrypted by the PDCP layer and counterchecked by the PDCP layer.
  • the eNB can process the data security according to the current protocol.
  • the data is processed by the PHY layer, the MAC layer, the RLC layer, and the PDCP layer, and the data is written into the DRB corresponding to the local exchange DRB ID2 of the second terminal, and is locally exchanged by the second terminal. TFT mapping, data reaches the business layer.
  • each of the above modules can be implemented by hardware.
  • a processor including the above modules, or each of the above modules is located in one processor.
  • software is also provided for performing the technical solutions described in the above embodiments and preferred embodiments.
  • a storage medium is provided, the software being stored, including but not limited to: an optical disk, a floppy disk, a hard disk, a rewritable memory, and the like. From the above description, it can be seen that the present invention achieves the following technical effects: When the eNB or the PGW determines that the first terminal and the second terminal can perform local exchange, the eNB can cooperate with the eNB or one of the neighboring eNBs.
  • the first terminal and the second terminal establish a local bearer, and then use the local bearer to forward the service data between the first terminal and the second terminal, and solve the related art to perform data forwarding by using the LTE technology.
  • the method increases the load of the network equipment of the core network and the transmission delay of the user data, and achieves the effect of reducing the load of the network equipment of the core network, shortening the transmission delay of the data, and improving the data transmission speed.
  • the computing device may be implemented by program code executable by the computing device, such that they may be stored in the storage device by the computing device and, in some cases, may be different from the order herein.
  • the steps shown or described are performed, or they are separately fabricated into individual integrated circuit modules, or a plurality of modules or steps are fabricated as a single integrated circuit module.
  • the invention is not limited to any specific combination of hardware and software.
  • the above is only the preferred embodiment of the present invention, and is not intended to limit the present invention, and various modifications and changes can be made to the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and scope of the present invention are intended to be included within the scope of the present invention.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

Disclosed are a method and a system for local exchange of a terminal. The method comprises: an evolved base station eNB coordinating with a first terminal and a second terminal to establish a local carrier, where the local carrier refers to a carrier dedicated to device-to-device (D2D) that needs to be used in a local exchange process; and the eNB forwarding service data between the first terminal and the second terminal by using the local carrier to implement local exchange. By means of the present invention, effects of reducing load of a network device in a core network, shortening a transmission delay of data, and improving a transmission speed of data are achieved.

Description

终端的本地交换方法及系统 技术领域 本发明涉及通信领域, 具体而言, 涉及一种终端的本地交换方法及系统。 背景技术 随着无线多媒体业务的发展, 人们对高数据速率和用户体验的需求日益增长, 从 而对传统蜂窝网络的系统容量和覆盖提出了较高要求。 而且, 社交网络、 近距离数据 共享、本地广告等应用的流行使得人们对了解附近感兴趣的人或事物并与之通信的 PS (Proximity Services, 邻近服务) 的需求逐渐增加。 传统的以基站为中心的蜂窝网络 在高数据速率以及邻近服务的支持方面存在明显的局限性, 在这种需求背景下, 代表 未来通信技术发展新方向的 D2D (Device-to-Device,设备到设备)技术应运而生。 D2D 技术的应用, 可以减轻蜂窝网络的负担、 减少用户设备的电池功耗、 提高数据速率, 并改善网络基础设施的鲁棒性, 很好地满足上述高数据速率业务和邻近服务的要求。 本地交换技术属于 D2D技术的一个分支, 本地交换技术是指两个终端进行通信时, 用 户数据不需要走完整的核心网流程, 而是由基站直接对用户数据进行转发。 进行本地 交换的两个终端可以在同一个基站的覆盖范围下, 由该基站进行数据转发, 也可以分 别在两个相邻的基站覆盖范围下, 由这两个基站联合进行数据转发。  TECHNICAL FIELD The present invention relates to the field of communications, and in particular to a local switching method and system for a terminal. BACKGROUND OF THE INVENTION With the development of wireless multimedia services, the demand for high data rates and user experiences is increasing, and higher requirements are placed on the system capacity and coverage of traditional cellular networks. Moreover, the popularity of applications such as social networking, near-field data sharing, and local advertising has led to an increasing demand for PS (Proximity Services) that understands and communicates with people or things of interest nearby. The traditional base station-centric cellular network has obvious limitations in supporting high data rates and proximity services. In the context of this demand, D2D (Device-to-Device, device to the new direction of future communication technology development) Equipment) technology came into being. The application of D2D technology can reduce the burden on the cellular network, reduce the battery power consumption of the user equipment, increase the data rate, and improve the robustness of the network infrastructure, which satisfies the requirements of the above high data rate services and proximity services. The local switching technology belongs to a branch of the D2D technology. When the two terminals communicate, the user data does not need to go through the complete core network process, but the base station directly forwards the user data. The two terminals performing the local exchange may perform data forwarding by the base station under the coverage of the same base station, or may be jointly performed by the two base stations under the coverage of two adjacent base stations.
LTE (Long Term Evolution, 长期演进)技术目前不支持本地交换, 在同一基站覆 盖范围下, 或相邻基站覆盖范围下, 点对点数据交换需通过 SGW ( Serving Gateway, 服务网关) 禾 P PGW (Packet Data Network Gateway, 分组数据网关) 的转发处理。 这 种数据交换方法增加了 SGW和 PGW网关和传输网络的负荷, 此外, 由于数据传输的 路径长, 数据在基站需要经过复杂的处理, 用户数据传输的时延大, 传输的速度受到 影响。 针对相关技术中通过 LTE技术进行数据转发的方式会增加核心网的网络设备的负 荷、 用户数据的传输时延的问题, 目前尚未提出有效的解决方案。 发明内容 本发明实施例提供了一种终端的本地交换方法及系统, 以至少解决相关技术中通 过 LTE技术进行数据转发的方式会增加核心网的网络设备的负荷、用户数据的传输时 延的问题。 根据本发明的一个方面,提供了一种终端的本地交换方法,包括:演进型基站 e B 协同第一终端和第二终端建立本地承载, 其中, 本地承载是指本地交换过程中需要使 用的专用于设备到设备 D2D的承载; eNB通过本地承载转发第一终端和第二终端之间 的业务数据以实现本地交换。 优选地, 演进型基站 eNB协同第一终端和第二终端建立本地承载, 包括: 在分组 数据网关 PGW发起本地承载建立流程后, eNB分别向第一终端和第二终端发起第一 无线资源控制 RRC连接重配流程、第二无线资源控制 RRC连接重配流程;在第一 RRC 连接重配和第二 RRC连接重配均成功的情况下, eNB确定本地承载的建立已经完成, 否则,根据第一终端和 /或第二终端反馈的建立失败消息,重新向第一终端和 /或第二终 端发起 RRC连接重配流程, 直至完成本地承载的建立。 优选地, 分组数据网关 PGW发起本地承载建立流程, 包括: PGW接收到第一终 端发送的本地承载建立请求消息后, 为第一终端生成第一传输流模板 TFT, 并在第一 TFT中增加本地交换的地址类型和第二终端的 IP地址, 其中, 本地承载建立请求消息 包括: 第一终端的 IP地址和第二终端的 IP地址; PGW根据第二终端的 IP地址为第 二终端生成第二 TFT, 并在第二 TFT中增加本地交换的地址类型和第一终端的 IP地 址; PGW生成第一本地承载建立消息, 其中, 第一本地承载建立消息是从 PGW到移 动管理实体 MME的消息, 本地承载建立消息包括: 第一终端的 IP地址、 由第一 TFT 和第二 TFT组成的本地交换 TFT对, 以及服务质量 QoS参数; PGW通过服务网关 SGW将第一本地承载建立消息发送给 MME, 由 MME根据第一本地承载建立消息生 成第二本地承载建立消息, 其中, 第二本地承载建立消息是从 MME到 eNB的消息, 第二本地承载建立消息包括: 第一终端的第一 UE ID、 第二终端的第二 UE ID、 第一 终端的第一 E-RAB ID、 第二终端的第二 E-RAB ID, 以及 QoS参数。 优选地, eNB分别向第一终端和第二终端发起第一无线资源控制 RRC连接重配流 程、 第二无线资源控制 RRC连接重配流程, 包括: eNB 向第一终端发起第一无线资源控制 RRC连接重配流程, 包括: eNB根据第 一 E-RAB ID生成第一终端到 eNB的第一数据无线承载 DRB,并生成对应于第一 DRB 的第一 DRB ID、 第一逻辑信道, 以及第一 LC ID, 其中, 第一 LC ID的保留值用于在 进行本地交换的过程中标识第一逻辑信道; eNB生成对应于第一终端的第一 RRC连接 重配消息, 其中, 第一 RRC连接重配消息包括: 第一 DRB ID、 第一 LC ID以及对应 于第一终端的第一 NAS消息, 第一 NAS消息携带有第一 TFT; eNB向第一终端发送 第一 RRC连接重配消息, 发起第一 RRC连接重配流程; eNB 向第二终端发起第二无线资源控制 RRC连接重配流程, 包括: eNB根据第 二 E-RAB ID生成第二终端到 eNB的第二数据无线承载 DRB,并生成对应于第二 DRB 的第二 DRB ID、 第二逻辑信道, 以及第二 LC ID, 其中, 第二 LC ID的保留值用于在 进行本地交换的过程中标识第二逻辑信道; eNB生成对应于第二终端的第二 RRC连接 重配消息, 其中, 第二 RRC连接重配消息包括: 第二 DRB ID、 第二 LC ID, 以及对 应于第二终端的第二 NAS消息, 第二 NAS消息携带有第二 TFT; eNB向第二终端发 送第二 RRC连接重配消息, 发起第二 RRC连接重配流程; 其中,第一 DRB和第二 DRB存在固定的绑定关系,第一 DRB ID和第二 DRB ID 存在固定的绑定关系, 第一 DRB ID和第二 DRB ID组成 DRB ID对。 优选地, 在 eNB分别向第一终端和第二终端发起第一无线资源控制 RRC连接重 配流程、 第二无线资源控制 RRC连接重配流程之后, 包括: 第一终端将第一 TFT绑 定到第一 DRB, 并执行第一 RRC连接重配的其他操作; 第二终端将第二 TFT绑定到 第二 DRB, 并执行第二 RRC连接重配的其他操作。 优选地, 在第一 RRC连接重配和第二 RRC连接重配均成功的情况下, 包括: 第 一终端向 eNB发送第一 RRC连接重配完成消息; 第二终端向 eNB发送第二 RRC连 接重配完成消息。 优选地,在 eNB接收到第一 RRC连接重配完成消息和第二 RRC连接重配完成消 息的情况下, 包括: eNB向第一终端发送第一 RRC配置结束消息, 向第二终端发送第 二 RRC配置结束消息。 优选地, eNB通过本地承载转发第一终端和第二终端之间的业务数据以实现本地 交换,包括:在接收第一终端发送的调用请求 SR信令后, eNB向第一终端发送 UL grant 信令, 其中, UL grant信令中携带第一终端发送业务数据时使用的上行资源; eNB通 过空口接收来自第一终端的业务数据, 并对业务数据进行 PHY层、 MAC层及 RLC层 的处理, 使业务数据到达 PDCP层; eNB为第二终端分配用于在接收业务数据时使用 的缓存; eNB通过缓存将业务数据发送给第二终端。 优选地, eNB通过缓存将业务数据发送给第二终端, 采用以下方式之一: 方式一, eNB业务数据置于 PDCP层后, 通过缓存将发送给第二终端; 方式二, eNB业务数据置于 PDCP层之上后, 通过缓存将发送给第二终端; 其中, 采用方式一进行数据发送时, 对业务数据进行加密处理, 包括: 当第一终 端到 eNB的第一数据无线承载 DRB的上行数据包计数值达到第一计数阈值时, eNB 向第一终端发送第一 Countercheck消息以使第一终端按照 LTE流程对业务数据进行计 数检查; 当第二终端到 eNB的第二数据无线承载 DRB的下行数据包计数值达到第二 技术阈值时, eNB 向第二终端发送第二 Countercheck消息以使第二终端按照 LTE流 程对业务数据进行计数检查。 优选地, 在演进型基站 eNB协同第一终端和第二终端建立本地承载之前, 该方法 还包括: eNB或分组数据网关 PGW判断是否能够进行本地交换。 优选地, eNB判断是否能够进行本地交换, 包括: 在第一终端进行附着的过程中, eNB接收移动管理实体 MME发送的第一终端的 IP地址, 并保存第一终端的 IP地址; 在第二终端进行附着的过程中, eNB接收 MME发送的第二终端的 IP地址, 并保存第 二终端的 IP地址; 当接收到第一终端发送的携带有第二终端的 IP地址的本地交换请 求消息时, eNB判断本地是否已经保存了第二终端的 IP地址,在判断结果为是的情况 下, 确定第一终端和第二终端能够进行本地交换; 在判断结果为否的情况下, eNB向 相邻 eNB查询相邻 eNB是否已经保存了第二终端的 IP地址, 如果查询结果为是, 确 定第一终端和第二终端能够进行本地交换, 如果查询结果为否, 确定第一终端和第二 终端不能进行本地交换。 优选地, 在确定第一终端和第二终端能够进行本地交换的情况下, 包括: eNB向 第一终端发送本地交换请求响应消息, 其中, 本地交换请求响应消息用于指示第一终 端能够与第二终端进行本地交换, 并启动本地承载的建立流程。 优选地, PGW判断是否能够进行本地交换, 包括: 在第一终端成功和第二终端附 着成功后, PGW建立与第一终端和第二终端之间的 LTE承载; PGW接收第一终端发 送的业务数据, 其中, 业务数据中包括: 第一终端的 IP地址和第二终端的 IP地址; PGW根据第一终端的 IP地址和第二终端的 IP地址, 判断第一终端和第二终端是否均 位于 eNB下且 eNB支持本地交换功能, 或者第一终端和第二终端是否分别位于 eNB 和相邻 eNB下且 eNB和相邻 eNB均支持本地交换功能, 如果判断结果为是, 确定第 一终端和第二终端能够进行本地夂换, 如果判断结果为否, 确定第一终端和第二终端 不能进行本地交换。 根据本发明的另一方面,提供了一种终端的本地交换系统,包括:演进型基站 e B、 第一终端、 第二终端、 分组数据网关 PGW、 服务网关 SGW以及移动管理实体 MME, 其中, eNB包括: 建立模块, 设置为协同第一终端和第二终端建立本地承载, 其中, 本地承载是指本地交换过程中需要使用的专用于设备到设备 D2D的承载; 转发模块, 设置为通过本地承载转发第一终端和第二终端之间的业务数据以实现本地交换。 优选地, 建立模块包括: 发起模块, 设置为在 PGW发起本地承载建立流程后, 分别向第一终端和第二终端发起第一无线资源控制 RRC连接重配流程、第二无线资源 控制 RRC连接重配流程; 处理模块, 设置为在第一 RRC连接重配和第二 RRC连接重 配均成功的情况下, 确定本地承载的建立已经完成, 否则, 根据第一终端和 /或第二终 端反馈的建立失败消息, 重新向第一终端和 /或第二终端发起 RRC连接重配流程, 直 至完成本地承载的建立。 优选地, PGW用于发起本地承载建立流程, PGW包括: 第一接收模块, 设置为 接收第一终端发送的本地承载建立请求消息; 第一生成模块, 设置为为第一终端生成 第一传输流模板 TFT, 并在第一 TFT中增加本地交换的地址类型和第二终端的 IP地 址, 其中, 本地承载建立请求消息包括: 第一终端的 IP地址和第二终端的 IP地址; 第二生成模块, 设置为根据第二终端的 IP地址为第二终端生成第二 TFT, 并在第二 TFT中增加本地交换的地址类型和第一终端的 IP地址; 第三生成模块, 设置为生成第 一本地承载建立消息, 其中, 第一本地承载建立消息是从 PGW到 MME的消息, 本 地承载建立消息包括: 第一终端的 IP地址、 由第一 TFT和第二 TFT组成的本地交换 TFT对, 以及服务质量 QoS参数; 第一发送模块, 设置为通过 SGW将第一本地承载 建立消息发送给 MME以使 MME根据第一本地承载建立消息生成第二本地承载建立 消息, 其中, 第二本地承载建立消息是从 MME到 eNB的消息, 第二本地承载建立消 息包括:第一终端的第一 UE ID、第二终端的第二 UE ID、第一终端的第一 E-RAB ID、 第二终端的第二 E-RAB ID, 以及 QoS参数。 优选地, 发起模块包括: 第一生成单元, 设置为根据第一 E-RAB ID生成第一终 端到 eNB的第一数据无线承载 DRB, 并生成对应于第一 DRB的第一 DRB ID、 第一 逻辑信道, 以及第一 LC ID, 其中, 第一 LC ID的保留值用于在进行本地交换的过程 中标识第一逻辑信道; 第二生成单元,设置为生成对应于第一终端的第一 RRC连接重 配消息, 其中, 第一 RRC连接重配消息包括: 第一 DRB ID、 第一 LC ID以及对应于 第一终端的第一 NAS消息, 第一 NAS消息携带有第一 TFT; 第一发送单元, 设置为 向第一终端发送第一 RRC连接重配消息, 发起第一 RRC连接重配流程; 第三生成单 元, 设置为根据第二 E-RAB ID生成第二终端到 eNB的第二数据无线承载 DRB, 并生 成对应于第二 DRB的第二 DRB ID、 第二逻辑信道, 以及第二 LC ID, 其中, 第二 LC ID的保留值用于在进行本地交换的过程中标识第二逻辑信道; 第四生成单元, 设置为 生成对应于第二终端的第二 RRC连接重配消息,其中,第二 RRC连接重配消息包括: 第二 DRB ID、第二 LC ID, 以及对应于第二终端的第二 NAS消息, 第二 NAS消息携 带有第二 TFT; 第二发送单元, 设置为向第二终端发送第二 RRC连接重配消息, 发起 第二 RRC连接重配流程; 其中, 第一 DRB和第二 DRB存在固定的绑定关系, 第一 DRB ID和第二 DRB ID存在固定的绑定关系,第一 DRB ID和第二 DRB ID组成 DRB ID对。 优选地, 第一终端包括: 第一绑定模块, 设置为在发起模块向第一终端发起第一 RRC连接重配流程之后, 将第一 TFT绑定到第一 DRB, 并执行第一 RRC连接重配的 其他操作;第二终端包括:第二绑定模块,设置为在发起模块向第二终端发起第二 RRC 连接重配流程之后, 将第二 TFT绑定到第二 DRB, 并执行第二 RRC连接重配的其他 操作。 优选地, 第一终端还包括: 第二发送模块, 设置为在第一 RRC连接重配成功的情 况下, 向 e B发送第一 RRC连接重配完成消息; 第二终端还包括: 第三发送模块, 设置为在第二 RRC连接重配成功的情况下,向 eNB发送第二 RRC连接重配完成消息。 优选地, 建立模块还包括: 第四发送模块, 设置为在接收到第一 RRC连接重配完 成消息和第二 RRC连接重配完成消息的情况下, 向第一终端发送第一 RRC配置结束 消息, 向第二终端发送第二 RRC配置结束消息。 优选地, 转发模块包括: 第二接收模块, 设置为接收第一终端发送的调用请求 SR 信令; 第五发送模块, 设置为向第一终端发送 UL grant信令, 其中, UL grant信令中 携带第一终端发送业务数据时使用的上行资源; 第三接收模块, 设置为通过空口接收 来自第一终端的业务数据, 并对业务数据进行 PHY层、 MAC层及 RLC层的处理, 使 业务数据到达 PDCP层; 分配模块, 设置为为第二终端分配用于在接收业务数据时使 用的缓存; 第六发送模块, 设置为通过缓存将业务数据发送给第二终端。 优选地,第六发送模块通过缓存将业务数据发送给第二终端,采用以下方式之一: 方式一,第六发送模块将业务数据置于 PDCP层后,通过缓存将发送给第二终端; 方式二, 第六发送模块将业务数据置于 PDCP层之上后, 通过缓存将发送给第二 终端; 其中, 采用方式一进行数据发送时, 第六发送模块对业务数据进行加密处理, 包 括: 当第一终端到 eNB的第一数据无线承载 DRB的上行数据包计数值达到第一计数 阈值时, 第六发送模块向第一终端发送第一 Countercheck消息以使第一终端按照 LTE 流程对业务数据进行计数检查; 当第二终端到 e B的第二数据无线承载 DRB的下行 数据包计数值达到第二技术阈值时, 第六发送模块向第二终端发送第二 Countercheck 消息以使第二终端按照 LTE流程对业务数据进行计数检查。 优选地, e B还包括: 第一判断模块, 设置为在建立模块建立本地承载之前, 判 断是否能够进行本地交换; 或者, PGW还包括: 第二判断模块, 设置为在建立模块建 立本地承载之前, 判断是否能够进行本地交换。 优选地, 第一判断模块包括: 第一接收单元, 设置为在第一终端进行附着的过程 中, 接收 MME发送的第一终端的 IP地址, 并保存第一终端的 IP地址; 第二接收单 元, 设置为在第二终端进行附着的过程中, 接收 MME发送的第二终端的 IP地址, 并 保存第二终端的 IP地址; 第一判断单元, 设置为当接收到第一终端发送的携带有第二 终端的 IP地址的本地交换请求消息时, 判断本地是否已经保存了第二终端的 IP地址; 第一确定单元, 设置为在判断结果为是的情况下, 确定第一终端和第二终端能够进行 本地交换; 查询单元, 设置为在判断结果为否的情况下, 向相邻 eNB 查询相邻 eNB 是否已经保存了第二终端的 IP地址; 第二确定单元, 设置为当查询结果为是时, 确定 第一终端和第二终端能够进行本地交换, 当查询结果为否时, 确定第一终端和第二终 端不能进行本地交换。 优选地, eNB还包括: 第七发送模块, 设置为在第一判断模块确定第一终端和第 二终端能够进行本地交换的情况下, 向第一终端发送本地交换请求响应消息, 其中, 本地交换请求响应消息用于指示第一终端能够与第二终端进行本地交换, 并启动本地 承载的建立流程。 优选地, 第二判断模块包括: 建立单元, 设置为在第一终端成功和第二终端附着 成功后, 建立与第一终端和第二终端之间的 LTE承载; 第三接收单元, 设置为接收第 一终端发送的业务数据, 其中, 业务数据中包括: 第一终端的 IP地址和第二终端的 IP 地址; 第二判断单元, 设置为根据第一终端的 IP地址和第二终端的 IP地址, 判断第 一终端和第二终端是否均位于 eNB下且 eNB支持本地交换功能, 或者第一终端和第 二终端是否分别位于 eNB和相邻 eNB下且 eNB和相邻 eNB均支持本地交换功能,如 果判断结果为是, 确定第一终端和第二终端能够进行本地夂换, 如果判断结果为否, 确定第一终端和第二终端不能进行本地交换。 通过本发明的上述实施例, 采用当 eNB或 PGW判定第一终端和第二终端能够进 行本地交换时, eNB可以协同同时位于 eNB或其中一个位于相邻 eNB的第一终端和 第二终端建立本地承载, 进而使用本地承载转发第一终端和第二终端之间的业务数据 的方式, 解决了相关技术中通过 LTE技术进行数据转发的方式会增加核心网的网络设 备的负荷、 用户数据的传输时延的问题, 达到了降低核心网的网络设备的负荷、 缩短 数据的传输时延, 提高数据的传输速度的效果。 附图说明 此处所说明的附图用来提供对本发明的进一步理解, 构成本申请的一部分, 本发 明的示意性实施例及其说明用于解释本发明, 并不构成对本发明的不当限定。 在附图 中: 图 1是根据本发明实施例的终端的本地交换方法流程图; 图 2是根据本发明实施例的终端的本地交换系统的结构示意图; 图 3是根据本发明优选实施例的终端的本地交换系统的结构示意图; 图 4是根据本发明优选实施例的本地交换的流程图; 图 5是根据本发明优选实施例的本地承载建立的流程图; 图 6是根据本发明优选实施例的 e B判断是否可以进行本地交换的消息流程图; 图 7是根据本发明优选实施例的 MME到 e B的本地承载建立消息的消息框图; 图 8是根据本发明优选实施例的本地承载建立流程图; 图 9是根据本发明优选实施例的本地交换的 MAC字头的框图; 图 10是根据本发明优选实施例的 RRC连接重配消息流程图; 图 11是根据本发明优选实施例的 RRC连接重配失败消息流程图; 图 12是根据本发明优选实施例的本地交换消息流程图; 图 13是根据本发明优选实施例的本地交换数据处理 (PDCP层转发) 的流程图; 图 14是根据本发明优选实施例的防止非法入侵的 ConterCheck基站消息流程图; 图 15 是根据本发明优选实施例的 PGW判断是否可以进行本地交换的消息流程 图; 以及 图 16是根据本发明优选实施例的本地交换数据处理(PDCP层之上转发) 的流程 图。 具体实施方式 下文中将参考附图并结合实施例来详细说明本发明。 需要说明的是, 在不冲突的 情况下, 本申请中的实施例及实施例中的特征可以相互组合。 本发明实施例主要提供一种终端的本地交换的实现方法, 该方法还可以用于实现 与本发明实施例中的终端具有类似功能的无线设备的本地交换。 通过本发明实施例, 可以解决现有技术在同一基站覆盖范围下 (或相邻基站覆盖范围下) 进行点对点数据 交换时, 需通过 SGW (服务网关) 和 PGW (分组数据网关) 进行转发处理而导致的 增加核心网的网络设备的负荷、 用户数据的传输时延等问题, 进而能够降低核心网的 网络设备的负荷, 缩短数据的传输时延, 提高数据传输的速度。 本发明实施例提供了一种终端的本地交换方法。 图 1是根据本发明实施例的终端 的本地交换方法流程图,如图 1所示,该方法主要包括以下步骤(步骤 S 102-步骤 S104): 步骤 S102, 演进型基站 (e B ) 协同第一终端和第二终端建立本地承载, 其中, 本地承载是指本地交换过程中需要使用的专用于设备到设备 (D2D) 的承载; 步骤 S104, e B通过本地承载转发第一终端和第二终端之间的业务数据以实现本 地交换。 通过上述各个步骤, eNB可以协同同时位于 eNB或其中一个位于相邻 eNB的第 一终端和第二终端建立本地承载, 进而使用本地承载转发第一终端和第二终端之间的 业务数据, 能够降低核心网的网络设备的负荷、 缩短数据的传输时延, 提高数据的传 输速度。 在本实施例中, 步骤 S102可以通过以下方式来实现: 在分组数据网关 PGW发起 本地承载建立流程后, eNB 分别向第一终端和第二终端发起第一无线资源控制 RRC 连接重配流程、 第二无线资源控制 R C连接重配流程; 在第一 R C连接重配和第二 RRC连接重配均成功的情况下, eNB确定本地承载的建立已经完成, 否则, 根据第一 终端和 /或第二终端反馈的建立失败消息, 重新向第一终端和 /或第二终端发起 RRC连 接重配流程, 直至完成本地承载的建立。 在本实施例中, 分组数据网关 PGW发起本地承载建立流程, 可以包括: PGW接 收到第一终端发送的本地承载建立请求消息后,为第一终端生成第一传输流模板 TFT, 并在第一 TFT中增加本地交换的地址类型和第二终端的 IP地址, 其中, 本地承载建 立请求消息包括: 第一终端的 IP地址和第二终端的 IP地址; PGW根据第二终端的 IP 地址为第二终端生成第二 TFT, 并在第二 TFT中增加本地交换的地址类型和第一终端 的 IP地址; PGW生成第一本地承载建立消息,其中,第一本地承载建立消息是从 PGW 到移动管理实体 MME的消息, 本地承载建立消息包括: 第一终端的 IP地址、 由第一 TFT和第二 TFT组成的本地交换 TFT对, 以及服务质量 QoS参数; PGW通过服务网 关 SGW将第一本地承载建立消息发送给 MME, 由 MME根据第一本地承载建立消息 生成第二本地承载建立消息,其中,第二本地承载建立消息是从 MME到 eNB的消息, 第二本地承载建立消息包括: 第一终端的第一 UE ID、 第二终端的第二 UE ID、 第一 终端的第一 E-RAB ID、 第二终端的第二 E-RAB ID, 以及 QoS参数。 在本实施例中, eNB分别向第一终端和第二终端发起第一无线资源控制 RRC连接 重配流程、 第二无线资源控制 RRC连接重配流程, 可以采用以下方式实现: eNB 向第一终端发起第一无线资源控制 RRC连接重配流程, 包括: eNB根据第 一 E-RAB ID生成第一终端到 eNB的第一数据无线承载 DRB,并生成对应于第一 DRB 的第一 DRB ID、 第一逻辑信道, 以及第一 LC ID, 其中, 第一 LC ID的保留值用于在 进行本地交换的过程中标识第一逻辑信道; eNB生成对应于第一终端的第一 RRC连接 重配消息, 其中, 第一 RRC连接重配消息包括: 第一 DRB ID、 第一 LC ID以及对应 于第一终端的第一 NAS消息, 第一 NAS消息携带有第一 TFT; eNB向第一终端发送 第一 RRC连接重配消息, 发起第一 RRC连接重配流程; eNB 向第二终端发起第二无线资源控制 RRC连接重配流程, 包括: eNB根据第 二 E-RAB ID生成第二终端到 eNB的第二数据无线承载 DRB,并生成对应于第二 DRB 的第二 DRB ID、 第二逻辑信道, 以及第二 LC ID, 其中, 第二 LC ID的保留值用于在 进行本地交换的过程中标识第二逻辑信道; eNB生成对应于第二终端的第二 RRC连接 重配消息, 其中, 第二 RRC连接重配消息包括: 第二 DRB ID、 第二 LC ID, 以及对 应于第二终端的第二 NAS消息, 第二 NAS消息携带有第二 TFT; eNB向第二终端发 送第二 RRC连接重配消息, 发起第二 RRC连接重配流程; 其中,第一 DRB和第二 DRB存在固定的绑定关系,第一 DRB ID和第二 DRB ID 存在固定的绑定关系, 第一 DRB ID和第二 DRB ID组成 DRB ID对。 在本实施例中, 在 eNB分别向第一终端和第二终端发起第一无线资源控制 RRC 连接重配流程、第二无线资源控制 RRC连接重配流程之后,第一终端可以将第一 TFT 绑定到第一 DRB, 并执行第一 RRC连接重配的其他操作; 第二终端可以将第二 TFT 绑定到第二 DRB, 并执行第二 RRC连接重配的其他操作。 在本实施例中, 在第一 RRC连接重配和第二 RRC连接重配均成功的情况下, 第 一终端可以向 eNB发送第一 RRC连接重配完成消息; 第二终端可以向 eNB发送第二 RRC连接重配完成消息。 在本实施例中,在 eNB接收到第一 RRC连接重配完成消息和第二 RRC连接重配 完成消息的情况下, eNB可以向第一终端发送第一 RRC配置结束消息, 向第二终端发 送第二 RRC配置结束消息。 在本实施例中,步骤 S104可以通过以下方式来实现:在接收第一终端发送的调用 请求 SR信令后, eNB向第一终端发送 UL grant信令, 其中, UL grant信令中携带第 一终端发送业务数据时使用的上行资源; eNB通过空口接收来自第一终端的业务数据, 并对业务数据进行 PHY层、 MAC层及 RLC层的处理,使业务数据到达 PDCP层; eNB 为第二终端分配用于在接收业务数据时使用的缓存; eNB通过缓存将业务数据发送给 第二终端。 在本实施例中, eNB通过缓存将业务数据发送给第二终端, 采用以下方式之一: 方式一, eNB业务数据置于 PDCP层后, 通过缓存将发送给第二终端; 方式二, eNB业务数据置于 PDCP层之上后, 通过缓存将发送给第二终端; 其中, 采用方式一进行数据发送时, 对业务数据进行加密处理, 包括: 当第一终 端到 eNB的第一数据无线承载 DRB的上行数据包计数值达到第一计数阈值时, eNB 向第一终端发送第一 Countercheck消息以使第一终端按照 LTE流程对业务数据进行计 数检查; 当第二终端到 eNB的第二数据无线承载 DRB的下行数据包计数值达到第二 技术阈值时, eNB 向第二终端发送第二 Countercheck消息以使第二终端按照 LTE流 程对业务数据进行计数检查。 在本实施例中, 在演进型基站 eNB协同第一终端和第二终端建立本地承载之前, 该方法还包括: 由 eNB或分组数据网关 PGW判断是否能够进行本地交换。 在本实施例中, eNB判断是否能够进行本地交换, 可以通过这样的方式实现: 在 第一终端进行附着的过程中, eNB接收移动管理实体 MME发送的第一终端的 IP地址, 并保存第一终端的 IP地址; 在第二终端进行附着的过程中, eNB接收 MME发送的第 二终端的 IP地址, 并保存第二终端的 IP地址; 当接收到第一终端发送的携带有第二 终端的 IP地址的本地交换请求消息时, eNB判断本地是否已经保存了第二终端的 IP 地址, 在判断结果为是的情况下, 确定第一终端和第二终端能够进行本地交换; 在判 断结果为否的情况下, eNB向相邻 eNB查询相邻 eNB是否已经保存了第二终端的 IP 地址, 如果查询结果为是, 确定第一终端和第二终端能够进行本地交换, 如果查询结 果为否, 确定第一终端和第二终端不能进行本地交换。 在本实施例中, 在确定第一终端和第二终端能够进行本地交换的情况下, 包括: eNB向第一终端发送本地交换请求响应消息, 其中, 本地交换请求响应消息用于指示 第一终端能够与第二终端进行本地交换, 并启动本地承载的建立流程。 在本实施例中, PGW判断是否能够建立本地承载, 可以通过这样的方式实现: 在 第一终端成功和第二终端附着成功后, PGW 建立与第一终端和第二终端之间的 LTE 承载; PGW接收第一终端发送的业务数据, 其中, 业务数据中包括: 第一终端的 IP 地址和第二终端的 IP地址; PGW根据第一终端的 IP地址和第二终端的 IP地址, 判 断第一终端和第二终端是否均位于 eNB下且 eNB支持本地交换功能, 或者第一终端 和第二终端是否分别位于 eNB和相邻 eNB下且 eNB和相邻 eNB均支持本地交换功能, 如果判断结果为是,确定第一终端和第二终端能够进行本地交换,如果判断结果为否, 确定第一终端和第二终端不能进行本地交换。 本发明实施例提供了一种终端的本地交换系统, 该系统用以实现上述实施例提供 的终端的本地交换方法。 图 2是根据本发明实施例的终端的本地交换系统的结构示意 图, 如图 2所示, 该系统主要包括: 演进型基站 (e B)、 第一终端、 第二终端、 分组 数据网关 (PGW)、 服务网关 (SGW) 以及移动管理实体 (MME)。 其中, eNB可以包括: 建立模块 12, 设置为协同第一终端和第二终端建立本地承 载, 其中, 本地承载是指本地交换过程中需要使用的专用于设备到设备 D2D的承载; 转发模块 14, 设置为通过本地承载转发第一终端和第二终端之间的业务数据以实现本 地交换。 在本实施例提供的终端的本地交换系统基础上,可以对该系统进行进一步的优化, 以得到一个优选实施例。 以下结合图 3对该优选实施例进行进一步描述。 图 3是根据本发明优选实施例的终端的本地交换系统的结构示意图,如图 3所示, 在该优选实施例提供的终端的本地交换系统中,建立模块 12可以包括:发起模块 122, 设置为在 PGW发起本地承载建立流程后, 分别向第一终端和第二终端发起第一无线 资源控制 RRC连接重配流程、 第二无线资源控制 RRC连接重配流程; 处理模块 124, 设置为在第一 RRC连接重配和第二 RRC连接重配均成功的情况下, 确定本地承载的 建立已经完成, 否则, 根据第一终端和 /或第二终端反馈的建立失败消息, 重新向第一 终端和 /或第二终端发起 RRC连接重配流程, 直至完成本地承载的建立。 在该优选实施例提供的终端的本地交换系统中, PGW 用于发起本地承载建立流 程, PGW包括: 第一接收模块 21, 设置为接收第一终端发送的本地承载建立请求消 息; 第一生成模块 22, 设置为为第一终端生成第一传输流模板 TFT, 并在第一 TFT 中增加本地交换的地址类型和第二终端的 IP地址,其中,本地承载建立请求消息包括: 第一终端的 IP地址和第二终端的 IP地址; 第二生成模块 23, 设置为根据第二终端的 IP地址为第二终端生成第二 TFT,并在第二 TFT中增加本地交换的地址类型和第一终 端的 IP地址; 第三生成模块 24, 设置为生成第一本地承载建立消息, 其中, 第一本 地承载建立消息是从 PGW到 MME的消息, 本地承载建立消息包括: 第一终端的 IP 地址、 由第一 TFT和第二 TFT组成的本地交换 TFT对, 以及服务质量 QoS参数; 第 一发送模块 25, 设置为通过 SGW将第一本地承载建立消息发送给 MME以使 MME 根据第一本地承载建立消息生成第二本地承载建立消息, 其中, 第二本地承载建立消 息是从 MME到 eNB的消息, 第二本地承载建立消息包括: 第一终端的第一 UE ID、 第二终端的第二 UE ID、 第一终端的第一 E-RAB ID、 第二终端的第二 E-RAB ID, 以 及 QoS参数。 在该优选实施例提供的终端的本地交换系统中, 发起模块 122包括: 第一生成单 元 1221, 设置为根据第一 E-RAB ID生成第一终端到 eNB的第一数据无线承载 DRB, 并生成对应于第一 DRB的第一 DRB ID、 第一逻辑信道, 以及第一 LC ID, 其中, 第 一 LC ID 的保留值用于在进行本地交换的过程中标识第一逻辑信道; 第二生成单元 1222, 设置为生成对应于第一终端的第一 RRC连接重配消息, 其中, 第一 RRC连接 重配消息包括: 第一 DRB ID、 第一 LC ID以及对应于第一终端的第一 NAS消息, 第 一 NAS消息携带有第一 TFT; 第一发送单元 1223, 设置为向第一终端发送第一 RRC 连接重配消息, 发起第一 RRC连接重配流程; 第三生成单元 1224, 设置为根据第二 E-RAB ID生成第二终端到 eNB的第二数据无线承载 DRB, 并生成对应于第二 DRB 的第二 DRB ID、 第二逻辑信道, 以及第二 LC ID, 其中, 第二 LC ID的保留值用于在 进行本地交换的过程中标识第二逻辑信道; 第四生成单元 1225, 设置为生成对应于第 二终端的第二 RRC连接重配消息,其中,第二 RRC连接重配消息包括:第二 DRB ID、 第二 LC ID, 以及对应于第二终端的第二 NAS消息, 第二 NAS消息携带有第二 TFT; 第二发送单元 1226, 设置为向第二终端发送第二 RRC连接重配消息, 发起第二 RRC 连接重配流程; 其中, 第一 DRB和第二 DRB存在固定的绑定关系, 第一 DRB ID和 第二 DRB ID存在固定的绑定关系, 第一 DRB ID和第二 DRB ID组成 DRB ID对。 在该优选实施例提供的终端的本地交换系统中,第一终端包括:第一绑定模块 32, 设置为在发起模块 122向第一终端发起第一 RRC连接重配流程之后, 将第一 TFT绑 定到第一 DRB, 并执行第一 RRC连接重配的其他操作; 第二终端包括: 第二绑定模 块 42, 设置为在发起模块 122向第二终端发起第二 RRC连接重配流程之后, 将第二 TFT绑定到第二 DRB, 并执行第二 RRC连接重配的其他操作。 在该优选实施例提供的终端的本地交换系统中, 第一终端还包括: 第二发送模块 34, 设置为在第一 RRC连接重配成功的情况下, 向 e B发送第一 RRC连接重配完成 消息; 第二终端还包括: 第三发送模块 44, 设置为在第二 RRC连接重配成功的情况 下, 向 eNB发送第二 RRC连接重配完成消息。 在该优选实施例提供的终端的本地交换系统中,建立模块 12还包括:第四发送模 块 126, 设置为在接收到第一 RRC连接重配完成消息和第二 RRC连接重配完成消息 的情况下, 向第一终端发送第一 RRC配置结束消息, 向第二终端发送第二 RRC配置 结束消息。 在该优选实施例提供的终端的本地交换系统中,转发模块 14包括:第二接收模块 141 , 设置为接收第一终端发送的调用请求 SR信令; 第五发送模块 142, 设置为向第 一终端发送 UL grant信令, 其中, UL grant信令中携带第一终端发送业务数据时使用 的上行资源; 第三接收模块 143, 设置为通过空口接收来自第一终端的业务数据, 并 对业务数据进行 PHY层、 MAC层及 RLC层的处理, 使业务数据到达 PDCP层; 分配 模块 144, 设置为为第二终端分配用于在接收业务数据时使用的缓存; 第六发送模块 145, 设置为通过缓存将业务数据发送给第二终端。 在该优选实施例提供的终端的本地交换系统中, 第六发送模块 145通过缓存将业 务数据发送给第二终端, 采用以下方式之一: 方式一, 第六发送模块 145将业务数据置于 PDCP层后, 通过缓存将发送给第二 终端; 方式二, 第六发送模块 145将业务数据置于 PDCP层之上后, 通过缓存将发送给 第二终端; 其中,采用方式一进行数据发送时,第六发送模块 145对业务数据进行加密处理, 包括: 当第一终端到 eNB的第一数据无线承载 DRB的上行数据包计数值达到第一计 数阈值时,第六发送模块 145向第一终端发送第一 Countercheck消息以使第一终端按 照 LTE流程对业务数据进行计数检查; 当第二终端到 eNB的第二数据无线承载 DRB 的下行数据包计数值达到第二技术阈值时, 第六发送模块 145 向第二终端发送第二 Countercheck消息以使第二终端按照 LTE流程对业务数据进行计数检查。 在该优选实施例提供的终端的本地交换系统中, e B还包括: 第一判断模块 16, 设置为在建立模块 12建立本地承载之前, 判断是否能够进行本地交换; 或者, PGW 还包括: 第二判断模块 26, 设置为在建立模块 12建立本地承载之前, 判断是否能够 进行本地交换。 在该优选实施例提供的终端的本地交换系统中,第一判断模块 16包括:第一接收 单元 161, 设置为在第一终端进行附着的过程中, 接收 MME发送的第一终端的 IP地 址, 并保存第一终端的 IP地址; 第二接收单元 162, 设置为在第二终端进行附着的过 程中, 接收 MME发送的第二终端的 IP地址, 并保存第二终端的 IP地址; 第一判断 单元 163, 设置为当接收到第一终端发送的携带有第二终端的 IP地址的本地交换请求 消息时, 判断本地是否已经保存了第二终端的 IP地址; 第一确定单元 164, 设置为在 判断结果为是的情况下, 确定第一终端和第二终端能够进行本地交换; 查询单元 165, 设置为在判断结果为否的情况下, 向相邻 eNB查询相邻 eNB是否已经保存了第二终 端的 IP地址; 第二确定单元 166, 设置为当查询结果为是时, 确定第一终端和第二终 端能够进行本地交换, 当查询结果为否时, 确定第一终端和第二终端不能进行本地交 换。 在该优选实施例提供的终端的本地交换系统中, eNB还包括: 第七发送模块 18, 设置为在第一判断模块 16确定第一终端和第二终端能够进行本地交换的情况下,向第 一终端发送本地交换请求响应消息, 其中, 本地交换请求响应消息用于指示第一终端 能够与第二终端进行本地交换, 并启动本地承载的建立流程。 在该优选实施例提供的终端的本地交换系统中,第二判断模块 26包括: 建立单元 262, 设置为在第一终端成功和第二终端附着成功后,建立与第一终端和第二终端之间 的 LTE承载; 第三接收单元 264, 设置为接收第一终端发送的业务数据, 其中, 业务 数据中包括: 第一终端的 IP地址和第二终端的 IP地址; 第二判断单元 266, 设置为根 据第一终端的 IP地址和第二终端的 IP地址,判断第一终端和第二终端是否均位于 eNB 下且 eNB支持本地夂换功能,或者第一终端和第二终端是否分别位于 eNB和相邻 eNB 下且 eNB和相邻 eNB均支持本地交换功能, 如果判断结果为是, 确定第一终端和第 二终端能够进行本地交换, 如果判断结果为否, 确定第一终端和第二终端不能进行本 地交换。 采用上述实施例提供的终端的本地交换方法及系统, 当 e B或 PGW判定第一终 端和第二终端能够进行本地交换时, eNB可以协同同时位于 eNB或其中一个位于相邻 eNB的第一终端和第二终端建立本地承载, 进而使用本地承载转发第一终端和第二终 端之间的业务数据的方式, 进而达到了降低核心网的网络设备的负荷、 缩短数据的传 输时延, 提高数据的传输速度的效果。 下面结合图 4至图 16以及两个优选实施例对上述实施例提供的终端的本地交换方 法的实现过程进行更加详细的描述和说明。 在对以下两个优选实例进行详细描述之前, 先对该两个优选实施例提供的本地交 换流程进行简要介绍。 图 4是根据本发明优选实施例的本地交换的流程图, 如图 4所 示, 该本地交换流程可以分为两个大步骤: 步骤 1, 第一终端和第二终端之间建立本地承载。 步骤 2, eNB通过本地承载完成第一终端和第二终端之间的本地交换流程。 其中, 步骤 1又可以细分如下三个步骤, 图 5是根据本发明优选实施例的本地承 载建立的流程图, 如图 5所示, 该三个步骤包括: 步骤 11 : eNB或 PGW判断可否建立本地承载。 步骤 12: PGW发起本地承载建立的流程。 步骤 13 : eNB完成 RRC连接重配, 完成本地承载的建立。 在该本地交换流程中, 可以由 eNB或 PGW先判断是否可以进行本地交换, 在本 地交换的数据处理上, 可以采用在 PDCP层进行数据交换和在 PDCP层之上进行数据 交换两种方式, 由哪个实体判断是否可以建立本地承载与采用哪种方式进行本地交换 的数据处理并不相关 (即, 采用哪种方式判断可否建立本地承载, 并不会影响本地交 换的数据处理的流程), 甚至它们之间可以相互组合。下面将对以下两个优选实施例进 行详细描述。 优选实施例一 本优选实施例给出了第一终端和第二终端建立本地承载, 并进行本地交换的具体 实施例,在本优选实施例中,是由 eNB判断可否建立本地承载的。在本优选实施例中, 第一终端和第二终端服务于同一个 e B。 在本优选实施例中, 本地交换数据在 PDCP 层进行交换。 步骤一: eNB判断可否建立本地承载。 图 6是根据本发明优选实施例的 eNB判断是否可以进行本地交换的消息流程图, 如图 6所示, eNB判断可否建立承载的具体流程如下: 第一终端进行附着。在附着的过程中, MME通过 initial context setup request消息, 将第一终端的 IP地址传给 e B, eNB收到该消息后, 记录第一终端的 IP地址, 第二 终端进行附着, 在附着的过程中, MME通过 initial context setup request消息, 将第二 终端的 IP地址传给 eNB, eNB收到该消息后, 记录第二终端的 IP地址。 当第一终端有数据要发给第二终端时, 第一终端给 eNB发本地交换请求消息。 该 消息携带第二终端的 IP地址。 eNB从该消息中获得第二终端的 IP地址, 并判断是否 可以进行本地交换, 判断方法如下, eNB判断本 eNB是否记录了第二终端的 IP地址, 如果判断结果是本 eNB记录了第二终端的 IP地址, 则 eNB认为第一终端和第二终端 可以进行本地交换, 如果判断结果是本 eNB没有记录第二终端的 IP地址, 则 eNB将 会给相邻的 eNB通过 X2接口发 IP地址查询消息, 该消息携带第二终端的 IP地址, 相邻的 eNB收到该消息后判断是否记录了第二终端的 IP地址。 如果相邻 eNB支持本 地交换并且记录了第二终端的 IP地址, 则回 IP地址查询响应消息, 表明查询到了该 IP地址, 则 eNB收到该消息后认为第一终端和第二终端可以进行本地交换, 否则相邻 eNB回 IP地址查询响应消息, 表明没有查询到该 IP地址。 则 eNB收到该消息后, 认 为第一终端和第二终端不可以进行本交换。 在本实施例中, 第二终端在附着过程中, eNB记录了第二终端的 IP地址, eNB获得第二终端的 IP地址后, 判断出本 eNB记录 的第二终端的 IP地址, eNB认为第一终端和第二终端可以进行本地交换。 eNB给第一终端回本地交换请求响应消息, 表明第一终端和第二终端可以进行本 地交换。 第一终端收到该消息后给 PGW发本地交换承载建立请求消息, 该消息携带 第一终端 IP地址和第二终端的 IP地址。 步骤二: PGW发起本地承载建立的流程。 PGW收到第一终端的本地交换承载建立请求消息后, PGW生成用于本地交换的 第一终端的 TFT, 首先按照正常的流程, 生成第一终端的 TFT (即上述第一 TFT), 然 后在第一终端的 TFT的包滤波器的包滤波器内容单元中增加了一个新的类型(即本地 交换的地址类型)。 并在本地交换的地址类型后面跟着目标 UE的 IP地址, 即第二终 端的 IP地址, 并且只能包含第二终端的 IP地址。 PGW还生成用于本地交换的第二终端的 TFT (即上述第二 TFT), 首先按照正常 的流程, 生成第二终端的 TFT, 然后在第二终端 TFT的包滤波器的包滤波器内容单元 中增加了一个新的类型(即本地交换的地址类型)。并在本地交换的地址类型后面跟着 目标 UE的 IP地址, 即第一终端的 IP地址, 并且只能包含第一终端的 IP地址。 第一终端的本地交换 TFT和第二终端的本地交换 TFT组成 TFT对。 LTE (Long Term Evolution) technology does not currently support local switching. Under the same base station coverage or adjacent base station coverage, point-to-point data exchange needs to pass through SGW (Serving Gateway) and P PGW (Packet Data). Forward processing of Network Gateway, Packet Data Gateway. This data exchange method increases the load on the SGW and the PGW gateway and the transmission network. In addition, due to the long path of the data transmission, the data needs to undergo complicated processing at the base station, and the delay of the user data transmission is large, and the transmission speed is affected. The method of data forwarding by the LTE technology in the related art increases the load of the network equipment of the core network and the transmission delay of the user data. Currently, no effective solution has been proposed. SUMMARY OF THE INVENTION The embodiments of the present invention provide a local switching method and system for a terminal, so as to solve at least the problem that the data forwarding by the LTE technology in the related art increases the load of the network device of the core network and the transmission delay of the user data. .  According to an aspect of the present invention, a method for local switching of a terminal is provided, including: the evolved base station e B cooperates with the first terminal and the second terminal to establish a local bearer, where the local bearer refers to a dedicated need to be used in the local exchange process. The bearer of the device to the device D2D; the eNB forwards the service data between the first terminal and the second terminal through the local bearer to implement local exchange. Preferably, the evolved base station eNB cooperates with the first terminal and the second terminal to establish a local bearer, including: after the packet data gateway PGW initiates a local bearer setup procedure, the eNB initiates a first radio resource control RRC to the first terminal and the second terminal respectively. The connection reconfiguration process, the second radio resource control RRC connection reconfiguration procedure; in the case that both the first RRC connection reconfiguration and the second RRC connection reconfiguration are successful, the eNB determines that the establishment of the local bearer has been completed, otherwise, according to the first The establishment failure message fed back by the terminal and/or the second terminal re-initiates the RRC connection reconfiguration process to the first terminal and/or the second terminal until the establishment of the local bearer is completed. Preferably, the packet data gateway PGW initiates a local bearer setup procedure, including: after receiving the local bearer setup request message sent by the first terminal, the PGW generates a first transport stream template TFT for the first terminal, and adds a local to the first TFT. The exchanged address type and the IP address of the second terminal, where the local bearer setup request message includes: an IP address of the first terminal and an IP address of the second terminal; and the PGW generates a second second terminal according to the IP address of the second terminal a TFT, and adding a locally exchanged address type and an IP address of the first terminal in the second TFT; the PGW generates a first local bearer setup message, where the first local bearer setup message is a message from the PGW to the mobility management entity MME, The local bearer setup message includes: an IP address of the first terminal, a local switching TFT pair composed of the first TFT and the second TFT, and a quality of service QoS parameter; the PGW sends a first local bearer setup message to the MME through the serving gateway SGW, Generating, by the MME, a second local bearer setup message according to the first local bearer setup message, where The local bearer setup message is a message from the MME to the eNB, and the second local bearer setup message includes: a first UE ID of the first terminal, a second UE ID of the second terminal, a first E-RAB ID of the first terminal, and a first The second E-RAB ID of the second terminal, and the QoS parameters. Preferably, the eNB initiates a first radio resource control RRC connection reconfiguration procedure and a second radio resource control RRC connection reconfiguration procedure to the first terminal and the second terminal, respectively, including: the eNB initiating the first radio resource control RRC to the first terminal The connection reconfiguration process includes: the eNB generates a first data radio bearer DRB of the first terminal to the eNB according to the first E-RAB ID, and generates a first DRB ID, a first logical channel, and the first corresponding to the first DRB. An LC ID, where the reserved value of the first LC ID is used to identify the first logical channel in the process of performing local switching; the eNB generates a first RRC connection reconfiguration message corresponding to the first terminal, where the first RRC connection is heavy The configuration message includes: a first DRB ID, a first LC ID, and a first NAS message corresponding to the first terminal, where the first NAS message carries the first TFT; the eNB sends a first RRC connection reconfiguration message to the first terminal, and initiates The first RRC connection reconfiguration process;  And the eNB sends a second radio resource control RRC connection reconfiguration procedure to the second terminal, where: the eNB generates a second data radio bearer DRB of the second terminal to the eNB according to the second E-RAB ID, and generates a second DRB corresponding to the second DRB. a second DRB ID, a second logical channel, and a second LC ID, where the reserved value of the second LC ID is used to identify the second logical channel in the process of performing local switching; the eNB generates a second RRC corresponding to the second terminal And the second RRC connection reconfiguration message includes: a second DRB ID, a second LC ID, and a second NAS message corresponding to the second terminal, where the second NAS message carries the second TFT; The second terminal sends a second RRC connection reconfiguration message, and initiates a second RRC connection reconfiguration process. The first DRB and the second DRB have a fixed binding relationship, and the first DRB ID and the second DRB ID are fixedly bound. The relationship, the first DRB ID and the second DRB ID form a DRB ID pair. Preferably, after the eNB initiates the first radio resource control RRC connection reconfiguration process and the second radio resource control RRC connection reconfiguration process to the first terminal and the second terminal, the method includes: the first terminal binding the first TFT to the first terminal The first DRB, and performing other operations of the first RRC connection reconfiguration; the second terminal binding the second TFT to the second DRB, and performing other operations of the second RRC connection reconfiguration. Preferably, if both the first RRC connection reconfiguration and the second RRC connection reconfiguration are successful, the method includes: the first terminal sends a first RRC connection reconfiguration complete message to the eNB; and the second terminal sends the second RRC connection to the eNB. Rematch complete message. Preferably, when the eNB receives the first RRC connection reconfiguration complete message and the second RRC connection reconfiguration complete message, the method includes: the eNB sends a first RRC configuration end message to the first terminal, and sends a second message to the second terminal. RRC configuration end message. Preferably, the eNB forwards the service data between the first terminal and the second terminal by using the local bearer to implement the local exchange, including: after receiving the call request SR signaling sent by the first terminal, the eNB sends the UL grant message to the first terminal. The UL grant signaling carries the uplink resource used when the first terminal sends the service data; the eNB receives the service data from the first terminal through the air interface, and processes the service data by the PHY layer, the MAC layer, and the RLC layer, The service data is sent to the PDCP layer; the eNB allocates a buffer for using the second terminal to receive the service data; and the eNB sends the service data to the second terminal by using the cache. Preferably, the eNB sends the service data to the second terminal by using the buffer, in one of the following manners: In the first mode, after the eNB service data is placed in the PDCP layer, the eNB is sent to the second terminal by using the buffer; After being above the PDCP layer, it will be sent to the second terminal through the cache;  The method of performing encryption on the service data when the data is sent by using the mode 1 includes: when the uplink data packet count value of the first data radio bearer DRB of the first terminal to the eNB reaches a first counting threshold, the eNB sends the first terminal to the first terminal. Sending a first Countercheck message to enable the first terminal to check the service data according to the LTE process; when the downlink data packet count value of the second data radio bearer DRB of the second terminal to the eNB reaches the second technical threshold, the eNB goes to the second The terminal sends a second Countercheck message to enable the second terminal to perform a check check on the service data according to the LTE process. Preferably, before the evolved base station eNB cooperates with the first terminal and the second terminal to establish a local bearer, the method further includes: the eNB or the packet data gateway PGW determining whether local switching is possible. Preferably, the eNB determines whether the local exchange is possible, the method includes: in the process of attaching by the first terminal, the eNB receives the IP address of the first terminal sent by the mobility management entity MME, and saves the IP address of the first terminal; During the process of attaching the terminal, the eNB receives the IP address of the second terminal sent by the MME, and saves the IP address of the second terminal; when receiving the local exchange request message that is sent by the first terminal and carries the IP address of the second terminal, The eNB determines whether the IP address of the second terminal has been saved locally. If the determination result is yes, it is determined that the first terminal and the second terminal can perform local exchange; if the determination result is negative, the eNB approaches the neighbor. The eNB queries whether the neighboring eNB has saved the IP address of the second terminal. If the query result is yes, it is determined that the first terminal and the second terminal can perform local exchange. If the query result is no, the first terminal and the second terminal cannot be determined. Perform local exchange. Preferably, in the case that it is determined that the first terminal and the second terminal can perform local exchange, the method includes: the eNB sends a local exchange request response message to the first terminal, where the local exchange request response message is used to indicate that the first terminal can The two terminals perform local exchange and initiate the establishment process of the local bearer. Preferably, the PGW determines whether the local terminal can be exchanged, the method includes: after the first terminal succeeds and the second terminal successfully attaches, the PGW establishes an LTE bearer between the first terminal and the second terminal; and the PGW receives the service sent by the first terminal. Data, where the service data includes: an IP address of the first terminal and an IP address of the second terminal; and the PGW determines, according to the IP address of the first terminal and the IP address of the second terminal, whether the first terminal and the second terminal are located. The eNB and the eNB support the local switching function, or whether the first terminal and the second terminal are respectively located under the eNB and the neighboring eNB, and the eNB and the neighboring eNB support the local switching function. If the determination result is yes, the first terminal and the first terminal are determined. The second terminal can perform local exchange. If the judgment result is no, it is determined that the first terminal and the second terminal cannot perform local exchange. According to another aspect of the present invention, a local switching system of a terminal is provided, including: an evolved base station e B, a first terminal, a second terminal, a packet data gateway PGW, a serving gateway SGW, and a mobility management entity MME, where The eNB includes: an establishing module, configured to establish a local bearer in cooperation with the first terminal and the second terminal, where The local bearer refers to a bearer dedicated to the device to the device D2D that needs to be used in the local switching process. The forwarding module is configured to forward the service data between the first terminal and the second terminal through the local bearer to implement local exchange. Preferably, the establishing module includes: an initiating module, configured to: after the PGW initiates the local bearer setup process, initiate a first radio resource control RRC connection reconfiguration process to the first terminal and the second terminal, and the second radio resource control RRC connection weight a processing module, configured to determine that the establishment of the local bearer has been completed if the first RRC connection reconfiguration and the second RRC connection reconfiguration are successful, otherwise, according to the feedback of the first terminal and/or the second terminal A failure message is established, and the RRC connection reconfiguration process is re-initiated to the first terminal and/or the second terminal until the establishment of the local bearer is completed. Preferably, the PGW is configured to initiate a local bearer setup process, and the PGW includes: a first receiving module, configured to receive a local bearer setup request message sent by the first terminal; and a first generating module, configured to generate a first transport stream for the first terminal a template TFT, and adding a locally exchanged address type and an IP address of the second terminal in the first TFT, where the local bearer setup request message includes: an IP address of the first terminal and an IP address of the second terminal; And generating, according to the IP address of the second terminal, a second TFT for the second terminal, and adding a locally exchanged address type and an IP address of the first terminal in the second TFT; and a third generation module, configured to generate the first local a bearer setup message, where the first local bearer setup message is a message from the PGW to the MME, and the local bearer setup message includes: an IP address of the first terminal, a local exchange TFT pair composed of the first TFT and the second TFT, and a service a quality QoS parameter; the first sending module, configured to send, by using an SGW, a first local bearer setup message to the MME The MME generates a second local bearer setup message according to the first local bearer setup message, where the second local bearer setup message is a message from the MME to the eNB, and the second local bearer setup message includes: the first UE ID of the first terminal, a second UE ID of the second terminal, a first E-RAB ID of the first terminal, a second E-RAB ID of the second terminal, and a QoS parameter. Preferably, the initiating module includes: a first generating unit, configured to generate a first data radio bearer DRB of the first terminal to the eNB according to the first E-RAB ID, and generate a first DRB ID corresponding to the first DRB, first a logical channel, and a first LC ID, where the reserved value of the first LC ID is used to identify the first logical channel in a process of performing local switching; and the second generating unit is configured to generate a first RRC corresponding to the first terminal a first RRC connection reconfiguration message, where the first RRC connection reconfiguration message includes: a first DRB ID, a first LC ID, and a first NAS message corresponding to the first terminal, where the first NAS message carries the first TFT; a unit, configured to send a first RRC connection reconfiguration message to the first terminal, to initiate a first RRC connection reconfiguration process, and a third generating unit, configured to generate second data from the second terminal to the eNB according to the second E-RAB ID Radio bearer DRB, and generates a second DRB ID corresponding to the second DRB, a second logical channel, and a second LC ID, where the reserved value of the second LC ID is used in the process of performing local exchange Identifying the second logical channel; and a fourth generating unit arranged to generate a corresponding second terminal of the second RRC connection reconfiguration message, wherein the second RRC connection reconfiguration message comprises: a second DRB ID, a second LC ID, and a second NAS message corresponding to the second terminal, where the second NAS message carries the second TFT; the second sending unit is configured to send the second RRC connection reconfiguration to the second terminal a message, initiating a second RRC connection reconfiguration process, where the first DRB and the second DRB have a fixed binding relationship, the first DRB ID and the second DRB ID have a fixed binding relationship, and the first DRB ID and the second The DRB ID constitutes a DRB ID pair. Preferably, the first terminal includes: a first binding module, configured to bind the first TFT to the first DRB and perform the first RRC connection after the initiating module initiates the first RRC connection reconfiguration process to the first terminal The second terminal includes: a second binding module, configured to bind the second TFT to the second DRB after the initiating module initiates the second RRC connection reconfiguration process to the second terminal, and perform the Two other operations of RRC connection reconfiguration. Preferably, the first terminal further includes: a second sending module, configured to: when the first RRC connection reconfiguration succeeds, send a first RRC connection reconfiguration complete message to the e B; the second terminal further includes: the third sending And a module, configured to send a second RRC connection reconfiguration complete message to the eNB if the second RRC connection reconfiguration succeeds. Preferably, the establishing module further includes: a fourth sending module, configured to send the first RRC configuration end message to the first terminal, when the first RRC connection reconfiguration complete message and the second RRC connection reconfiguration complete message are received Sending a second RRC configuration end message to the second terminal. Preferably, the forwarding module includes: a second receiving module, configured to receive the call request SR signaling sent by the first terminal; and a fifth sending module, configured to send the UL grant signaling to the first terminal, where the UL grant signaling is Carrying the uplink resource used when the first terminal sends the service data; the third receiving module is configured to receive the service data from the first terminal by using the air interface, and perform processing on the PHY layer, the MAC layer, and the RLC layer of the service data to enable the service data Arriving at the PDCP layer; an allocation module, configured to allocate a buffer for use in receiving the service data to the second terminal; and a sixth sending module, configured to send the service data to the second terminal by using the cache. Preferably, the sixth sending module sends the service data to the second terminal by using a buffer, in one of the following manners: mode 1, the sixth sending module sends the service data to the PDCP layer, and then sends the data to the second terminal by using the buffer; After the service module is placed on the PDCP layer, the sixth sending module sends the data to the second terminal by using the cache. The data is sent by the sixth sending module to encrypt the service data, including: When the uplink data packet count value of the first data radio bearer DRB of the first terminal to the eNB reaches the first counting threshold, the sixth sending module sends a first Countercheck message to the first terminal to make the first terminal according to the LTE. The process performs a check on the service data. When the downlink data packet count value of the second data radio bearer DRB of the second terminal to the eB reaches the second technical threshold, the sixth sending module sends a second Countercheck message to the second terminal. The second terminal performs counting check on the service data according to the LTE process. Preferably, the e B further includes: a first determining module, configured to determine whether the local exchange can be performed before the establishing module establishes the local bearer; or the PGW further includes: a second determining module, configured to: before the establishing module establishes the local bearer , to determine whether local exchange is possible. Preferably, the first determining module includes: a first receiving unit, configured to receive an IP address of the first terminal sent by the MME and save the IP address of the first terminal in the process of attaching the first terminal; In the process of attaching the second terminal, receiving the IP address of the second terminal sent by the MME, and saving the IP address of the second terminal; the first determining unit is configured to receive when the first terminal sends the When the local exchange request message of the IP address of the second terminal is used, it is determined whether the IP address of the second terminal has been saved locally; the first determining unit is configured to determine the first terminal and the second terminal if the determination result is yes The local exchange can be performed; the query unit is configured to, if the judgment result is negative, query the neighboring eNB whether the neighboring eNB has saved the IP address of the second terminal; the second determining unit is set to be when the query result is Determining that the first terminal and the second terminal can perform local exchange, and when the query result is no, determining the first terminal and the first Terminal can be locally switched. Preferably, the eNB further includes: a seventh sending module, configured to send a local exchange request response message to the first terminal, where the first determining module determines that the first terminal and the second terminal can perform local exchange, where the local exchange The request response message is used to indicate that the first terminal can perform local exchange with the second terminal, and initiates a setup process of the local bearer. Preferably, the second determining module includes: an establishing unit, configured to: after the first terminal succeeds and the second terminal successfully attaches, establish an LTE bearer between the first terminal and the second terminal; and the third receiving unit is configured to receive The service data sent by the first terminal, where the service data includes: an IP address of the first terminal and an IP address of the second terminal; and a second determining unit, configured to be based on the IP address of the first terminal and the IP address of the second terminal Determining whether the first terminal and the second terminal are both located under the eNB and the eNB supports the local switching function, or whether the first terminal and the second terminal are respectively located under the eNB and the neighboring eNB, and the eNB and the neighboring eNB support the local switching function, If the determination result is yes, it is determined that the first terminal and the second terminal can perform local exchange, and if the determination result is no, it is determined that the first terminal and the second terminal cannot perform local exchange. With the foregoing embodiment of the present invention, when the eNB or the PGW determines that the first terminal and the second terminal are capable of local switching, the eNB may establish a local device in cooperation with the first terminal and the second terminal of the eNB or one of the neighboring eNBs. Carrying, and then forwarding the service data between the first terminal and the second terminal by using the local bearer The method solves the problem that the data forwarding by the LTE technology in the related art increases the load of the network equipment of the core network and the transmission delay of the user data, thereby reducing the load of the network equipment of the core network and shortening the data transmission. Delay, the effect of increasing the speed of data transmission. BRIEF DESCRIPTION OF THE DRAWINGS The accompanying drawings, which are set to illustrate,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, 1 is a flow chart of a local switching method of a terminal according to an embodiment of the present invention; FIG. 2 is a schematic structural diagram of a local switching system of a terminal according to an embodiment of the present invention; FIG. 3 is a schematic diagram of a local switching system of a terminal according to an embodiment of the present invention; FIG. 4 is a flow chart of a local exchange according to a preferred embodiment of the present invention; FIG. 5 is a flow chart of local bearer establishment according to a preferred embodiment of the present invention; FIG. 6 is a preferred embodiment of the present invention. The e B of the example determines whether a message flow chart of the local exchange can be performed; FIG. 7 is a message block diagram of the local bearer setup message of the MME to the e B according to a preferred embodiment of the present invention; FIG. 8 is a local bearer according to a preferred embodiment of the present invention. Figure 9 is a block diagram of a locally switched MAC header in accordance with a preferred embodiment of the present invention; Figure 10 is a flowchart of an RRC Connection Reconfiguration message in accordance with a preferred embodiment of the present invention; Figure 11 is a preferred embodiment in accordance with the present invention. RRC Connection Reconfiguration Failure Message Flowchart; Figure 12 is a flow diagram of a local exchange message in accordance with a preferred embodiment of the present invention; 3 is a flow chart of local exchange data processing (PDCP layer forwarding) according to a preferred embodiment of the present invention; FIG. 14 is a flow chart of a ConterCheck base station message for preventing illegal intrusion according to a preferred embodiment of the present invention; FIG. 15 is a preferred embodiment of the present invention. The PGW of the example determines whether a message flow chart of local exchange is possible;  Figure 16 is a flow diagram of local exchange data processing (for forwarding over the PDCP layer) in accordance with a preferred embodiment of the present invention. BEST MODE FOR CARRYING OUT THE INVENTION Hereinafter, the present invention will be described in detail with reference to the accompanying drawings. It should be noted that the embodiments in the present application and the features in the embodiments may be combined with each other without conflict. The embodiment of the present invention mainly provides a method for implementing local exchange of a terminal, and the method can also be used to implement local exchange of a wireless device having similar functions to the terminal in the embodiment of the present invention. According to the embodiment of the present invention, when the point-to-point data exchange is performed under the coverage of the same base station (or the coverage of the neighboring base station), the SGW (Serving Gateway) and the PGW (Packet Data Gateway) need to perform forwarding processing. The problem of increasing the load of the network equipment of the core network and the transmission delay of the user data may reduce the load of the network equipment of the core network, shorten the transmission delay of the data, and increase the speed of data transmission. The embodiment of the invention provides a local exchange method of a terminal. 1 is a flowchart of a local switching method of a terminal according to an embodiment of the present invention. As shown in FIG. 1, the method mainly includes the following steps (step S102 to step S104): Step S102, an evolved base station (e B ) cooperates with A terminal and a second terminal establish a local bearer, where the local bearer refers to a device-to-device (D2D)-specific bearer that needs to be used in the local switching process; and in step S104, the e B forwards the first terminal and the second terminal by using the local bearer. Business data between to achieve local exchange. Through the foregoing steps, the eNB can establish a local bearer in cooperation with the first terminal and the second terminal located in the eNB or one of the neighboring eNBs, and then use the local bearer to forward the service data between the first terminal and the second terminal, which can be reduced. The load of the network equipment of the core network, shortening the transmission delay of data, and increasing the data transmission speed. In this embodiment, step S102 may be implemented in the following manner: After the packet data gateway PGW initiates a local bearer setup process, the eNB initiates a first radio resource control RRC connection reconfiguration process to the first terminal and the second terminal, respectively. The second radio resource control RC connection reconfiguration process; in the case that both the first RC connection reconfiguration and the second RRC connection reconfiguration are successful, the eNB determines that the establishment of the local bearer has been completed, otherwise, according to the first terminal and/or the second The establishment failure message sent by the terminal re-initiates the RRC connection reconfiguration process to the first terminal and/or the second terminal until the establishment of the local bearer is completed. In this embodiment, the packet data gateway PGW initiates a local bearer setup process, which may include: after receiving the local bearer setup request message sent by the first terminal, the PGW generates a first transport stream template TFT for the first terminal, And adding the locally exchanged address type and the IP address of the second terminal to the first TFT, where the local bearer setup request message includes: an IP address of the first terminal and an IP address of the second terminal; and the PGW is configured according to the IP address of the second terminal. The second terminal generates a second TFT, and adds a locally exchanged address type and an IP address of the first terminal in the second TFT. The PGW generates a first local bearer setup message, where the first local bearer setup message is from the PGW. The message to the mobility management entity MME, the local bearer setup message includes: an IP address of the first terminal, a local switching TFT pair composed of the first TFT and the second TFT, and a quality of service QoS parameter; the PGW will first through the serving gateway SGW The local bearer setup message is sent to the MME, and the MME generates a second local bearer setup message according to the first local bearer setup message, where the second local bearer setup message is a message from the MME to the eNB, and the second local bearer setup message includes: a first UE ID of a terminal, a second UE ID of the second terminal, a first E-RAB ID of the first terminal, and a second terminal A second E-RAB ID, and QoS parameters. In this embodiment, the eNB initiates a first radio resource control RRC connection reconfiguration process and a second radio resource control RRC connection reconfiguration process to the first terminal and the second terminal, which may be implemented in the following manner: Initiating the first radio resource control RRC connection reconfiguration procedure, the method includes: the eNB generates a first data radio bearer DRB of the first terminal to the eNB according to the first E-RAB ID, and generates a first DRB ID corresponding to the first DRB, a logical channel, and a first LC ID, where the reserved value of the first LC ID is used to identify the first logical channel in the process of performing local switching; the eNB generates a first RRC connection reconfiguration message corresponding to the first terminal, The first RRC connection reconfiguration message includes: a first DRB ID, a first LC ID, and a first NAS message corresponding to the first terminal, where the first NAS message carries the first TFT; the eNB sends the first to the first terminal The RRC connection reconfiguration message initiates a first RRC connection reconfiguration procedure; the eNB initiates a second radio resource control RRC connection reconfiguration procedure to the second terminal, including: the eNB according to the second E-RAB ID Generating, by the second terminal, the second data radio bearer to the eNB, and generating a second DRB ID, a second logical channel, and a second LC ID corresponding to the second DRB, where the reserved value of the second LC ID is used in Identifying a second logical channel in the process of performing the local exchange; the eNB generates a second RRC connection reconfiguration message corresponding to the second terminal, where the second RRC connection reconfiguration message includes: a second DRB ID, a second LC ID, and Corresponding to the second NAS message of the second terminal, the second NAS message carries the second TFT; the eNB sends a second RRC connection reconfiguration message to the second terminal, and initiates a second RRC connection reconfiguration process; where the first DRB and The second DRB has a fixed binding relationship. The first DRB ID and the second DRB ID have a fixed binding relationship. The first DRB ID and the second DRB ID form a DRB ID pair. In this embodiment, after the eNB initiates the first radio resource control RRC connection reconfiguration process and the second radio resource control RRC connection reconfiguration process to the first terminal and the second terminal, the first terminal may use the first TFT. Binding to the first DRB, and performing other operations of the first RRC connection reconfiguration; the second terminal may bind the second TFT to the second DRB and perform other operations of the second RRC connection reconfiguration. In this embodiment, when both the first RRC connection reconfiguration and the second RRC connection reconfiguration are successful, the first terminal may send a first RRC connection reconfiguration complete message to the eNB; the second terminal may send the first eNB to the eNB. The second RRC connection reconfiguration complete message. In this embodiment, when the eNB receives the first RRC connection reconfiguration complete message and the second RRC connection reconfiguration complete message, the eNB may send a first RRC configuration end message to the first terminal, and send the message to the second terminal. The second RRC configuration end message. In this embodiment, the step S104 may be implemented by: after receiving the call request SR signaling sent by the first terminal, the eNB sends the UL grant signaling to the first terminal, where the UL grant signaling carries the first The uplink resource used by the terminal to send the service data; the eNB receives the service data from the first terminal through the air interface, and processes the service data by the PHY layer, the MAC layer, and the RLC layer, so that the service data reaches the PDCP layer; the eNB is the second terminal. Allocating a buffer for use in receiving service data; the eNB transmits the service data to the second terminal through the cache. In this embodiment, the eNB sends the service data to the second terminal by using the buffer, in one of the following manners: In the first mode, after the eNB service data is placed in the PDCP layer, the eNB sends the data to the second terminal through the buffer. After the data is placed on the PDCP layer, the data is sent to the second terminal by using the buffer. The data is sent to the eNB by the first method. When the uplink packet count value reaches the first counting threshold, the eNB sends a first Countercheck message to the first terminal to enable the first terminal to check the service data according to the LTE process; when the second terminal sends the second data radio bearer to the eNB. When the downlink packet count value of the DRB reaches the second technical threshold, the eNB sends a second Countercheck message to the second terminal, so that the second terminal performs the check check on the service data according to the LTE process. In this embodiment, before the evolved base station eNB cooperates with the first terminal and the second terminal to establish a local bearer, the method further includes: determining, by the eNB or the packet data gateway PGW, whether local exchange is possible. In this embodiment, the eNB determines whether the local exchange can be performed, and may be implemented in the following manner: In the process of attaching by the first terminal, the eNB receives the IP address of the first terminal sent by the mobility management entity MME, and saves the first The IP address of the terminal; in the process of attaching the second terminal, the eNB receives the IP address of the second terminal sent by the MME, and saves the IP address of the second terminal; When the local exchange request message of the IP address of the terminal is used, the eNB determines whether the IP address of the second terminal has been saved locally. If the determination result is yes, it is determined that the first terminal and the second terminal can perform local exchange; If not, the eNB queries the neighboring eNB whether the neighboring eNB has saved the IP address of the second terminal. If the query result is yes, it is determined that the first terminal and the second terminal can perform local exchange, if the query result is no. , determining that the first terminal and the second terminal cannot perform local exchange. In this embodiment, in the case that it is determined that the first terminal and the second terminal can perform local exchange, the method includes: the eNB sends a local exchange request response message to the first terminal, where the local exchange request response message is used to indicate the first terminal. The local terminal can be exchanged with the second terminal, and the establishment process of the local bearer is started. In this embodiment, the PGW determines whether the local bearer can be established, and can be implemented in the following manner: After the first terminal succeeds and the second terminal successfully attaches, the PGW establishes an LTE bearer between the first terminal and the second terminal; The PGW receives the service data sent by the first terminal, where the service data includes: an IP address of the first terminal and an IP address of the second terminal; and the PGW determines the first according to the IP address of the first terminal and the IP address of the second terminal. Whether the terminal and the second terminal are both located under the eNB and the eNB supports the local switching function, or whether the first terminal and the second terminal are respectively located under the eNB and the neighboring eNB, and the eNB and the neighboring eNB support the local switching function, if the judgment result is Yes, it is determined that the first terminal and the second terminal can perform local exchange. If the determination result is no, it is determined that the first terminal and the second terminal cannot perform local exchange. The embodiment of the present invention provides a local switching system for a terminal, which is used to implement the local switching method of the terminal provided by the foregoing embodiment. 2 is a schematic structural diagram of a local switching system of a terminal according to an embodiment of the present invention. As shown in FIG. 2, the system mainly includes: an evolved base station (e B), a first terminal, a second terminal, and a packet data gateway (PGW). ), the Serving Gateway (SGW) and the Mobility Management Entity (MME). The eNB may include: an establishing module 12, configured to establish a local bearer in cooperation with the first terminal and the second terminal, where the local bearer refers to a bearer dedicated to the device to the device D2D that needs to be used in the local switching process; and the forwarding module 14 It is configured to forward the service data between the first terminal and the second terminal by using the local bearer to implement local exchange. Based on the local switching system of the terminal provided in this embodiment, the system can be further optimized to obtain a preferred embodiment. This preferred embodiment is further described below in conjunction with FIG. 3 is a schematic structural diagram of a local switching system of a terminal according to a preferred embodiment of the present invention. As shown in FIG. 3, in the local switching system of the terminal provided by the preferred embodiment, the establishing module 12 may include: an initiating module 122, which is configured. After the local bearer establishment process is initiated on the PGW, the first radio resource control RRC connection reconfiguration process and the second radio resource control RRC connection reconfiguration process are respectively initiated to the first terminal and the second terminal; and the processing module 124 is set to be in the first When both the RRC connection reconfiguration and the second RRC connection reconfiguration are successful, determining the local bearer The establishment has been completed. Otherwise, according to the establishment failure message fed back by the first terminal and/or the second terminal, the RRC connection reconfiguration process is re-initiated to the first terminal and/or the second terminal until the establishment of the local bearer is completed. In the local switching system of the terminal provided by the preferred embodiment, the PGW is configured to initiate a local bearer setup process, and the PGW includes: a first receiving module 21, configured to receive a local bearer setup request message sent by the first terminal; 22, the first transport stream template TFT is configured to be generated for the first terminal, and the locally exchanged address type and the IP address of the second terminal are added to the first TFT, where the local bearer setup request message includes: the IP of the first terminal The address and the IP address of the second terminal; the second generating module 23 is configured to generate a second TFT for the second terminal according to the IP address of the second terminal, and add the locally exchanged address type and the first terminal in the second TFT The third generation module 24 is configured to generate a first local bearer setup message, where the first local bearer setup message is a message from the PGW to the MME, and the local bearer setup message includes: an IP address of the first terminal, a local switching TFT pair composed of a TFT and a second TFT, and a quality of service QoS parameter; a first transmitting module 25, Sending, by the SGW, a first local bearer setup message to the MME, to enable the MME to generate a second local bearer setup message according to the first local bearer setup message, where the second local bearer setup message is a message from the MME to the eNB, the second local The bearer setup message includes: a first UE ID of the first terminal, a second UE ID of the second terminal, a first E-RAB ID of the first terminal, a second E-RAB ID of the second terminal, and a QoS parameter. In the local switching system of the terminal provided by the preferred embodiment, the initiating module 122 includes: a first generating unit 1221, configured to generate a first data radio bearer DRB of the first terminal to the eNB according to the first E-RAB ID, and generate Corresponding to the first DRB ID of the first DRB, the first logical channel, and the first LC ID, where the reserved value of the first LC ID is used to identify the first logical channel in the process of performing local switching; 1222. The first RRC connection reconfiguration message is configured to generate a first RRC connection reconfiguration message, where the first RRC connection reconfiguration message includes: a first DRB ID, a first LC ID, and a first NAS message corresponding to the first terminal. The first NAS message carries the first TFT. The first sending unit 1223 is configured to send a first RRC connection reconfiguration message to the first terminal, and initiate a first RRC connection reconfiguration process. The third generating unit 1224 is configured to Generating, by the second E-RAB ID, a second data radio bearer DRB of the second terminal to the eNB, and generating a second DRB ID, a second logical channel, and a second LC I corresponding to the second DRB D, wherein the reserved value of the second LC ID is used to identify the second logical channel in the process of performing local exchange; the fourth generating unit 1225 is configured to generate a second RRC connection reconfiguration message corresponding to the second terminal, where The second RRC connection reconfiguration message includes: a second DRB ID, a second LC ID, and a second NAS message corresponding to the second terminal, where the second NAS message carries the second TFT; the second sending unit 1226 is configured to Sending a second RRC connection reconfiguration message to the second terminal, and initiating a second RRC connection reconfiguration process, where the first DRB and the second DRB have a fixed binding relationship, and the first DRB ID and the second DRB ID are fixed. Binding relationship, the first DRB ID and the second DRB ID form a DRB ID pair.  In the local switching system of the terminal provided by the preferred embodiment, the first terminal includes: a first binding module 32, configured to: after the initiating module 122 initiates a first RRC connection reconfiguration process to the first terminal, Binding to the first DRB, and performing other operations of the first RRC connection reconfiguration; the second terminal includes: a second binding module 42, configured to: after the initiating module 122 initiates the second RRC connection reconfiguration procedure to the second terminal Binding the second TFT to the second DRB, and performing other operations of the second RRC connection reconfiguration. In the local switching system of the terminal provided by the preferred embodiment, the first terminal further includes: a second sending module 34, configured to send the first RRC connection reconfiguration to the e B if the first RRC connection reconfiguration succeeds The second terminal further includes: a third sending module 44, configured to send a second RRC connection reconfiguration complete message to the eNB if the second RRC connection reconfiguration succeeds. In the local switching system of the terminal provided by the preferred embodiment, the establishing module 12 further includes: a fourth sending module 126, configured to receive the first RRC connection reconfiguration complete message and the second RRC connection reconfiguration complete message And sending a first RRC configuration end message to the first terminal, and sending a second RRC configuration end message to the second terminal. In the local switching system of the terminal provided by the preferred embodiment, the forwarding module 14 includes: a second receiving module 141, configured to receive the call request SR signaling sent by the first terminal; and a fifth sending module 142, configured to be the first The terminal sends the UL grant signaling, where the UL grant signaling carries the uplink resource used by the first terminal to send the service data. The third receiving module 143 is configured to receive the service data from the first terminal through the air interface, and the service data is received. Perform processing on the PHY layer, the MAC layer, and the RLC layer to enable service data to reach the PDCP layer;44And being configured to allocate, to the second terminal, a buffer used for receiving the service data; and the sixth sending module 145 is configured to send the service data to the second terminal by using the cache. In the local switching system of the terminal provided by the preferred embodiment, the sixth sending module 145 sends the service data to the second terminal by using the cache, in one of the following manners: In the first mode, the sixth sending module 145 places the service data in the PDCP. After the layer is sent to the second terminal by using the buffer, the second sending module 145 sends the service data to the second terminal by using the buffer, and then sends the data to the second terminal by using the buffer. The sixth sending module 145 performs the encryption processing on the service data, including: when the uplink data packet count value of the first data radio bearer DRB of the first terminal to the eNB reaches the first counting threshold, the sixth sending module 145 sends the first sending module 145 to the first terminal. a first Countercheck message to enable the first terminal to check the service data according to the LTE process; when the second terminal to the eNB's second data radio bearer DRB When the downlink packet count value reaches the second technical threshold, the sixth sending module 145 sends a second Countercheck message to the second terminal, so that the second terminal performs the check check on the service data according to the LTE process. In the local switching system of the terminal provided by the preferred embodiment, the e B further includes: a first judging module 16, configured to determine whether the local exchange can be performed before the establishing module 12 establishes the local bearer; or the PGW further includes: The second determining module 26 is configured to determine whether local switching is possible before the establishing module 12 establishes a local bearer. In the local switching system of the terminal provided by the preferred embodiment, the first determining module 16 includes: a first receiving unit 161, configured to receive an IP address of the first terminal sent by the MME in the process of attaching the first terminal, And storing the IP address of the first terminal; the second receiving unit 162 is configured to receive the IP address of the second terminal sent by the MME and save the IP address of the second terminal in the process of attaching the second terminal; The unit 163 is configured to: when receiving the local exchange request message that is sent by the first terminal and carrying the IP address of the second terminal, determine whether the IP address of the second terminal has been saved locally; the first determining unit 164 is configured to be If the determination result is yes, it is determined that the first terminal and the second terminal can perform local exchange; the query unit 165 is configured to, if the determination result is negative, query the neighboring eNB whether the neighboring eNB has saved the second The IP address of the terminal; the second determining unit 166 is configured to: when the query result is yes, determine that the first terminal and the second terminal can Perform local exchange. When the query result is no, it is determined that the first terminal and the second terminal cannot perform local exchange. In the local switching system of the terminal provided by the preferred embodiment, the eNB further includes: a seventh sending module 18, configured to: when the first determining module 16 determines that the first terminal and the second terminal are capable of local switching, A terminal sends a local exchange request response message, where the local exchange request response message is used to indicate that the first terminal can perform local exchange with the second terminal, and initiates a local bearer establishment process. In the local switching system of the terminal provided by the preferred embodiment, the second determining module 26 includes: an establishing unit 262, configured to establish the first terminal and the second terminal after the first terminal succeeds and the second terminal successfully attaches The third receiving unit 264 is configured to receive the service data sent by the first terminal, where the service data includes: an IP address of the first terminal and an IP address of the second terminal; and a second determining unit 266, setting In order to determine whether the first terminal and the second terminal are both located under the eNB according to the IP address of the first terminal and the IP address of the second terminal, and whether the eNB supports the local switching function, or whether the first terminal and the second terminal are respectively located in the eNB and The neighboring eNB and the eNB and the neighboring eNB support the local switching function. If the determination result is yes, it is determined that the first terminal and the second terminal can perform local switching. If the determination result is no, the first terminal and the second terminal cannot be determined. Perform local exchange.  With the local switching method and system of the terminal provided by the foregoing embodiment, when the e B or the PGW determines that the first terminal and the second terminal can perform local exchange, the eNB can cooperate with the eNB or one of the first terminals located in the neighboring eNB. Establishing a local bearer with the second terminal, and then using the local bearer to forward the service data between the first terminal and the second terminal, thereby reducing the load on the network device of the core network, shortening the data transmission delay, and improving the data. The effect of the transmission speed. The implementation process of the local switching method of the terminal provided by the foregoing embodiment is described and illustrated in more detail below with reference to FIG. 4 to FIG. 16 and two preferred embodiments. Before describing the following two preferred examples in detail, the local exchange process provided by the two preferred embodiments will be briefly introduced. 4 is a flow chart of a local exchange according to a preferred embodiment of the present invention. As shown in FIG. 4, the local exchange process can be divided into two major steps: Step 1. A local bearer is established between the first terminal and the second terminal. Step 2: The eNB completes a local exchange process between the first terminal and the second terminal by using a local bearer. Step 1 may further subdivide the following three steps. FIG. 5 is a flowchart of local bearer establishment according to a preferred embodiment of the present invention. As shown in FIG. 5, the three steps include: Step 11: The eNB or the PGW determines whether it is OK. Establish a local bearer. Step 12: The PGW initiates a process of establishing a local bearer. Step 13: The eNB completes the RRC connection reconfiguration and completes the establishment of the local bearer. In the local exchange process, the eNB or the PGW can first determine whether the local exchange can be performed. In the data processing of the local exchange, data exchange at the PDCP layer and data exchange on the PDCP layer can be adopted. Which entity determines whether the local bearer can be established and the data processing used for local exchange is not related (that is, which method is used to determine whether the local bearer can be established, and does not affect the process of data processing of the local exchange), even Can be combined with each other. The following two preferred embodiments will be described in detail below. The preferred embodiment of the present invention provides a specific embodiment in which the first terminal and the second terminal establish a local bearer and perform local exchange. In the preferred embodiment, the eNB determines whether the local bearer can be established. In the preferred embodiment, the first terminal and the second terminal serve the same e B. In the preferred embodiment, the locally exchanged data is exchanged at the PDCP layer.  Step 1: The eNB determines whether a local bearer can be established. FIG. 6 is a message flow diagram of an eNB determining whether a local exchange can be performed according to a preferred embodiment of the present invention. As shown in FIG. 6, the specific process of the eNB determining whether a bearer can be established is as follows: The first terminal performs attaching. In the process of attaching, the MME transmits the IP address of the first terminal to the e B through the initial context setup request message, and after receiving the message, the eNB records the IP address of the first terminal, and the second terminal attaches, and is attached. In the process, the MME transmits the IP address of the second terminal to the eNB through the initial context setup request message, and after receiving the message, the eNB records the IP address of the second terminal. When the first terminal has data to send to the second terminal, the first terminal sends a local exchange request message to the eNB. The message carries the IP address of the second terminal. The eNB obtains the IP address of the second terminal from the message, and determines whether the local terminal can be exchanged. The determining method is as follows: The eNB determines whether the eNB records the IP address of the second terminal, and if the judgment result is that the eNB records the second terminal. The eNB considers that the first terminal and the second terminal can perform local exchange. If the eNB determines that the eNB does not record the IP address of the second terminal, the eNB sends an IP address query to the neighboring eNB through the X2 interface. The message carries the IP address of the second terminal, and the neighboring eNB determines whether the IP address of the second terminal is recorded after receiving the message. If the neighboring eNB supports the local exchange and records the IP address of the second terminal, and then returns an IP address query response message, indicating that the IP address is queried, the eNB considers that the first terminal and the second terminal can perform localization after receiving the message. Exchange, otherwise the neighboring eNB returns an IP address query response message, indicating that the IP address is not queried. After receiving the message, the eNB considers that the first terminal and the second terminal cannot perform the exchange. In this embodiment, during the attaching process, the eNB records the IP address of the second terminal, and after obtaining the IP address of the second terminal, the eNB determines the IP address of the second terminal recorded by the local eNB, and the eNB considers that A terminal and a second terminal can perform local exchange. The eNB returns a local exchange request response message to the first terminal, indicating that the first terminal and the second terminal can perform local exchange. After receiving the message, the first terminal sends a local exchange bearer setup request message to the PGW, where the message carries the IP address of the first terminal and the IP address of the second terminal. Step 2: The PGW initiates a process of establishing a local bearer. After receiving the local exchange bearer setup request message of the first terminal, the PGW generates a TFT of the first terminal for local exchange, and first generates a TFT of the first terminal (that is, the first TFT) according to a normal process, and then A new type (ie, a locally exchanged address type) is added to the packet filter content unit of the packet filter of the TFT of the first terminal. The address type exchanged locally is followed by the IP address of the target UE, that is, the IP address of the second terminal, and can only contain the IP address of the second terminal.  The PGW also generates a TFT for the second terminal for local exchange (ie, the second TFT described above), first generates a TFT of the second terminal according to a normal flow, and then performs a packet filter content unit of the packet filter of the second terminal TFT. A new type has been added (that is, the address type of the local exchange). The address type exchanged locally is followed by the IP address of the target UE, that is, the IP address of the first terminal, and can only contain the IP address of the first terminal. The local switching TFT of the first terminal and the local switching TFT of the second terminal form a TFT pair.
PGW 生成本地承载建立消息, 该消息除了包含正常的承载建立消息包含的参数 夕卜。 还包括本地交换 TFT对和第二终端的 IP地址。 The PGW generates a local bearer setup message, which contains the parameters contained in the normal bearer setup message. It also includes the local exchange TFT pair and the IP address of the second terminal.
PGW生成 PGW到 MME的本地承载建立消息, 该消息经过 SGW, 发给 MME。 MME根据第二终端的 IP地址判断出第二终端, 根据第二终端的上下文信息, 得到第 二终端的 MME UE SIAP ID值和 eNB UE SIAP ID值, 和第二终端的 UE Aggregate Maximum Bit Rate的值。 MME根据该消息生成第一终端的 E-RAB ID (即上述第一 E-RAB ID) 和第二终端的 E-RAB ID (即上述第二 E-RAB ID)。 MME还生成 NAS消 息, 并将其打包进 NAS PDU和 NAS PDU2参数中, 在 NAS PDU参数中包含到第一 终端 NAS消息, 其中包含第一终端对应的本地交换 TFT, 在 NAS PDU2参数中包含 到第二终端 NAS 消息, 其中包含第二终端对应的本地交换 TFT。 之后, MME生成 MME到 eNB的本地承载建立消息。 图 7是根据本发明优选实施例的 MME到 eNB的 本地承载建立消息的消息框图,如图 7所示,该消息包括如下参数: MME UE S1AP ID, eNB UE SIAP ID, UE Aggregate Maximum Bit Rate, E-RAB ID, NAS-PDU, E-RAB Level QoS Parameters, MME UE S1AP ID2, eNB UE S1AP ID2, UE Aggregate Maximum Bit Rate2, E-RAB ID2, NAS-PDU2其中 MME UE SIAP ID, eNB UE SIAP ID, UE Aggregate Maximum Bit Rate, E-RAB ID是第一终端相关的参数, MME UE SIAP ID2, eNB UE S1AP ID2, UE Aggregate Maximum Bit Rate2, E-RAB ID2, NAS-PDU2是第 二终端相关的参数。 Qos参数由 PGW通过本地承载建立消息传给 MME, 是针对第一 终端到第二终端的本地承载的 (只有一个)。 图 8是根据本发明优选实施例的本地承载建立流程图, 如图 8所示, PGW生成到The PGW generates a local bearer setup message from the PGW to the MME, and the message is sent to the MME through the SGW. The MME determines, according to the IP address of the second terminal, the second terminal, and obtains the MME UE SIAP ID value and the eNB UE SIAP ID value of the second terminal according to the context information of the second terminal, and the UE Aggregate Maximum Bit Rate of the second terminal. value. The MME generates an E-RAB ID of the first terminal (ie, the first E-RAB ID) and an E-RAB ID of the second terminal (ie, the second E-RAB ID) according to the message. The MME also generates a NAS message and packs it into the NAS PDU and the NAS PDU2 parameters, and includes the first terminal NAS message in the NAS PDU parameter, which includes the local switching TFT corresponding to the first terminal, and is included in the NAS PDU2 parameter. The second terminal NAS message includes a local switching TFT corresponding to the second terminal. Thereafter, the MME generates a local bearer setup message from the MME to the eNB. 7 is a message block diagram of a local bearer setup message of an MME to an eNB according to a preferred embodiment of the present invention. As shown in FIG. 7, the message includes the following parameters: MME UE S1AP ID, eNB UE SIAP ID, UE Aggregate Maximum Bit Rate, E-RAB ID, NAS-PDU, E-RAB Level QoS Parameters, MME UE S1AP ID2, eNB UE S1AP ID2, UE Aggregate Maximum Bit Rate2, E-RAB ID2, NAS-PDU2 where MME UE SIAP ID, eNB UE SIAP ID , UE Aggregate Maximum Bit Rate, E-RAB ID is a parameter related to the first terminal, MME UE SIAP ID2, eNB UE S1AP ID2, UE Aggregate Maximum Bit Rate2, E-RAB ID2, NAS-PDU2 is a second terminal related parameter . The Qos parameter is transmitted by the PGW to the MME through the local bearer setup message, which is local to the first terminal to the second terminal (only one). FIG. 8 is a flow chart of establishing a local bearer according to a preferred embodiment of the present invention. As shown in FIG. 8, the PGW is generated to
MME的本地承载建立消息,该消息包括 TFT对,第二终端的 IP地址,和 Qos等参数。 该消息经过 SGW, 发给 MME。 MME收到该消息后, 生成 MME到 eNB的本地承载 建立消息, 该消息包括第一终端和第二终端的 UE ID, 第一终端和第二终端的 E-RAB ID和 Qos等参数。 MME发送该消息到 e B。 步骤三: eNB完成 RRC连接重配, 完成本地承载的建立。 eNB收到 MME发的本地承载建立消息后,根据该消息的 E-RAB ID对,生成 DRB 对并生成其对应的 DRB ID对和 LCID对。 eNB根据该消息中与第一终端对应的 E-RAB ID参数生成第一终端到 eNB的数据无线承载(DRB), 并生成数据无线承载标识 DRB ID。 eNB根据该消息中与第二终端对应的 E-RAB ID2参数生成第二终端到 eNB的数 据无线承载 (DRB), 并生成数据无线承载标识 DRB ID2, 两个 DRB有固定的绑定关 系,同样 DRB ID和 DRB ID2也有固定的绑定关系, DRB ID和 DRB ID2组成 DRB ID 对。 eNB生成第一终端到 eNB的 DRB对应的逻辑信道, 并生成 LCID, eNB生成第 二终端到 eNB的 DRB对应的逻辑信道, 并生成 LCID2。 eNB在生成 DRB ID和 DRB ID2时, 可以突破目前协议规定的无线承载标识个数的限制。 同样 eNB在生成 LCID 和 LCID2时, 也可以突破目前协议规定的逻辑信道标识的个数限制。 图 9是根据本发 明优选实施例的本地交换的 MAC字头的框图, 如图 9所示, eNB在生成 MAC子头 时, 可以使用原来的 R位即保留位, 表明其为本地交换的 Mac子头格式, 可以将 R 位改为 T位, 即类型 (type) 位, 可以用 1表明是本地交换的 MAC子头, 用 0表明 为正常的 MAC头,。 并且在进行本地交换时, 可以用 LCID的保留值来标识本地交换 的逻辑信道, 以到达对 LCID 个数的扩展。 eNB 在 RRC 连接重配消息中的 RadioResourceConfigDedicated字段中增加 LSdrb-ToAddModList字段, 该字段包含本 地交换使用的 DRB ID。 eNB在生成本地交换的 DRB对和逻辑信道并生成 DRB ID对和 LCID之后,再分 别生成 eNB到第一终端的 RRC连接重配消息, 和 eNB到第二终端的 RRC连接重配 消息。 eNB到第一终端的 RRC连接重配消息包含 eNB到第一终端的 DRB对应的 DRB ID和 LCID等参数, eNB从 MME到 eNB的承载建立消息的 NAS PDU参数中获得其 包含的 NAS消息, 并通过 RRC连接重配消息捎带该 NAS消息, 该 NAS消息中包含 第一终端所对应的本地交换的 TFT。 eNB到第二终端的 RRC连接重配消息包含第二 终端到 eNB的 DRB对应的 DRB ID2和 LCID2等参数, eNB从 MME到 eNB的承载 建立消息的 NAS PDU参数中获得其包含的 NAS消息, 并通过连接重配消息捎带该 NAS消息, 该 NAS消息中包含第二终端所对应的本地交换 TFT。 eNB生成 RRC连接重配消息后,发起 RRC连接重配。图 10是根据本发明优选实 施例的 RRC连接重配消息流程图, 如图 10所示, eNB向第一终端发送 eNB到第一终 端的 RRC连接重配消息, 向第二终端发送 eNB到第二终端的 RRC连接重配消息。第 一终端在 RRC 收到连接重配消息后, 将生成第一终端到 eNB 的本地交换 DRB, 该 DRB将用 DRB ID标识, 并将进行本地交换 TFT到本地交换 DRB的绑定, 将第一终 端的本地交换 TFT绑定到第一终端到 eNB的本地交换 DRB上。 并完成 RRC连接重 配的其他操作。在完成 RRC连接重配后,第一终端给 eNB回 RRC连接重配完成消息。 第二终端在收到 RRC连接重配消息后, 将进行 TFT的绑定, 将生成第二终端到 eNB 的本地交换 DRB,该 DRB用 DRB ID2标识,并将进行本地交换 TFT到本地交换 DRB 的绑定, 将第二终端的本地交换 TFT绑定到第二终端到 eNB的本地交换 DRB上。 并 完成 RRC连接重配的其他操作。 在完成 RRC连接重配后, 第一终端给 eNB回 RRC 连接重配完成消息。 eNB在收到第一终端的 RRC连接重配完成消息和第二终端的 RRC 连接重配完成消息之后。分别给第一终端和第二终端发送 RRC配置结束消息。第一终 端收到 RRC配置结束消息之后, 开始和第二终端进行本地数据交换,第二终端在收到 RRC配置结束消息之后, 开始和第一终端进行本地数据交换。 以上是 RRC连接重配, 配置成功的正常流程, 如果 RRC连接重配配置失败, 则 进入 RRC连接重配异常流程。图 11是根据本发明优选实施例的 RRC连接重配失败消 息流程图, 如图 11所示, 当 eNB给第一终端发 RRC连接重配消息后, 如果第一终端 在进行 RRC连接重配时, 重配失败, 为了不让本地交换承载建立的失败影响其他的应 用,在本地交换的 RRC连接重配异常流程中增加了 RRCConnectionConfigurationFailure 消息, 该消息表明本地交换的 RRC连接配置失败。第一终端发送该消息给 e B, 第一 终端可以在该消息中携带 RRCConnectionConfigurationFigurationCause单元,该单元表 明失败的原因。 eNB可以根据失败原因重新为本地交换通信分配 RRC连接重配的相关 参数, 并重新发送 RRCConnectionReconfiguration 消息, 如果配置成功, 第一终端回 RRCConnectionReconfigurationComplete消息, eNB将进行下面的流程, 在收到第一终 端和第二终端的 RRCConnectionReconfigurationComplete 消息之后发送承载建立响应 给 MME, 表明本地承载建立成功, 如果没有配置成功, 第一终端将第二次回 RRCConnectionConfigurationFailure消息, 则 eNB要发送承载建立响应给 MME, 在该 消息的 E-RAB Failed to Setup List单元中, 表明为是由于和第一终端的 RRC连接重配 失败导致的本地承载建立失败。 如果第二终端的 RRC 连接重配成功, 在本优选实施 施例所示, eNB还要给第二终端发送 RRC连接重配恢复消息,将第二终端恢复到连接 重配之前的状态。 步骤四, 本地交换流程。 在建立好本地交换承载后,将进行本地数据交换。图 12是根据本发明优选实施例 的本地交换消息流程图, 如图 12所示, 当第一终端有数据要发送时, 第一终端发送调 度请求信令, 即 SR信令, eNB收到 SR信令后, 发送 UL grant信令, 该信令包含为 第一终端分配的进行上行发送的资源, 但该 UL grant分配的上行资源非常有限。 在本 实施例中, 第一终端在收到 UL grant信令后, 会在 eNB为其分配的上行资源上发送 BSR消息, 该消息携带了第一终端要发送的数据的 buffer (即缓存) 的大小。 eNB收 到该消息后, 将获得第一终端要发送数据的 buffer大小。 eNB将检查进行本地交换所 使用的转发 buffer所剩空间的大小, 如果转发 buffer的剩余空间大于第一终端要发送 数据的 buffers 则 eNB为第一终端分配上行资源, 并发送 UL grant信令。 第一终端收 到上行信令后, 在 eNB分配的上行资源上发送业务数据。 第一终端和第二终端进行本地交换的数据流程。图 13是根据本发明优选实施例的 本地交换数据处理 (PDCP层转发) 的流程图, 如图 13所示, 在本优选实施例中, 是 第一终端向第二终端发送业务数据, 经过本地交换 TFT映射到第一终端的本地交换的 DRB中, 在经过 PDCP层, RLC层, MAC层, PHY层的处理后, 通过空口发送出去。 之后 eNB接收到第一终端发送的数据, 该数据经过 PHY层, MAC层, RLC层的处理 后到达 PDCP层,有两种数据转发方法:一种是在 PDCP层转发,还有一种是在 PDCP 层之上转发。在本优选实施例中, 本地交换的数据在 PDCP层转发。数据经过 RLC层 之后, 已经在 eNB的本地交换的 DRB ID所对应的 DRB之中, eNB从该 DRB中读取 数据, 并将其写入转发 buffer 中, 并记录从该 DRB 中读取的包数, 将其记录为 countMSB-Uplink。 eNB为第二终端分配下行资源, 并从转发 buffer中读取数据, 并将 数据写入 eNB的本地交换 DRB ID2所对应的 DRB中。 并记录写入该 DRB的包数, 将其记录为 countMSB-Downlink。 数据被写入 eNB的 DRB ID2所对应的 DRB后, 经 过 RLC层, MAC层, PHY层的处理, 被发送给第二终端, 第二终端接收到该数据后, 数据经过 PHY层, MAC层, RLC层和 PDCP层的处理后, 数据被写入第二终端本地 交换 DRB ID2所对应的 DRB中, 经过第二终端本地交换 TFT的映射, 数据到达业务 层。 在 PDCP层转发, 数据的加解密处理, 在第一终端和第二终端之间进行。 但为了 防止第一终端到 eNB之间的数据不受 intruder的攻击。 eNB和第一终端之间采用了本 地交换的 countercheck 机制, 同理 eNB 和第二终端之间也采用了本地交换的 countercheck机制。 图 14是根据本发明优选实施例的防止非法入侵的 ConterCheck基 站消息流程图, 如图 14所示, 当 eNB的 DRB ID所对应的 DRB的 countMSB-Uplink 的值到达某一个特殊的值, eNB 就会向第一终端发送 Countercheck消息, 该消息的 drb-CountMSB-InfoList字段将包含 countMSB-Uplink的值。 第一终端按照正常的 LTE 流程进行 Countercheck检查。 并回 CounterCheckResponse消息。 当 eNB的 DRB ID2 所对应的 DRB的 countMSB-Downlink的值到达某一个特殊的值, eNB就会向第二终 端发送 Countercheck 消息, 该消息的 drb-CountMSB-InfoList 字段将包含 countMSB-Uplink的值。 第二终端按照正常的 LTE流程进行 CountCheck检查。 并回 CounterCheckResponse消息。只有 eNB和第一终端以及 eNB和第二终端这两段链路都 正确时, 才认为第一终端到第二终端之间的本地交换链路通过了 Countercheck检查。 优选实施例二 本优选实施例给出了第一终端和第二终端建立本地承载并进行本地交换的具体实 施例, 在本优选实施例中, 是由 PGW判断可否建立本地承载的。 在本优选实施例中, 第一终端和第二终端由同一个 eNB服务, 也属于同一个 PGW的管理下。 在本优选实 施例中, 本地交换数据在 PDCP层之上进行交换。 步骤一: PGW判断可否建立本地承载。 图 15 是根据本发明优选实施例的 PGW判断是否可以进行本地交换的消息流程 图, 如图 15所示, PGW判断可否建立承载的具体流程如下: 第一终端进行附着。 第二终端进行附着, 当第一终端有到第二终端的数据要发送 时, 先请求 PGW建立正常的承载, 正常的 LTE的承载建立后向第一终端通过该承载 向第二终端发送数据。 第一终端发给第二终端的数据包将经过 PGW,PGW从第一终端发送的数据包中, 获取该数据包的目的地址。 在本实施例中, 第一终端数据包的目的地址为第二终端的 IP地址。 PGW根据第二终端的 IP地址可以得出第一终端发送的数据包的目的地为第 二终端。 PGW判断第一终端和第二终端是否在同一个 eNB下, 如果第一终端和第二 终端在同一个 eNB下, 且该 eNB支持本地交换功能, 则 PGW认为第一终端和第二终 端可以进行本地交换, 如果第一终端和第二终端不在同一个 eNB下, 则判断第一终端 和第二终端是否处于相邻的 eNB下, 且相邻的两个 eNB均支持本地交换功能, 如果 符合该条件, 则第一终端和第二终端可以进行本地交换。 如果不满足以上两个条件, 则第一终端和第二终端不能进行本地交换。 在本实施例中, 第一终端和第二终端服务 于同一个 e B, 故可以进行本地交换, PGW将发起本地承载建立流程。 步骤二: PGW发起本地承载建立的流程。 The local bearer setup message of the MME includes the TFT pair, the IP address of the second terminal, and parameters such as Qos. The message is sent to the MME via the SGW. After receiving the message, the MME generates a local bearer setup message of the MME to the eNB, where the message includes the UE ID of the first terminal and the second terminal, and the E-RAB ID and Qos parameters of the first terminal and the second terminal. The MME sends the message to e B. Step 3: The eNB completes the RRC connection reconfiguration and completes the establishment of the local bearer. After receiving the local bearer setup message sent by the MME, the eNB generates a DRB pair and generates a corresponding DRB ID pair and an LCID pair according to the E-RAB ID pair of the message. The eNB generates a data radio bearer (DRB) of the first terminal to the eNB according to the E-RAB ID parameter corresponding to the first terminal in the message, and generates a data radio bearer identifier DRB ID. The eNB generates a data radio bearer (DRB) of the second terminal to the eNB according to the E-RAB ID2 parameter corresponding to the second terminal in the message, and generates a data radio bearer identifier DRB ID2, where the two DRBs have a fixed binding relationship, and the same The DRB ID and DRB ID2 also have a fixed binding relationship. The DRB ID and DRB ID2 form a DRB ID pair. The eNB generates a logical channel corresponding to the DRB of the first terminal to the eNB, and generates an LCID, and the eNB generates a logical channel corresponding to the DRB of the second terminal to the eNB, and generates an LCID2. When the eNB generates the DRB ID and the DRB ID2, the eNB can break the limitation of the number of radio bearer identifiers specified by the current protocol. Similarly, when generating the LCID and LCID2, the eNB can also break the limit of the number of logical channel identifiers specified by the current protocol. 9 is a block diagram of a locally exchanged MAC header according to a preferred embodiment of the present invention. As shown in FIG. 9, when generating a MAC subheader, the eNB may use the original R bit, that is, a reserved bit, to indicate that it is a locally switched Mac. Sub-header format, you can change the R bit to the T bit, that is, the type bit. You can use 1 to indicate the MAC sub-header of the local exchange, and 0 to indicate the normal MAC header. And when performing local exchange, the reserved value of the LCID can be used to identify the logical channel of the local exchange to reach the extension of the number of LCIDs. The eNB adds an LSdrb-ToAddModList field in the RadioResourceConfigDedicated field in the RRC Connection Reconfiguration message, which field contains the DRB ID used by the local exchange. After generating the locally exchanged DRB pair and the logical channel and generating the DRB ID pair and the LCID, the eNB separately generates an RRC connection reconfiguration message from the eNB to the first terminal and an RRC connection reconfiguration message from the eNB to the second terminal. The RRC connection reconfiguration message of the eNB to the first terminal includes parameters such as a DRB ID and an LCID corresponding to the DRB of the eNB to the first terminal, and the eNB obtains the NAS message included in the NAS PDU parameter of the bearer setup message of the MME to the eNB, and The NAS message is carried by the RRC connection reconfiguration message, and the NAS message includes the locally exchanged TFT corresponding to the first terminal. The RRC connection reconfiguration message of the eNB to the second terminal includes parameters such as DRB ID2 and LCID2 corresponding to the DRB of the second terminal to the eNB, and the eNB obtains the NAS message included in the NAS PDU parameter of the bearer setup message from the MME to the eNB, and The NAS message is carried by the connection reconfiguration message, where the NAS message includes a local switching TFT corresponding to the second terminal. After the eNB generates an RRC connection reconfiguration message, the RRC connection reconfiguration is initiated. FIG. 10 is a flowchart of an RRC connection reconfiguration message according to a preferred embodiment of the present invention. As shown in FIG. 10, the eNB sends an RRC connection reconfiguration message from the eNB to the first terminal to the first terminal, and sends the eNB to the second terminal. The RRC connection reconfiguration message of the second terminal. After receiving the connection reconfiguration message, the first terminal will generate a local exchange DRB of the first terminal to the eNB, and the DRB will be identified by the DRB ID, and the local switching TFT will be bound to the local exchange DRB, and the first terminal will be first. The local switching TFT of the terminal is bound to the local exchange DRB of the first terminal to the eNB. And complete other operations of RRC connection reconfiguration. After completing the RRC connection reconfiguration, the first terminal returns an RRC connection reconfiguration complete message to the eNB. After receiving the RRC connection reconfiguration message, the second terminal performs TFT bonding, and generates a local switching DRB of the second terminal to the eNB, where the DRB is identified by DRB ID2, and the local switching TFT is switched to the local switching DRB. Binding, binding the local switching TFT of the second terminal to the second terminal to the local exchange DRB of the eNB. And complete other operations of RRC connection reconfiguration. After completing the RRC connection reconfiguration, the first terminal returns an RRC connection reconfiguration complete message to the eNB. After receiving the RRC connection reconfiguration complete message of the first terminal and the RRC connection reconfiguration complete message of the second terminal, the eNB. And sending an RRC configuration end message to the first terminal and the second terminal respectively. After receiving the RRC configuration end message, the first terminal starts local data exchange with the second terminal, and after receiving the RRC configuration end message, the second terminal starts local data exchange with the first terminal. The above is the normal flow of the RRC connection reconfiguration and the configuration is successful. If the RRC connection reconfiguration fails, the RRC connection reconfiguration exception procedure is entered. 11 is a flowchart of an RRC connection reconfiguration failure message according to a preferred embodiment of the present invention. As shown in FIG. 11, after the eNB sends an RRC connection reconfiguration message to the first terminal, if the first terminal is performing RRC connection reconfiguration, The reconfiguration failure fails. In order to prevent the failure of the local exchange bearer establishment from affecting other applications, an RRCConnectionConfigurationFailure message is added in the RRC connection reconfiguration exception procedure of the local exchange, and the message indicates that the RRC connection configuration of the local exchange fails. The first terminal sends the message to e B, and the first terminal may carry an RRCConnectionConfigurationFigurationCause unit in the message, the unit indicating the reason for the failure. The eNB may re-allocate the RRC connection reconfiguration related parameter for the local exchange communication according to the failure reason, and resend the RRCConnectionReconfiguration message. If the configuration is successful, the first terminal returns the RRCConnectionReconfigurationComplete message, and the eNB performs the following process, after receiving the first terminal and The RRCConnectionReconfigurationComplete message of the second terminal sends a bearer setup response to the MME, indicating that the local bearer is successfully established. If the configuration is successful, the first terminal will return the RRCConnectionConfigurationFailure message a second time, and the eNB sends a bearer setup response to the MME, where the message is E. In the -RAB Failed to Setup List unit, it indicates that the local bearer setup failed due to the RRC connection reconfiguration failure with the first terminal. If the RRC connection reconfiguration of the second terminal is successful, in the preferred embodiment, the eNB further sends an RRC connection reconfiguration recovery message to the second terminal, and restores the second terminal to the state before the connection reconfiguration. Step four, the local exchange process. After the local exchange bearer is established, local data exchange will take place. 12 is a flow chart of a local exchange message according to a preferred embodiment of the present invention. As shown in FIG. 12, when the first terminal has data to transmit, the first terminal sends scheduling request signaling, that is, SR signaling, and the eNB receives the SR. After the signaling, the UL grant signaling is sent, where the signaling includes the uplink transmission resource allocated for the first terminal, but the uplink resource allocated by the UL grant is very limited. In this embodiment, after receiving the UL grant signaling, the first terminal sends a BSR message to the eNB for the uplink resource allocated by the eNB, where the message carries the buffer (ie, cache) of the data to be sent by the first terminal. size. eNB After the message, the buffer size of the data to be sent by the first terminal will be obtained. The eNB checks the size of the space left by the forwarding buffer used for the local exchange. If the remaining space of the forwarding buffer is greater than the buffers of the data to be sent by the first terminal, the eNB allocates uplink resources to the first terminal and sends UL grant signaling. After receiving the uplink signaling, the first terminal sends the service data on the uplink resource allocated by the eNB. The data flow of the local exchange between the first terminal and the second terminal. FIG. 13 is a flowchart of local exchange data processing (PDCP layer forwarding) according to a preferred embodiment of the present invention. As shown in FIG. 13, in the preferred embodiment, the first terminal sends service data to the second terminal. The switching TFT is mapped to the locally switched DRB of the first terminal, and after being processed by the PDCP layer, the RLC layer, the MAC layer, and the PHY layer, is sent out through the air interface. After receiving the data sent by the first terminal, the eNB passes through the PHY layer, the MAC layer, and the RLC layer to reach the PDCP layer. There are two data forwarding methods: one is forwarding at the PDCP layer, and the other is at PDCP. Forward on the layer. In the preferred embodiment, locally exchanged data is forwarded at the PDCP layer. After the data passes through the RLC layer, among the DRBs corresponding to the DRB ID exchanged locally by the eNB, the eNB reads data from the DRB, writes it into the forwarding buffer, and records the packet read from the DRB. Number, record it as countMSB-Uplink. The eNB allocates downlink resources to the second terminal, and reads data from the forwarding buffer, and writes the data into the DRB corresponding to the local exchange DRB ID2 of the eNB. And record the number of packets written to the DRB, and record it as countMSB-Downlink. After the data is written into the DRB corresponding to the DRB ID2 of the eNB, it is processed by the RLC layer, the MAC layer, and the PHY layer, and is sent to the second terminal. After receiving the data, the second terminal passes the PHY layer and the MAC layer. After the RLC layer and the PDCP layer are processed, the data is written into the DRB corresponding to the second terminal local exchange DRB ID2, and the data is mapped to the service layer through the mapping of the second terminal local switching TFT. Forwarding at the PDCP layer, data encryption and decryption processing is performed between the first terminal and the second terminal. However, in order to prevent the data between the first terminal and the eNB from being attacked by the intruder. The local exchange countercheck mechanism is adopted between the eNB and the first terminal, and the local exchange countercheck mechanism is also adopted between the eNB and the second terminal. 14 is a message flow diagram of a ConterCheck base station for preventing illegal intrusion according to a preferred embodiment of the present invention. As shown in FIG. 14, when the value of the countMSB-Uplink of the DRB corresponding to the DRB ID of the eNB reaches a certain value, the eNB A Countercheck message is sent to the first terminal, and the drb-CountMSB-InfoList field of the message will contain the value of countMSB-Uplink. The first terminal performs a Countercheck check according to the normal LTE procedure. And return the CounterCheckResponse message. When the value of the countMSB-Downlink of the DRB corresponding to the DRB ID2 of the eNB reaches a certain value, the eNB sends a Countercheck message to the second terminal, and the drb-CountMSB-InfoList field of the message will contain the value of countMSB-Uplink. The second terminal performs a CountCheck check according to a normal LTE process. And return the CounterCheckResponse message. Only when the eNB and the first terminal and the eNB and the second terminal are both correct, it is considered that the local switching link between the first terminal and the second terminal passes the Countercheck check. The preferred embodiment of the present invention provides a specific embodiment in which the first terminal and the second terminal establish a local bearer and perform local exchange. In the preferred embodiment, the PGW determines whether the local bearer can be established. In the preferred embodiment, the first terminal and the second terminal are served by the same eNB, and are also under the management of the same PGW. In the preferred embodiment, the locally exchanged data is exchanged over the PDCP layer. Step 1: The PGW determines whether a local bearer can be established. FIG. 15 is a message flow diagram of a PGW determining whether a local exchange can be performed according to a preferred embodiment of the present invention. As shown in FIG. 15, the specific process of the PGW determining whether a bearer can be established is as follows: The first terminal performs attaching. The second terminal performs the attaching. When the first terminal has data to be sent to the second terminal, the PGW is requested to establish a normal bearer. After the normal LTE bearer is established, the first terminal sends data to the second terminal through the bearer. The data packet sent by the first terminal to the second terminal will pass through the PGW, and the PGW obtains the destination address of the data packet from the data packet sent by the first terminal. In this embodiment, the destination address of the first terminal data packet is the IP address of the second terminal. The PGW can obtain, according to the IP address of the second terminal, that the destination of the data packet sent by the first terminal is the second terminal. The PGW determines whether the first terminal and the second terminal are in the same eNB. If the first terminal and the second terminal are in the same eNB, and the eNB supports the local switching function, the PGW considers that the first terminal and the second terminal can perform the If the first terminal and the second terminal are not in the same eNB, the first terminal and the second terminal are determined to be in the neighboring eNB, and the two neighboring eNBs support the local switching function. Condition, the first terminal and the second terminal can perform local exchange. If the above two conditions are not met, the first terminal and the second terminal cannot perform local exchange. In this embodiment, the first terminal and the second terminal serve the same e B, so that local exchange can be performed, and the PGW will initiate a local bearer establishment process. Step 2: The PGW initiates a process of establishing a local bearer.
PGW发起本地承载建立的流程, PGW生成用于本地交换的第一终端的 TFT (即 上述第一 TFT), 首先按照正常的流程, 生成第一终端的 TFT, 然后在第一终端 TFT 的包滤波器的包滤波器内容单元中增加了一个新的类型(即本地交换的地址类型), 并 在本地交换的地址类型后面跟着目标 UE的 IP地址 (即第二终端的 IP地址), 并且只 能包含第二终端的 IP地址。 The PGW initiates a process of establishing a local bearer, and the PGW generates a TFT for the first terminal for local exchange (ie, the first TFT), first generates a TFT of the first terminal according to a normal process, and then filters the packet of the TFT in the first terminal. A new type (ie, the locally exchanged address type) is added to the packet filter content unit, and the locally exchanged address type is followed by the IP address of the target UE (ie, the IP address of the second terminal), and Contains the IP address of the second terminal.
PGW还生成用于本地交换的第二终端的 TFT (即上述第二 TFT), 首先按照正常 的流程,生成第二终端的 TFT,然后在第二终端 TFT的包滤波器的包滤波器内容单元, 增加了一个新的类型(即本地交换的地址类型), 并在本地交换的地址类型后面跟着目 标 UE的 IP地址 (即第一终端的 IP地址), 并且只能包含第一终端的 IP地址。 第一终端的本地交换 TFT和第二终端的本地交换 TFT组成 TFT对。 The PGW also generates a TFT for the second terminal for local exchange (ie, the above second TFT), first generates a TFT of the second terminal according to a normal flow, and then a packet filter content unit of the packet filter of the second terminal TFT , A new type (ie, the locally exchanged address type) is added, and the locally exchanged address type is followed by the IP address of the target UE (ie, the IP address of the first terminal), and can only contain the IP address of the first terminal. The local switching TFT of the first terminal and the local switching TFT of the second terminal constitute a TFT pair.
PGW 生成本地承载建立消息, 该消息除了包含正常的承载建立消息包含的参数 夕卜。 还包括本地交换 TFT对和第二终端的 IP地址。 The PGW generates a local bearer setup message, which contains the parameters contained in the normal bearer setup message. It also includes the local exchange TFT pair and the IP address of the second terminal.
PGW生成 PGW到 MME的本地承载建立消息, 该消息经过 SGW, 发给 MME。 MME根据第二终端的 IP地址判断出第二终端, 根据第二终端的上下文信息, 得到第 二终端的 MME UE SIAP ID值和 eNB UE SIAP Π)值。 和第二终端的 UE Aggregate Maximum Bit Rate的值。 MME根据该消息生成第一终端的 E-RAB ID (即上述第一 E-RAB ID) 和第二终端 E-RAB ID (即上述第二 E-RAB ID)。MME还生成 NAS消息, 并将其打包进 NAS PDU和 NAS PDU2参数中, 在 NAS PDU参数中包含到第一终端 NAS消息,其中包含第一终端对应的本地交换 TFT,在 NAS PDU2参数中包含到第二 终端 NAS消息, 其中包含第二终端对应的本地交换 TFT。 之后, MME生成 MME到 eNB的本地承载建立消息。图 7是根据本发明优选实施例的 MME到 eNB的本地承载 建立消息的消息框图,如图 7所示,该消息包括如下参数: MME UE S1AP ID, eNB UE SIAP ID, UE Aggregate Maximum Bit Rate, E-RAB ID, NAS-PDU, E-RAB Level QoS Parameters, MME UE S1AP ID2, eNB UE S1AP ID2, UE Aggregate Maximum Bit Rate2, E-RAB ID2, NAS-PDU2其中 MME UE SIAP ID, eNB UE SIAP ID, UE Aggregate Maximum Bit Rate, E-RAB ID是第一终端相关的参数, MME UE SIAP ID2, eNB UE S1AP ID2, UE Aggregate Maximum Bit Rate2, E-RAB ID2, NAS-PDU2是第二终端相 关的参数。 Qos参数由 PGW通过本地承载建立消息传给 MME, 是针对第一终端到第 二终端的本地承载的 (只有一个)。 图 8是根据本发明优选实施例的本地承载建立流程图, 如图 8所示, PGW发起本 地承载建立的流程包括: PGW生成到 MME的本地承载建立消息, 该消息包括 TFT 对, 第二终端的 IP地址, 和 Qos等参数。 该消息经过 SGW, 发给 MME。 MME收到 该消息后, 生成 MME到 eNB的本地承载建立消息, 该消息包括第一终端和第二终端 的 UE ID,第一终端和第二终端的 E-RAB ID和 Qos等参数。 MME发送该消息到 eNB。 步骤三: eNB完成 RRC连接重配, 完成本地承载的建立。 eNB收到 MME发的本地承载建立消息后,根据该消息的 E-RAB ID对,生成 DRB 对并生成其对应的 DRB ID对和 LCID对。 eNB根据该消息中的第一终端对应的 E-RAB ID参数生成第一终端到 eNB的数据无线承载(DRB), 并生成数据无线承载标识 DRB ID。 eNB根据该消息中的第二终端对应的 E-RAB ID2参数, 生成第二终端到 eNB的 数据无线承载 (DRB), 并生成数据无线承载标识 DRB ID2, 两个 DRB有固定的绑定 关系, 同样 DRB ID和 DRB ID2也有固定的绑定关系, DRB ID和 DRB ID2组成 DRB ID对。 eNB生成第一终端到 eNB的 DRB对应的逻辑信道, 并生成 LCID, eNB生成 第二终端到 eNB的 DRB对应的逻辑信道,并生成 LCID2。e B在生成 DRB ID和 DRB ID2时, 可以突破目前协议规定的无线承载标识个数的限制。 同样 eNB在生成 LCID 和 LCID2时, 也可以突破目前协议规定的逻辑信道标识的个数限制。 图 9是根据本发 明优选实施例的本地交换的 MAC字头的框图, 如图 9所示, eNB在生成 MAC子头 时, 可以使用原来的 R位即保留位, 表明其为本地交换的 Mac子头格式, 可以将 R 位改为 T位, 即类型 (type) 位, 可以用 1表明是本地交换的 MAC子头, 用 0表明 为正常的 MAC头,。 并且在进行本地交换时, 可以用 LCID的保留值来标识本地交换 的逻辑信道, 以到达对 LCID 个数的扩展。 eNB 在 RRC 连接重配消息中的 RadioResourceConfigDedicated字段中增加 LSdrb-ToAddModList字段, 该字段包含本 地交换使用的 DRB ID。 eNB生成本地交换的 DRB对和逻辑信道并生成 DRB ID对和 LCID之后,分别生 成 eNB到第一终端的 RRC连接重配消息, 和 eNB到第二终端的 RRC连接重配消息。 eNB到第一终端的 RRC连接重配消息包含 eNB到第一终端的 DRB对应的 DRB ID和 LCID等参数, eNB从 MME到 eNB的承载建立消息的 NAS PDU参数中获得其包含 的 NAS消息, 并通过 RRC连接重配消息捎带该 NAS消息, 该 NAS消息中包含第一 终端所对应的本地交换的 TFT。 eNB到第二终端的 RRC连接重配消息包含第二终端 至 lj eNB的 DRB对应的 DRB ID2和 LCID2等参数, eNB从 MME到 eNB的承载建立 消息的 NAS PDU参数中获得其包含的 NAS消息, 并通过连接重配消息捎带该 NAS 消息, 该 NAS消息中包含第二终端所对应的本地交换 TFT。 eNB生成 RRC连接重配消息后,发起 RRC连接重配, 图 10是根据本发明优选实 施例的 RRC连接重配消息流程图, 如图 10所示, 发起 RRC连接重配流程包括: eNB 向第一终端发送 eNB到第一终端的 RRC连接重配消息, 向第二终端发送 eNB到第二 终端的 RRC连接重配消息。 第一终端在 RRC收到连接重配消息后, 将生成第一终端 到 eNB的本地交换 DRB, 该 DRB将用 DRB ID标识, 并将进行本地交换 TFT到本地 交换 DRB 的绑定, 将第一终端的本地交换 TFT绑定到第一终端到 eNB 的本地交换 DRB上。并完成 RRC连接重配的其他操作。在完成 RRC连接重配后,第一终端给 eNB 回 RRC连接重配完成消息。 第二终端在收到 RRC连接重配消息后, 将进行 TFT的绑 定, 将生成第二终端到 eNB的本地交换 DRB, 该 DRB将用 DRB ID2标识, 并将进行 本地交换 TFT到本地交换 DRB的绑定, 将第二终端的本地交换 TFT绑定到第二终端 到 eNB的本地交换 DRB上。 并完成 RRC连接重配的其他操作。 在完成 RRC连接重 配后, 第一终端给 eNB回 RRC连接重配完成消息。 eNB在收到第一终端的 RRC连接 重配完成消息和第二终端的 RRC连接重配完成消息之后。分别给第一终端和第二终端 发送 RRC配置结束消息。 第一终端收到 RRC配置结束消息之后, 开始和第二终端进 行本地数据交换,第二终端在收到 RRC配置结束消息之后, 开始和第一终端进行本地 数据交换 以上是 RRC连接重配, 配置成功的正常流程, 如果 RRC连接重配配置失败, 则 进入 RRC连接重配异常流程。图 11是根据本发明优选实施例的 RRC连接重配失败消 息流程图, 如图 11所示, 当 eNB给第一终端发 RRC连接重配消息后, 如果第一终端 在进行 RRC连接重配时, 重配失败, 为了不让本地交换承载建立的失败影响其他的应 用,在本地交换的 RRC连接重配异常流程中增加了 RRCConnectionConfigurationFailure 消息, 该消息表明本地交换的 RRC连接配置失败。第一终端发送该消息给 e B, 第一 终端可以在该消息中携带 RRCConnectionConfigurationFigurationCause单元,该单元表 明失败的原因。 eNB可以根据失败原因重新为本地交换通信分配 RRC连接重配的相关 参数, 并重新发送 RRCConnectionReconfiguration 消息, 如果配置成功, 第一终端回 RRCConnectionReconfigurationComplete消息, eNB将进行下面的流程, 在收到第一终 端和第二终端的 RRCConnectionReconfigurationComplete 消息之后发送承载建立响应 给 MME, 表明本地承载建立成功, 如果没有配置成功, 第一终端将第二次回 RRCConnectionConfigurationFailure消息, 则 eNB要发送承载建立响应给 MME, 在该 消息的 E-RAB Failed to Setup List单元中, 表明为是由于和第一终端的 RRC连接重配 失败导致的本地承载建立失败。 如果第二终端的 RRC 连接重配成功, 如本实施例所 示, eNB还要给第二终端发送 RRC连接重配恢复消息,将第二终端恢复到连接重配之 前的状态。 步骤四, 本地交换流程。 在建立好本地交换承载后,将进行本地数据交换。图 12是根据本发明优选实施例 的本地交换消息流程图, 如图 12所示, 本地数据交换的消息流程包括: 当第一终端有 数据要发送时, 第一终端发送调度请求信令, 即 SR信令, eNB收到 SR信令后, 发送 UL grant信令, 该信令包含为第一终端分配的进行上行发送的资源, 但该 UL grant分 配的上行资源非常有限。 在本实施例中, 第一终端在收到 UL grant信令后, 会在 eNB 为其分配的上行资源上发送 BSR消息, 该消息携带了第一终端要发送的数据的 buffer 的大小。 eNB收到该消息后, 将获得第一终端要发送数据的 buffer大小。 eNB将检查 进行本地交换所使用的转发 buffer所剩空间的大小, 如果转发 buffer的剩余空间大于 第一终端要发送数据的 buffers 则 eNB为第一终端分配上行资源, 并发送 UL grant信 令。 第一终端收到上行信令后, 在 eNB分配的上行资源上发送业务数据。 第一终端和第二终端进行本地交换。图 16是根据本发明优选实施例的本地交换数 据处理 (PDCP层之上转发) 的流程图, 如图 16所示, 在本实优选施例中, 是第一终 端给第二终端的业务数据, 经过本地交换 TFT映射到第一终端的本地交换的 DRB ID 对应的 DRB中, 在经过 PDCP层, RLC层, MAC层, PHY层的处理后, 通过空口发 送出去。 之后 eNB接收到第一终端发送的数据, 该数据经过 PHY层, MAC层, RLC 层的处理后到达 PDCP层, 有两种数据转发方法: 一种是在 PDCP层转发, 还有一种 是在 PDCP层之上转发, 在本优选实施例中, 本地交换的数据在 PDCP层之上转发。 数据经过 PDCP层之后, 已经在 eNB的本地交换的 DRB ID所对应的 DRB之中, 并 且第一终端到 eNB的数据已经经过 PDCP层的加解密处理和 countercheck的保护, eNB 在数据安全的处理上按照目前的协议处理即可。 eNB从该 DRB 中读取数据, 并将其 写入转发 buffer中, eNB为第二终端分配下行资源, 并从转发 buffer中读取数据, 并 将数据写入 eNB的本地交换 DRB ID2所对应的 DRB。数据被写入 DRB ID2所对应的 DRB后, 经过 PDCP层, RLC层, MAC层, PHY层的处理, 被发送给第二终端。 eNB 到第二终端之间的数据, 在经过 PDCP 层时, 已经经过 PDCP 层的加解密处理和 countercheck保护, eNB 在数据安全的处理上按照目前的协议处理即可。 第二终端接 收到该数据后, 数据经过 PHY层, MAC层, RLC层和 PDCP层的处理后, 数据被写 入第二终端的本地交换 DRB ID2所对应的 DRB中, 经过第二终端本地交换 TFT的映 射, 数据到达业务层。 需要说明的是, 上述各个模块是可以通过硬件来实现的。 例如: 一种处理器, 包 括上述各个模块, 或者, 上述各个模块分别位于一个处理器中。 在另外一个实施例中, 还提供了一种软件, 该软件用于执行上述实施例及优选实 施方式中描述的技术方案。 在另外一个实施例中, 还提供了一种存储介质, 该存储介质中存储有上述软件, 该存储介质包括但不限于: 光盘、 软盘、 硬盘、 可擦写存储器等。 从以上的描述中, 可以看出, 本发明实现了如下技术效果: 采用当 eNB或 PGW 判定第一终端和第二终端能够进行本地交换时, eNB可以协同同时位于 eNB或其中一 个位于相邻 eNB的第一终端和第二终端建立本地承载,进而使用本地承载转发第一终 端和第二终端之间的业务数据的方式, 解决了相关技术中通过 LTE技术进行数据转发 的方式会增加核心网的网络设备的负荷、 用户数据的传输时延的问题, 达到了降低核 心网的网络设备的负荷、 缩短数据的传输时延, 提高数据的传输速度的效果。 显然, 本领域的技术人员应该明白, 上述的本发明的各模块或各步骤可以用通用 的计算装置来实现, 它们可以集中在单个的计算装置上, 或者分布在多个计算装置所 组成的网络上, 可选地, 它们可以用计算装置可执行的程序代码来实现, 从而, 可以 将它们存储在存储装置中由计算装置来执行, 并且在某些情况下, 可以以不同于此处 的顺序执行所示出或描述的步骤, 或者将它们分别制作成各个集成电路模块, 或者将 它们中的多个模块或步骤制作成单个集成电路模块来实现。 这样, 本发明不限制于任 何特定的硬件和软件结合。 以上所述仅为本发明的优选实施例而已, 并不用于限制本发明, 对于本领域的技 术人员来说, 本发明可以有各种更改和变化。 凡在本发明的精神和原则之内, 所作的 任何修改、 等同替换、 改进等, 均应包含在本发明的保护范围之内。 The PGW generates a local bearer setup message from the PGW to the MME, and the message is sent to the MME through the SGW. The MME determines, according to the IP address of the second terminal, the second terminal, and obtains the MME UE SIAP ID value and the eNB UE SIAP Π) value of the second terminal according to the context information of the second terminal. And the value of the UE Aggregate Maximum Bit Rate of the second terminal. The MME generates an E-RAB ID (ie, the first E-RAB ID) of the first terminal and a second terminal E-RAB ID (ie, the second E-RAB ID) according to the message. The MME also generates a NAS message and packs it into the NAS PDU and NAS PDU2 parameters, and includes the first terminal NAS message in the NAS PDU parameter, which includes the local switching TFT corresponding to the first terminal, and is included in the NAS PDU2 parameter. The second terminal NAS message includes a local switching TFT corresponding to the second terminal. Thereafter, the MME generates a local bearer setup message of the MME to the eNB. 7 is a message block diagram of a local bearer setup message of an MME to an eNB according to a preferred embodiment of the present invention. As shown in FIG. 7, the message includes the following parameters: MME UE S1AP ID, eNB UE SIAP ID, UE Aggregate Maximum Bit Rate, E-RAB ID, NAS-PDU, E-RAB Level QoS Parameters, MME UE S1AP ID2, eNB UE S1AP ID2, UE Aggregate Maximum Bit Rate2, E-RAB ID2, NAS-PDU2 where MME UE SIAP ID, eNB UE SIAP ID , UE Aggregate Maximum Bit Rate, E-RAB ID is a parameter related to the first terminal, MME UE SIAP ID2, eNB UE S1AP ID2, UE Aggregate Maximum Bit Rate2, E-RAB ID2, NAS-PDU2 is a second terminal related parameter . The Qos parameter is transmitted by the PGW to the MME through the local bearer setup message, which is local to the first terminal to the second terminal (only one). FIG. 8 is a flowchart of a local bearer setup according to a preferred embodiment of the present invention. As shown in FIG. 8, the PGW initiates a local bearer setup process. The PGW generates a local bearer setup message to the MME, where the message includes a TFT pair, and the second terminal. IP address, and parameters such as Qos. The message is sent to the MME via the SGW. After receiving the message, the MME generates a local bearer setup message of the MME to the eNB, where the message includes the UE ID of the first terminal and the second terminal, and the E-RAB ID and Qos parameters of the first terminal and the second terminal. The MME sends the message to the eNB. Step 3: The eNB completes the RRC connection reconfiguration and completes the establishment of the local bearer. After receiving the local bearer setup message sent by the MME, the eNB generates a DRB pair and generates a corresponding DRB ID pair and an LCID pair according to the E-RAB ID pair of the message. The eNB generates a data radio bearer (DRB) of the first terminal to the eNB according to the E-RAB ID parameter corresponding to the first terminal in the message, and generates a data radio bearer identifier DRB. ID. The eNB generates a data radio bearer (DRB) of the second terminal to the eNB according to the E-RAB ID2 parameter corresponding to the second terminal in the message, and generates a data radio bearer identifier DRB ID2, where the two DRBs have a fixed binding relationship. Similarly, the DRB ID and the DRB ID2 also have a fixed binding relationship, and the DRB ID and the DRB ID2 form a DRB ID pair. The eNB generates a logical channel corresponding to the DRB of the first terminal to the eNB, and generates an LCID, and the eNB generates a logical channel corresponding to the DRB of the second terminal to the eNB, and generates an LCID2. When generating the DRB ID and DRB ID2, e B can break the limit of the number of radio bearer identifiers specified in the current protocol. Similarly, when generating the LCID and LCID2, the eNB can also break the limit of the number of logical channel identifiers specified by the current protocol. 9 is a block diagram of a locally exchanged MAC header according to a preferred embodiment of the present invention. As shown in FIG. 9, when generating a MAC subheader, the eNB may use the original R bit, that is, a reserved bit, to indicate that it is a locally switched Mac. Sub-header format, you can change the R bit to the T bit, that is, the type bit. You can use 1 to indicate the MAC sub-header of the local exchange, and 0 to indicate the normal MAC header. And when performing local exchange, the reserved value of the LCID can be used to identify the logical channel of the local exchange to reach the extension of the number of LCIDs. The eNB adds an LSdrb-ToAddModList field in the RadioResourceConfigDedicated field in the RRC Connection Reconfiguration message, which field contains the DRB ID used by the local exchange. After the eNB generates the locally exchanged DRB pair and the logical channel and generates the DRB ID pair and the LCID, respectively, an RRC connection reconfiguration message from the eNB to the first terminal and an RRC connection reconfiguration message from the eNB to the second terminal are generated. The RRC connection reconfiguration message of the eNB to the first terminal includes parameters such as a DRB ID and an LCID corresponding to the DRB of the eNB to the first terminal, and the eNB obtains the NAS message included in the NAS PDU parameter of the bearer setup message of the MME to the eNB, and The NAS message is carried by the RRC connection reconfiguration message, and the NAS message includes the locally exchanged TFT corresponding to the first terminal. The RRC connection reconfiguration message of the eNB to the second terminal includes parameters such as DRB ID2 and LCID2 corresponding to the DRB of the second terminal to the lj eNB, and the eNB obtains the NAS message included in the NAS PDU parameter of the bearer setup message of the MME to the eNB, And the NAS message is carried by the connection reconfiguration message, where the NAS message includes the local switching TFT corresponding to the second terminal. After the eNB generates the RRC connection reconfiguration message, the RRC connection reconfiguration is initiated. FIG. 10 is a flowchart of the RRC connection reconfiguration message according to the preferred embodiment of the present invention. As shown in FIG. 10, the RRC connection reconfiguration process includes: A terminal sends an RRC connection reconfiguration message of the eNB to the first terminal, and sends an RRC connection reconfiguration message of the eNB to the second terminal to the second terminal. After receiving the connection reconfiguration message, the first terminal generates a local exchange DRB of the first terminal to the eNB, and the DRB identifies the DRB ID, and performs binding of the local switching TFT to the local exchange DRB, and the first The local switching TFT of the terminal is bound to the local exchange DRB of the first terminal to the eNB. And complete other operations of RRC connection reconfiguration. After completing the RRC connection reconfiguration, the first terminal returns an RRC connection reconfiguration complete message to the eNB. After receiving the RRC connection reconfiguration message, the second terminal will perform TFT binding, and will generate a local exchange DRB of the second terminal to the eNB, the DRB will be identified by DRB ID2, and the local switching TFT will be performed to the local exchange DRB. Binding, binding the local switching TFT of the second terminal to the second terminal Go to the local exchange DRB of the eNB. And complete other operations of RRC connection reconfiguration. After completing the RRC connection reconfiguration, the first terminal returns an RRC connection reconfiguration complete message to the eNB. After receiving the RRC connection reconfiguration complete message of the first terminal and the RRC connection reconfiguration complete message of the second terminal, the eNB. And sending an RRC configuration end message to the first terminal and the second terminal respectively. After receiving the RRC configuration end message, the first terminal starts to perform local data exchange with the second terminal, and after receiving the RRC configuration end message, the second terminal starts to perform local data exchange with the first terminal, where the RRC connection reconfiguration is configured. If the RRC connection reconfiguration configuration fails, the RRC connection reconfiguration exception procedure is entered. 11 is a flowchart of an RRC connection reconfiguration failure message according to a preferred embodiment of the present invention. As shown in FIG. 11, after the eNB sends an RRC connection reconfiguration message to the first terminal, if the first terminal is performing RRC connection reconfiguration, The reconfiguration failure fails. In order to prevent the failure of the local exchange bearer establishment from affecting other applications, an RRCConnectionConfigurationFailure message is added in the RRC connection reconfiguration exception procedure of the local exchange, and the message indicates that the RRC connection configuration of the local exchange fails. The first terminal sends the message to e B, and the first terminal may carry an RRCConnectionConfigurationFigurationCause unit in the message, the unit indicating the reason for the failure. The eNB may re-allocate the RRC connection reconfiguration related parameter for the local exchange communication according to the failure reason, and resend the RRCConnectionReconfiguration message. If the configuration is successful, the first terminal returns the RRCConnectionReconfigurationComplete message, and the eNB performs the following process, after receiving the first terminal and The RRCConnectionReconfigurationComplete message of the second terminal sends a bearer setup response to the MME, indicating that the local bearer is successfully established. If the configuration is successful, the first terminal will return the RRCConnectionConfigurationFailure message a second time, and the eNB sends a bearer setup response to the MME, where the message is E. In the -RAB Failed to Setup List unit, it indicates that the local bearer setup failed due to the RRC connection reconfiguration failure with the first terminal. If the RRC connection reconfiguration of the second terminal is successful, as shown in this embodiment, the eNB further sends an RRC connection reconfiguration recovery message to the second terminal, and restores the second terminal to the state before the connection reconfiguration. Step four, the local exchange process. After the local exchange bearer is established, local data exchange will take place. FIG. 12 is a flow chart of a local exchange message according to a preferred embodiment of the present invention. As shown in FIG. 12, the message flow of the local data exchange includes: when the first terminal has data to send, the first terminal sends a scheduling request signaling, that is, The SR signaling, after receiving the SR signaling, the eNB sends the UL grant signaling, where the signaling includes the uplink transmission resource allocated for the first terminal, but the uplink resource allocated by the UL grant is very limited. In this embodiment, after receiving the UL grant signaling, the first terminal sends a BSR message to the eNB for the uplink resource allocated by the eNB, where the message carries the size of the buffer of the data to be sent by the first terminal. After receiving the message, the eNB obtains the buffer size of the data to be sent by the first terminal. The eNB will check the size of the space left by the forwarding buffer used for local switching, if the remaining space of the forwarding buffer is greater than When the first terminal wants to send buffers of data, the eNB allocates uplink resources to the first terminal, and sends UL grant signaling. After receiving the uplink signaling, the first terminal sends the service data on the uplink resource allocated by the eNB. The first terminal and the second terminal perform local exchange. FIG. 16 is a flowchart of local exchange data processing (for forwarding on the PDCP layer) according to a preferred embodiment of the present invention. As shown in FIG. 16, in the preferred embodiment, the service data of the first terminal to the second terminal is shown in FIG. After being processed by the PDCP layer, the RLC layer, the MAC layer, and the PHY layer, the local switching TFT is mapped to the DRB corresponding to the DRB ID of the local exchange of the first terminal, and then sent out through the air interface. After receiving the data sent by the first terminal, the eNB passes through the PHY layer, the MAC layer, and the RLC layer to reach the PDCP layer. There are two data forwarding methods: one is forwarding at the PDCP layer, and the other is at PDCP. Forwarding over the layer, in the preferred embodiment, locally exchanged data is forwarded over the PDCP layer. After the data passes through the PDCP layer, it is already in the DRB corresponding to the DRB ID exchanged locally by the eNB, and the data of the first terminal to the eNB has been protected by the encryption and decryption processing of the PDCP layer and countercheck, and the eNB processes the data security. It can be processed according to the current agreement. The eNB reads data from the DRB and writes it into the forwarding buffer. The eNB allocates downlink resources to the second terminal, and reads data from the forwarding buffer, and writes the data to the local exchange DRB ID2 corresponding to the eNB. DRB. After the data is written into the DRB corresponding to the DRB ID2, it is processed by the PDCP layer, the RLC layer, the MAC layer, and the PHY layer, and is sent to the second terminal. The data between the eNB and the second terminal has been encrypted and decrypted by the PDCP layer and counterchecked by the PDCP layer. The eNB can process the data security according to the current protocol. After the second terminal receives the data, the data is processed by the PHY layer, the MAC layer, the RLC layer, and the PDCP layer, and the data is written into the DRB corresponding to the local exchange DRB ID2 of the second terminal, and is locally exchanged by the second terminal. TFT mapping, data reaches the business layer. It should be noted that each of the above modules can be implemented by hardware. For example: a processor, including the above modules, or each of the above modules is located in one processor. In another embodiment, software is also provided for performing the technical solutions described in the above embodiments and preferred embodiments. In another embodiment, a storage medium is provided, the software being stored, including but not limited to: an optical disk, a floppy disk, a hard disk, a rewritable memory, and the like. From the above description, it can be seen that the present invention achieves the following technical effects: When the eNB or the PGW determines that the first terminal and the second terminal can perform local exchange, the eNB can cooperate with the eNB or one of the neighboring eNBs. The first terminal and the second terminal establish a local bearer, and then use the local bearer to forward the service data between the first terminal and the second terminal, and solve the related art to perform data forwarding by using the LTE technology. The method increases the load of the network equipment of the core network and the transmission delay of the user data, and achieves the effect of reducing the load of the network equipment of the core network, shortening the transmission delay of the data, and improving the data transmission speed. Obviously, those skilled in the art should understand that the above modules or steps of the present invention can be implemented by a general-purpose computing device, which can be concentrated on a single computing device or distributed over a network composed of multiple computing devices. Alternatively, they may be implemented by program code executable by the computing device, such that they may be stored in the storage device by the computing device and, in some cases, may be different from the order herein. The steps shown or described are performed, or they are separately fabricated into individual integrated circuit modules, or a plurality of modules or steps are fabricated as a single integrated circuit module. Thus, the invention is not limited to any specific combination of hardware and software. The above is only the preferred embodiment of the present invention, and is not intended to limit the present invention, and various modifications and changes can be made to the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and scope of the present invention are intended to be included within the scope of the present invention.

Claims

权 利 要 求 书 claims
1. 一种终端的本地交换方法, 包括: 1. A local switching method for a terminal, including:
演进型基站 e B协同第一终端和第二终端建立本地承载, 其中, 所述本地 承载是指本地交换过程中需要使用的专用于设备到设备 D2D的承载; The evolved base station eB cooperates with the first terminal and the second terminal to establish a local bearer, where the local bearer refers to a bearer dedicated to device-to-device D2D that needs to be used in the local switching process;
所述 eNB 通过所述本地承载转发所述第一终端和所述第二终端之间的业 务数据以实现本地交换。 The eNB forwards the service data between the first terminal and the second terminal through the local bearer to implement local switching.
2. 根据权利要求 1所述的方法, 其中, 演进型基站 eNB协同所述第一终端和所述 第二终端建立本地承载, 包括: 2. The method according to claim 1, wherein the evolved base station eNB cooperates with the first terminal and the second terminal to establish a local bearer, including:
在分组数据网关 PGW发起本地承载建立流程后, 所述 eNB分别向所述第 一终端和所述第二终端发起第一无线资源控制 RRC连接重配流程、第二无线资 源控制 RRC连接重配流程; After the packet data gateway PGW initiates the local bearer establishment process, the eNB initiates a first radio resource control RRC connection reconfiguration process and a second radio resource control RRC connection reconfiguration process to the first terminal and the second terminal respectively. ;
在所述第一 RRC连接重配和所述第二 RRC连接重配均成功的情况下, 所 述 eNB确定所述本地承载的建立已经完成, 否则, 根据所述第一终端和 /或所 述第二终端反馈的建立失败消息,重新向所述第一终端和 /或所述第二终端发起 RRC连接重配流程, 直至完成所述本地承载的建立。 If both the first RRC connection reconfiguration and the second RRC connection reconfiguration are successful, the eNB determines that the establishment of the local bearer has been completed, otherwise, according to the first terminal and/or the Based on the establishment failure message fed back by the second terminal, the RRC connection reconfiguration process is reinitiated to the first terminal and/or the second terminal until the establishment of the local bearer is completed.
3. 根据权利要求 2所述的方法, 其中, 分组数据网关 PGW发起本地承载建立流 程, 包括: 3. The method according to claim 2, wherein the packet data gateway PGW initiates a local bearer establishment process, including:
所述 PGW接收到所述第一终端发送的本地承载建立请求消息后, 为所述 第一终端生成第一传输流模板 TFT,并在所述第一 TFT中增加本地交换的地址 类型和所述第二终端的 IP地址, 其中, 所述本地承载建立请求消息包括: 所述 第一终端的 IP地址和所述第二终端的 IP地址; After receiving the local bearer establishment request message sent by the first terminal, the PGW generates a first transport flow template TFT for the first terminal, and adds the locally switched address type and the first TFT to the first TFT. The IP address of the second terminal, wherein the local bearer establishment request message includes: the IP address of the first terminal and the IP address of the second terminal;
所述 PGW根据所述第二终端的 IP地址为所述第二终端生成第二 TFT, 并 在所述第二 TFT中增加所述本地交换的地址类型和所述第一终端的 IP地址; 所述 PGW生成第一本地承载建立消息, 其中, 第一本地承载建立消息是 从所述 PGW到移动管理实体 MME的消息, 所述本地承载建立消息包括: 所 述第一终端的 IP地址、 由所述第一 TFT和所述第二 TFT组成的本地交换 TFT 对, 以及服务质量 QoS参数; 所述 PGW通过服务网关 SGW将所述第一本地承载建立消息发送给所述 MME, 由所述 MME根据所述第一本地承载建立消息生成第二本地承载建立消 息, 其中, 所述第二本地承载建立消息是从所述 MME到所述 eNB的消息, 所 述第二本地承载建立消息包括: 所述第一终端的第一 UE ID、 所述第二终端的 第二 UE ID、所述第一终端的第一 E-RAB ID、所述第二终端的第二 E-RAB ID, 以及所述 QoS参数。 The PGW generates a second TFT for the second terminal according to the IP address of the second terminal, and adds the locally switched address type and the IP address of the first terminal to the second TFT; The PGW generates a first local bearer establishment message, wherein the first local bearer establishment message is a message from the PGW to the mobility management entity MME, and the local bearer establishment message includes: the IP address of the first terminal, a pair of locally switched TFTs composed of the first TFT and the second TFT, and quality of service QoS parameters; the PGW sends the first local bearer establishment message to the MME through the serving gateway SGW, and the MME The first local bearer establishment message generates a second local bearer establishment message. information, wherein the second local bearer establishment message is a message from the MME to the eNB, and the second local bearer establishment message includes: the first UE ID of the first terminal, the second terminal the second UE ID, the first E-RAB ID of the first terminal, the second E-RAB ID of the second terminal, and the QoS parameters.
4. 根据权利要求 3所述的方法, 其中, 所述 eNB分别向所述第一终端和所述第二 终端发起第一无线资源控制 RRC连接重配流程、 第二无线资源控制 RRC连接 重配流程, 包括: 4. The method according to claim 3, wherein the eNB initiates a first Radio Resource Control RRC connection reconfiguration process and a second Radio Resource Control RRC connection reconfiguration to the first terminal and the second terminal respectively. Process, including:
所述 eNB向所述第一终端发起所述第一无线资源控制 RRC连接重配流程, 包括: The eNB initiates the first radio resource control RRC connection reconfiguration process to the first terminal, including:
所述 eNB根据所述第一 E-RAB ID生成所述第一终端到所述 eNB的第一数 据无线承载 DRB,并生成对应于所述第一 DRB的第一 DRB ID、第一逻辑信道, 以及第一 LC ID, 其中, 所述第一 LC ID的保留值用于在进行本地交换的过程 中标识所述第一逻辑信道; The eNB generates a first data radio bearer DRB from the first terminal to the eNB based on the first E-RAB ID, and generates a first DRB ID and a first logical channel corresponding to the first DRB, and a first LC ID, wherein the reserved value of the first LC ID is used to identify the first logical channel during local switching;
所述 eNB生成对应于所述第一终端的第一 RRC连接重配消息, 其中, 所 述第一 RRC连接重配消息包括: 所述第一 DRB ID、 所述第一 LC ID以及对应 于所述第一终端的第一 NAS消息, 所述第一 NAS消息携带有所述第一 TFT; 所述 eNB向所述第一终端发送所述第一 RRC连接重配消息, 发起所述第 一 RRC连接重配流程; The eNB generates a first RRC connection reconfiguration message corresponding to the first terminal, wherein the first RRC connection reconfiguration message includes: the first DRB ID, the first LC ID and the first RRC connection reconfiguration message corresponding to the first terminal. The first NAS message of the first terminal, the first NAS message carries the first TFT; the eNB sends the first RRC connection reconfiguration message to the first terminal, initiating the first RRC Connection reconfiguration process;
所述 eNB向所述第二终端发起所述第二无线资源控制 RRC连接重配流程, 包括: The eNB initiates the second radio resource control RRC connection reconfiguration process to the second terminal, including:
所述 eNB根据所述第二 E-RAB ID生成所述第二终端到所述 eNB的第二数 据无线承载 DRB,并生成对应于所述第二 DRB的第二 DRB ID、第二逻辑信道, 以及第二 LC ID, 其中, 所述第二 LC ID的保留值用于在进行本地交换的过程 中标识所述第二逻辑信道; The eNB generates a second data radio bearer DRB from the second terminal to the eNB according to the second E-RAB ID, and generates a second DRB ID and a second logical channel corresponding to the second DRB, and a second LC ID, wherein the reserved value of the second LC ID is used to identify the second logical channel during local switching;
所述 eNB生成对应于所述第二终端的第二 RRC连接重配消息, 其中, 所 述第二 RRC连接重配消息包括: 所述第二 DRB ID、 所述第二 LC ID, 以及对 应于所述第二终端的第二 NAS消息,所述第二 NAS消息携带有所述第二 TFT; 所述 eNB向所述第二终端发送所述第二 RRC连接重配消息, 发起所述第 二 RRC连接重配流程; 其中, 所述第一 DRB 和所述第二 DRB 存在固定的绑定关系, 所述第一 DRB ID和所述第二 DRB ID存在固定的绑定关系,所述第一 DRB ID和所述第 二 DRB ID组成 DRB ID对。 The eNB generates a second RRC connection reconfiguration message corresponding to the second terminal, wherein the second RRC connection reconfiguration message includes: the second DRB ID, the second LC ID, and the second RRC connection reconfiguration message corresponding to the second terminal. The second NAS message of the second terminal, the second NAS message carries the second TFT; the eNB sends the second RRC connection reconfiguration message to the second terminal, initiating the second RRC connection reconfiguration process; Wherein, the first DRB and the second DRB have a fixed binding relationship, the first DRB ID and the second DRB ID have a fixed binding relationship, the first DRB ID and the third DRB ID have a fixed binding relationship. Two DRB IDs form a DRB ID pair.
5. 根据权利要求 4所述的方法, 其中, 在所述 eNB分别向所述第一终端和所述第 二终端发起第一无线资源控制 RRC连接重配流程、 第二无线资源控制 RRC连 接重配流程之后, 包括: 5. The method according to claim 4, wherein the eNB initiates a first radio resource control RRC connection reconfiguration process and a second radio resource control RRC connection reconfiguration process to the first terminal and the second terminal respectively. After the configuration process, including:
所述第一终端将所述第一 TFT绑定到所述第一 DRB, 并执行第一 RRC连 接重配的其他操作; The first terminal binds the first TFT to the first DRB and performs other operations of the first RRC connection reconfiguration;
所述第二终端将所述第二 TFT绑定到所述第二 DRB, 并执行第二 RRC连 接重配的其他操作。 The second terminal binds the second TFT to the second DRB and performs other operations of second RRC connection reconfiguration.
6. 根据权利要求 5所述的方法,其中,在所述第一 RRC连接重配和所述第二 RRC 连接重配均成功的情况下, 包括: 6. The method according to claim 5, wherein, in the case where both the first RRC connection reconfiguration and the second RRC connection reconfiguration are successful, it includes:
所述第一终端向所述 eNB发送第一 RRC连接重配完成消息; 所述第二终端向所述 eNB发送第二 RRC连接重配完成消息。 The first terminal sends a first RRC connection reconfiguration complete message to the eNB; and the second terminal sends a second RRC connection reconfiguration complete message to the eNB.
7. 根据权利要求 6所述的方法, 其中, 在所述 eNB接收到所述第一 RRC连接重 配完成消息和所述第二 RRC连接重配完成消息的情况下, 包括: 7. The method according to claim 6, wherein, in the case where the eNB receives the first RRC connection reconfiguration complete message and the second RRC connection reconfiguration complete message, the method includes:
所述 eNB向所述第一终端发送第一 RRC配置结束消息, 向所述第二终端 发送第二 RRC配置结束消息。 The eNB sends a first RRC configuration end message to the first terminal, and sends a second RRC configuration end message to the second terminal.
8. 根据权利要求 1所述的方法, 其中, 所述 eNB通过所述本地承载转发所述第一 终端和所述第二终端之间的业务数据以实现本地交换, 包括: 8. The method according to claim 1, wherein the eNB forwards the service data between the first terminal and the second terminal through the local bearer to implement local switching, including:
在接收所述第一终端发送的调用请求 SR信令后, 所述 eNB向所述第一终 端发送 UL grant信令, 其中, 所述 UL grant信令中携带所述第一终端发送所述 业务数据时使用的上行资源; After receiving the call request SR signaling sent by the first terminal, the eNB sends UL grant signaling to the first terminal, wherein the UL grant signaling carries the service sent by the first terminal. Uplink resources used for data processing;
所述 eNB通过空口接收来自所述第一终端的所述业务数据,并对所述业务 数据进行 PHY层、 MAC层及 RLC层的处理, 使所述业务数据到达 PDCP层; 所述 eNB为所述第二终端分配设置为在接收所述业务数据时使用的缓存; 所述 eNB通过所述缓存将所述业务数据发送给所述第二终端。 The eNB receives the service data from the first terminal through an air interface, and processes the service data at the PHY layer, MAC layer and RLC layer, so that the service data reaches the PDCP layer; the eNB is the The second terminal allocates a buffer set to be used when receiving the service data; and the eNB sends the service data to the second terminal through the buffer.
9. 根据权利要求 8所述的方法, 其中, 所述 eNB通过所述缓存将所述业务数据发 送给所述第二终端, 采用以下方式之一: 9. The method according to claim 8, wherein the eNB sends the service data to the second terminal through the cache, using one of the following methods:
方式一, 所述 eNB所述业务数据置于所述 PDCP层后, 通过所述缓存将发 送给所述第二终端; Method 1: After the service data of the eNB is placed in the PDCP layer, it will be sent to the second terminal through the cache;
方式二, 所述 eNB所述业务数据置于所述 PDCP层之上后, 通过所述缓存 将发送给所述第二终端; Method 2: After the eNB places the service data on the PDCP layer, it will be sent to the second terminal through the cache;
其中, 采用方式一进行数据发送时, 对所述业务数据进行加密处理, 包括: 当所述第一终端到所述 eNB的第一数据无线承载 DRB的上行数据包计数 值达到第一计数阈值时, 所述 eNB 向所述第一终端发送第一 Countercheck消 息以使所述第一终端按照 LTE流程对所述业务数据进行计数检查; Wherein, when the method 1 is used for data transmission, the service data is encrypted, including: when the uplink data packet count value of the first data radio bearer DRB from the first terminal to the eNB reaches the first counting threshold. , the eNB sends a first Countercheck message to the first terminal so that the first terminal counts and checks the service data according to the LTE process;
当所述第二终端到所述 eNB的第二数据无线承载 DRB的下行数据包计数 值达到第二技术阈值时, 所述 eNB 向所述第二终端发送第二 Countercheck消 息以使所述第二终端按照 LTE流程对所述业务数据进行计数检查。 When the downlink data packet count value of the second data radio bearer DRB from the second terminal to the eNB reaches the second technical threshold, the eNB sends a second Countercheck message to the second terminal so that the second The terminal performs counting and checking on the service data according to the LTE process.
10. 根据权利要求 1所述的方法, 其中, 在演进型基站 eNB协同所述第一终端和所 述第二终端建立本地承载之前, 所述方法还包括: 10. The method according to claim 1, wherein before the evolved base station eNB cooperates with the first terminal and the second terminal to establish a local bearer, the method further includes:
所述 eNB或分组数据网关 PGW判断是否能够进行本地交换。 The eNB or packet data gateway PGW determines whether local switching is possible.
11. 根据权利要求 10所述的方法, 其中, 所述 eNB判断是否能够进行本地交换, 包括: 11. The method according to claim 10, wherein the eNB determines whether local switching is possible, including:
在所述第一终端进行附着的过程中,所述 eNB接收移动管理实体 MME发 送的所述第一终端的 IP地址, 并保存所述第一终端的 IP地址; During the attachment process of the first terminal, the eNB receives the IP address of the first terminal sent by the mobility management entity MME, and saves the IP address of the first terminal;
在所述第二终端进行附着的过程中,所述 eNB接收所述 MME发送的所述 第二终端的 IP地址, 并保存所述第二终端的 IP地址; During the attachment process of the second terminal, the eNB receives the IP address of the second terminal sent by the MME, and saves the IP address of the second terminal;
当接收到所述第一终端发送的携带有所述第二终端的 IP 地址的本地交换 请求消息时, 所述 eNB判断本地是否已经保存了所述第二终端的 IP地址, 在 判断结果为是的情况下,确定所述第一终端和所述第二终端能够进行本地交换; 在判断结果为否的情况下, 所述 eNB向相邻 eNB查询所述相邻 eNB是否 已经保存了所述第二终端的 IP地址, 如果查询结果为是,确定所述第一终端和 所述第二终端能够进行本地交换, 如果查询结果为否, 确定所述第一终端和所 述第二终端不能进行本地交换。 When receiving the local switching request message carrying the IP address of the second terminal sent by the first terminal, the eNB determines whether the IP address of the second terminal has been saved locally, and when the determination result is yes In the case of , it is determined that the first terminal and the second terminal can perform local switching; if the judgment result is no, the eNB queries the neighboring eNB whether the neighboring eNB has saved the first The IP address of the second terminal. If the query result is yes, it is determined that the first terminal and the second terminal can perform local switching. If the query result is no, it is determined that the first terminal and the second terminal cannot perform local switching. exchange.
12. 根据权利要求 11所述的方法,其中,在确定所述第一终端和所述第二终端能够 进行本地交换的情况下, 包括: 12. The method of claim 11, wherein, in determining that the first terminal and the second terminal are capable of local switching, comprising:
所述 eNB向所述第一终端发送本地交换请求响应消息, 其中, 本地交换请 求响应消息用于指示所述第一终端能够与所述第二终端进行本地交换, 并启动 所述本地承载的建立流程。 The eNB sends a local switching request response message to the first terminal, where the local switching request response message is used to indicate that the first terminal can perform local switching with the second terminal and initiate the establishment of the local bearer. process.
13. 根据权利要求 10所述的方法, 其中, 所述 PGW判断是否能够进行本地交换, 包括: 13. The method according to claim 10, wherein the PGW determines whether local switching is possible, including:
在所述第一终端成功和所述第二终端附着成功后, 所述 PGW建立与所述 第一终端和所述第二终端之间的 LTE承载; 所述 PGW接收所述第一终端发送的业务数据, 其中, 所述业务数据中包 括: 所述第一终端的 IP地址和所述第二终端的 IP地址; After the first terminal is successfully attached and the second terminal is successfully attached, the PGW establishes an LTE bearer with the first terminal and the second terminal; the PGW receives the message sent by the first terminal. Service data, wherein the service data includes: the IP address of the first terminal and the IP address of the second terminal;
所述 PGW根据所述第一终端的 IP地址和所述第二终端的 IP地址,判断所 述第一终端和所述第二终端是否均位于所述 eNB下且所述 eNB支持本地交换 功能, 或者所述第一终端和所述第二终端是否分别位于所述 eNB和相邻 eNB 下且所述 eNB和所述相邻 eNB均支持本地交换功能, 如果判断结果为是, 确 定所述第一终端和所述第二终端能够进行本地交换, 如果判断结果为否, 确定 所述第一终端和所述第二终端不能进行本地交换。 The PGW determines, based on the IP address of the first terminal and the IP address of the second terminal, whether the first terminal and the second terminal are both located under the eNB and the eNB supports the local switching function, Or whether the first terminal and the second terminal are respectively located under the eNB and the adjacent eNB and both the eNB and the adjacent eNB support the local switching function. If the judgment result is yes, determine the first The terminal and the second terminal can perform local switching. If the judgment result is no, it is determined that the first terminal and the second terminal cannot perform local switching.
14. 一种终端的本地交换系统, 包括: 演进型基站 e B、 第一终端、 第二终端、 分 组数据网关 PGW、 服务网关 SGW以及移动管理实体 MME, 所述 eNB包括: 建立模块,设置为协同所述第一终端和所述第二终端建立本地承载,其中, 所述本地承载是指本地交换过程中需要使用的专用于设备到设备 D2D的承载; 转发模块, 设置为通过所述本地承载转发所述第一终端和所述第二终端之 间的业务数据以实现本地交换。 14. A local switching system for terminals, including: an evolved base station eB, a first terminal, a second terminal, a packet data gateway PGW, a serving gateway SGW, and a mobility management entity MME. The eNB includes: an establishment module, configured as Cooperate with the first terminal and the second terminal to establish a local bearer, where the local bearer refers to a bearer dedicated to device-to-device D2D that needs to be used in the local switching process; a forwarding module is configured to pass the local bearer Forwarding service data between the first terminal and the second terminal to implement local switching.
15. 根据权利要求 14所述的系统, 其中, 所述建立模块包括: 发起模块, 设置为在所述 PGW发起本地承载建立流程后, 分别向所述第 一终端和所述第二终端发起第一无线资源控制 RRC连接重配流程、第二无线资 源控制 RRC连接重配流程; 15. The system according to claim 14, wherein the establishment module includes: an initiating module, configured to initiate the first terminal and the second terminal respectively after the PGW initiates the local bearer establishment process. a radio resource control RRC connection reconfiguration process and a second radio resource control RRC connection reconfiguration process;
处理模块, 设置为在所述第一 RRC连接重配和所述第二 RRC连接重配均 成功的情况下, 确定所述本地承载的建立已经完成, 否则, 根据所述第一终端 和 /或所述第二终端反馈的建立失败消息, 重新向所述第一终端和 /或所述第二 终端发起 RRC连接重配流程, 直至完成所述本地承载的建立。 The processing module is configured to determine that the establishment of the local bearer has been completed if both the first RRC connection reconfiguration and the second RRC connection reconfiguration are successful; otherwise, according to the first terminal and/or the establishment failure message fed back by the second terminal, reinitiating the RRC connection reconfiguration process to the first terminal and/or the second terminal until the establishment of the local bearer is completed.
16. 根据权利要求 15所述的系统, 其中, 所述 PGW用于发起本地承载建立流程, 所述 PGW包括: 第一接收模块, 设置为接收所述第一终端发送的本地承载建立请求消息; 第一生成模块, 设置为为所述第一终端生成第一传输流模板 TFT, 并在所 述第一 TFT中增加本地交换的地址类型和所述第二终端的 IP地址, 其中, 所 述本地承载建立请求消息包括: 所述第一终端的 IP地址和所述第二终端的 IP 地址; 第二生成模块,设置为根据所述第二终端的 IP地址为所述第二终端生成第 二 TFT,并在所述第二 TFT中增加所述本地交换的地址类型和所述第一终端的 IP地址; 第三生成模块, 设置为生成第一本地承载建立消息, 其中, 第一本地承载 建立消息是从所述 PGW到所述 MME的消息, 所述本地承载建立消息包括: 所述第一终端的 IP地址、由所述第一 TFT和所述第二 TFT组成的本地交换 TFT 对, 以及服务质量 QoS参数; 第一发送模块, 设置为通过所述 SGW将所述第一本地承载建立消息发送 给所述 MME以使所述 MME根据所述第一本地承载建立消息生成第二本地承 载建立消息, 其中, 所述第二本地承载建立消息是从所述 MME到所述 eNB的 消息, 所述第二本地承载建立消息包括: 所述第一终端的第一 UE ID、 所述第 二终端的第二 UE ID、 所述第一终端的第一 E-RAB ID、 所述第二终端的第二 E-RAB ID, 以及所述 QoS参数。 16. The system according to claim 15, wherein the PGW is used to initiate a local bearer establishment process, and the PGW includes: a first receiving module configured to receive the local bearer establishment request message sent by the first terminal; The first generation module is configured to generate a first transport flow template TFT for the first terminal, and add a locally switched address type and an IP address of the second terminal to the first TFT, where, the local The bearer establishment request message includes: the IP address of the first terminal and the IP address of the second terminal; a second generation module configured to generate a second TFT for the second terminal according to the IP address of the second terminal , and add the address type of the local switch and the IP address of the first terminal to the second TFT; a third generation module, configured to generate a first local bearer establishment message, where, the first local bearer establishment message is a message from the PGW to the MME. The local bearer establishment message includes: the IP address of the first terminal, a locally switched TFT pair composed of the first TFT and the second TFT, and a service Quality QoS parameters; The first sending module is configured to send the first local bearer establishment message to the MME through the SGW so that the MME generates a second local bearer establishment message according to the first local bearer establishment message. , wherein the second local bearer establishment message is a message from the MME to the eNB, and the second local bearer establishment message includes: the first UE ID of the first terminal, the first UE ID of the second terminal the second UE ID, the first E-RAB ID of the first terminal, the second E-RAB ID of the second terminal, and the QoS parameters.
17. 根据权利要求 16所述的系统, 其中, 所述发起模块包括: 第一生成单元, 设置为根据所述第一 E-RAB ID生成所述第一终端到所述 eNB的第一数据无线承载 DRB, 并生成对应于所述第一 DRB的第一 DRB ID、 第一逻辑信道, 以及第一 LC ID, 其中, 所述第一 LC ID的保留值用于在进行 本地交换的过程中标识所述第一逻辑信道; 17. The system according to claim 16, wherein the initiating module includes: a first generating unit configured to generate a first data wireless link from the first terminal to the eNB according to the first E-RAB ID. Bear the DRB, and generate a first DRB ID, a first logical channel, and a first LC ID corresponding to the first DRB, where the reserved value of the first LC ID is used for identification during local switching. The first logical channel;
第二生成单元, 设置为生成对应于所述第一终端的第一 RRC 连接重配消 息, 其中, 所述第一 RRC连接重配消息包括: 所述第一 DRB ID、所述第一 LC ID以及对应于所述第一终端的第一 NAS消息,所述第一 NAS消息携带有所述 第一 TFT; 第一发送单元, 设置为向所述第一终端发送所述第一 RRC连接重配消息, 发起所述第一 RRC连接重配流程; The second generation unit is configured to generate a first RRC connection reconfiguration message corresponding to the first terminal, wherein the first RRC connection reconfiguration message includes: the first DRB ID, the first LC ID and a first NAS message corresponding to the first terminal, the first NAS message carrying the first TFT; The first sending unit is configured to send the first RRC connection reconfiguration message to the first terminal, and initiate the first RRC connection reconfiguration process;
第三生成单元, 设置为根据所述第二 E-RAB ID生成所述第二终端到所述 e B的第二数据无线承载 DRB, 并生成对应于所述第二 DRB的第二 DRB ID、 第二逻辑信道, 以及第二 LC ID, 其中, 所述第二 LC ID的保留值用于在进行 本地交换的过程中标识所述第二逻辑信道; The third generation unit is configured to generate a second data radio bearer DRB from the second terminal to the eB according to the second E-RAB ID, and generate a second DRB ID corresponding to the second DRB, a second logical channel, and a second LC ID, wherein the reserved value of the second LC ID is used to identify the second logical channel during local switching;
第四生成单元, 设置为生成对应于所述第二终端的第二 RRC 连接重配消 息, 其中, 所述第二 RRC连接重配消息包括: 所述第二 DRB ID、所述第二 LC ID, 以及对应于所述第二终端的第二 NAS消息, 所述第二 NAS消息携带有所 述第二 TFT; 第二发送单元, 设置为向所述第二终端发送所述第二 RRC连接重配消息, 发起所述第二 RRC连接重配流程; The fourth generation unit is configured to generate a second RRC connection reconfiguration message corresponding to the second terminal, wherein the second RRC connection reconfiguration message includes: the second DRB ID, the second LC ID , and a second NAS message corresponding to the second terminal, the second NAS message carries the second TFT; the second sending unit is configured to send the second RRC connection reconnection to the second terminal. configuration message, initiating the second RRC connection reconfiguration process;
其中, 所述第一 DRB 和所述第二 DRB 存在固定的绑定关系, 所述第一 DRB ID和所述第二 DRB ID存在固定的绑定关系,所述第一 DRB ID和所述第 二 DRB ID组成 DRB ID对。 Wherein, the first DRB and the second DRB have a fixed binding relationship, the first DRB ID and the second DRB ID have a fixed binding relationship, the first DRB ID and the third DRB ID have a fixed binding relationship. Two DRB IDs form a DRB ID pair.
18. 根据权利要求 17所述的系统, 其中, 所述第一终端包括: 第一绑定模块, 设置为在所述发起模块向所述第一终 端发起第一 RRC连接重配流程之后, 将所述第一 TFT绑定到所述第一 DRB, 并执行第一 RRC连接重配的其他操作; 所述第二终端包括: 第二绑定模块, 设置为在所述发起模块向所述第二终 端发起第二 RRC连接重配流程之后, 将所述第二 TFT绑定到所述第二 DRB, 并执行第二 RRC连接重配的其他操作。 18. The system according to claim 17, wherein the first terminal includes: a first binding module, configured to: after the initiating module initiates a first RRC connection reconfiguration process to the first terminal, The first TFT is bound to the first DRB, and performs other operations of first RRC connection reconfiguration; the second terminal includes: a second binding module, configured to send a message to the first DRB when the initiating module After the second terminal initiates the second RRC connection reconfiguration process, it binds the second TFT to the second DRB and performs other operations of the second RRC connection reconfiguration.
19. 根据权利要求 18所述的系统, 其中, 所述第一终端还包括:第二发送模块,设置为在所述第一 RRC连接重配成 功的情况下, 向所述 eNB发送第一 RRC连接重配完成消息; 19. The system according to claim 18, wherein the first terminal further includes: a second sending module configured to send the first RRC to the eNB when the first RRC connection reconfiguration is successful. Connection reconfiguration complete message;
所述第二终端还包括:第三发送模块,设置为在所述第二 RRC连接重配成 功的情况下, 向所述 eNB发送第二 RRC连接重配完成消息。 根据权利要求 19所述的系统, 其中, 所述建立模块还包括: 第四发送模块,设置为在接收到所述第一 RRC连接重配完成消息和所述第 二 RRC连接重配完成消息的情况下, 向所述第一终端发送第一 RRC配置结束 消息, 向所述第二终端发送第二 RRC配置结束消息。 The second terminal further includes: a third sending module configured to send a second RRC connection reconfiguration completion message to the eNB when the second RRC connection reconfiguration is successful. The system according to claim 19, wherein the establishment module further includes: The fourth sending module is configured to, upon receiving the first RRC connection reconfiguration complete message and the second RRC connection reconfiguration complete message, send a first RRC configuration end message to the first terminal, to The second terminal sends a second RRC configuration end message.
21. 根据权利要求 14所述的系统, 其中, 所述转发模块包括: 第二接收模块, 设置为接收所述第一终端发送的调用请求 SR信令; 第五发送模块, 设置为向所述第一终端发送 UL grant信令, 其中, 所述 UL grant信令中携带所述第一终端发送所述业务数据时使用的上行资源; 第三接收模块, 设置为通过空口接收来自所述第一终端的所述业务数据, 并对所述业务数据进行 PHY层、 MAC层及 RLC层的处理,使所述业务数据到 达 PDCP层; 分配模块, 设置为为所述第二终端分配用于在接收所述业务数据时使用的 缓存; 21. The system according to claim 14, wherein the forwarding module includes: a second receiving module configured to receive the call request SR signaling sent by the first terminal; a fifth sending module configured to send the call request to the first terminal. The first terminal sends UL grant signaling, wherein the UL grant signaling carries the uplink resources used by the first terminal when sending the service data; a third receiving module is configured to receive data from the first terminal through the air interface. The service data of the terminal, and the service data is processed at the PHY layer, MAC layer and RLC layer, so that the service data reaches the PDCP layer; the allocation module is configured to allocate to the second terminal for receiving The cache used for the business data;
第六发送模块,设置为通过所述缓存将所述业务数据发送给所述第二终端。 A sixth sending module is configured to send the service data to the second terminal through the cache.
22. 根据权利要求 21所述的系统,其中,所述第六发送模块通过所述缓存将所述业 务数据发送给所述第二终端, 采用以下方式之一: 22. The system according to claim 21, wherein the sixth sending module sends the service data to the second terminal through the cache, using one of the following methods:
方式一, 所述第六发送模块将所述业务数据置于所述 PDCP层后, 通过所 述缓存将发送给所述第二终端; Method 1: The sixth sending module places the service data in the PDCP layer and sends it to the second terminal through the cache;
方式二, 所述第六发送模块将所述业务数据置于所述 PDCP层之上后, 通 过所述缓存将发送给所述第二终端; 其中, 采用方式一进行数据发送时, 所述第六发送模块对所述业务数据进 行加密处理, 包括: Method 2: After the sixth sending module places the service data on the PDCP layer, it will be sent to the second terminal through the cache; wherein, when using method 1 to send data, the third The sixth sending module encrypts the business data, including:
当所述第一终端到所述 e B的第一数据无线承载 DRB的上行数据包计数 值达到第一计数阈值时, 所述第六发送模块向所述第一终端发送第一 Countercheck消息以使所述第一终端按照 LTE流程对所述业务数据进行计数检 查; When the uplink data packet count value of the first data radio bearer DRB from the first terminal to the eB reaches the first counting threshold, the sixth sending module sends a first Countercheck message to the first terminal to enable The first terminal performs counting and checking on the service data according to the LTE process;
当所述第二终端到所述 eNB的第二数据无线承载 DRB的下行数据包计数 值达到第二技术阈值时, 所述第六发送模块向所述第二终端发送第二 Countercheck消息以使所述第二终端按照 LTE流程对所述业务数据进行计数检 查。 When the downlink data packet count value of the second data radio bearer DRB from the second terminal to the eNB reaches the second technical threshold, the sixth sending module sends a second Countercheck message to the second terminal so that the The second terminal performs counting and checking on the service data according to the LTE process.
23. 根据权利要求 14所述的系统, 其中, 所述 e B还包括: 第一判断模块, 设置为在所述建立模块建立所述本地承 载之前, 判断是否能够进行本地交换; 或者, 23. The system according to claim 14, wherein the eB further includes: a first judgment module, configured to judge whether local switching can be performed before the establishment module establishes the local bearer; or,
所述 PGW还包括: 第二判断模块, 设置为在所述建立模块建立所述本地 承载之前, 判断是否能够进行本地交换。 The PGW also includes: a second judgment module configured to judge whether local switching can be performed before the establishment module establishes the local bearer.
24. 根据权利要求 23所述的系统, 其中, 所述第一判断模块包括: 第一接收单元,设置为在所述第一终端进行附着的过程中,接收所述 MME 发送的所述第一终端的 IP地址, 并保存所述第一终端的 IP地址; 24. The system according to claim 23, wherein the first judgment module includes: a first receiving unit configured to receive the first message sent by the MME during the attachment process of the first terminal. The IP address of the terminal, and save the IP address of the first terminal;
第二接收单元,设置为在所述第二终端进行附着的过程中,接收所述 MME 发送的所述第二终端的 IP地址, 并保存所述第二终端的 IP地址; The second receiving unit is configured to receive the IP address of the second terminal sent by the MME during the attachment process of the second terminal, and save the IP address of the second terminal;
第一判断单元, 设置为当接收到所述第一终端发送的携带有所述第二终端 的 IP地址的本地交换请求消息时,判断本地是否已经保存了所述第二终端的 IP 地址; 第一确定单元, 设置为在判断结果为是的情况下, 确定所述第一终端和所 述第二终端能够进行本地交换; The first judgment unit is configured to judge whether the IP address of the second terminal has been saved locally when receiving the local switching request message sent by the first terminal and carrying the IP address of the second terminal; a determination unit, configured to determine that the first terminal and the second terminal can perform local switching if the judgment result is yes;
查询单元, 设置为在判断结果为否的情况下, 向相邻 e B 查询所述相邻 e B是否已经保存了所述第二终端的 IP地址; 第二确定单元, 设置为当查询结果为是时, 确定所述第一终端和所述第二 终端能够进行本地交换, 当查询结果为否时, 确定所述第一终端和所述第二终 端不能进行本地交换。 The query unit is configured to query the neighboring eB whether the neighboring eB has saved the IP address of the second terminal when the judgment result is no; the second determination unit is configured to query the neighboring eB when the query result is When yes, it is determined that the first terminal and the second terminal can perform local switching; when the query result is no, it is determined that the first terminal and the second terminal cannot perform local switching.
25. 根据权利要求 24所述的系统, 其中, 所述 eNB还包括: 第七发送模块, 设置为在所述第一判断模块确定所述第一终端和所述第二 终端能够进行本地交换的情况下,向所述第一终端发送本地交换请求响应消息, 其中, 本地交换请求响应消息设置为指示所述第一终端能够与所述第二终端进 行本地交换, 并启动所述本地承载的建立流程。 25. The system according to claim 24, wherein the eNB further includes: a seventh sending module, configured to determine when the first judgment module determines that the first terminal and the second terminal can perform local switching. In this case, a local switching request response message is sent to the first terminal, where the local switching request response message is set to indicate that the first terminal can perform local switching with the second terminal and initiate the establishment of the local bearer. process.
26. 根据权利要求 23所述的系统, 其中, 所述第二判断模块包括: 建立单元, 设置为在所述第一终端成功和所述第二终端附着成功后, 建立 与所述第一终端和所述第二终端之间的 LTE承载; 第三接收单元, 设置为接收所述第一终端发送的业务数据, 其中, 所述业 务数据中包括: 所述第一终端的 IP地址和所述第二终端的 IP地址; 第二判断单元, 设置为根据所述第一终端的 IP地址和所述第二终端的 IP 地址, 判断所述第一终端和所述第二终端是否均位于所述 eNB 下且所述 eNB 支持本地交换功能, 或者所述第一终端和所述第二终端是否分别位于所述 eNB 和相邻 eNB下且所述 eNB和所述相邻 eNB均支持本地交换功能, 如果判断结 果为是, 确定所述第一终端和所述第二终端能够进行本地交换, 如果判断结果 为否, 确定所述第一终端和所述第二终端不能进行本地交换。 26. The system according to claim 23, wherein the second judgment module includes: an establishment unit, configured to establish a connection with the first terminal after the first terminal is successfully attached and the second terminal is successfully attached. LTE bearer between the second terminal and the second terminal; The third receiving unit is configured to receive the service data sent by the first terminal, wherein the service data includes: the IP address of the first terminal and the IP address of the second terminal; a second judgment unit, Set to determine whether the first terminal and the second terminal are both located under the eNB and the eNB supports a local switching function based on the IP address of the first terminal and the IP address of the second terminal, or Whether the first terminal and the second terminal are respectively located under the eNB and a neighboring eNB and both the eNB and the neighboring eNB support the local switching function. If the judgment result is yes, determine whether the first terminal and the second terminal can perform local switching. If the judgment result is no, it is determined that the first terminal and the second terminal cannot perform local switching.
PCT/CN2014/080344 2013-11-01 2014-06-19 Local exchange method and system of terminal WO2015062287A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201310538380.XA CN104618849A (en) 2013-11-01 2013-11-01 Local exchange method and system of terminal
CN201310538380.X 2013-11-01

Publications (1)

Publication Number Publication Date
WO2015062287A1 true WO2015062287A1 (en) 2015-05-07

Family

ID=53003262

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2014/080344 WO2015062287A1 (en) 2013-11-01 2014-06-19 Local exchange method and system of terminal

Country Status (2)

Country Link
CN (1) CN104618849A (en)
WO (1) WO2015062287A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP4207828A4 (en) * 2020-09-27 2023-09-20 Huawei Technologies Co., Ltd. Data communication method and communication apparatus

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2017028048A1 (en) 2015-08-14 2017-02-23 华为技术有限公司 Device-to-device (d2d) data transmission method, apparatus and system
KR20190002431A (en) * 2016-05-11 2019-01-08 광동 오포 모바일 텔레커뮤니케이션즈 코포레이션 리미티드 Communication method, terminal device and network device
EP3500043A4 (en) 2016-08-26 2019-09-04 Huawei Technologies Co., Ltd. Network management method and controller
CN109996306B (en) * 2017-12-29 2022-02-25 华为技术有限公司 Communication method and communication device
WO2020077574A1 (en) * 2018-10-17 2020-04-23 北京小米移动软件有限公司 Sidelink-based transmission method and device
WO2020191741A1 (en) 2019-03-28 2020-10-01 Oppo广东移动通信有限公司 Connection management method and apparatus, computer device and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101159905A (en) * 2007-11-07 2008-04-09 华为技术有限公司 Local exchange method, core network equipment and network system of implementing in base station controller
CN101754412A (en) * 2008-12-08 2010-06-23 中兴通讯股份有限公司 Method, equipment and system for implementing local exchange for base station group in GSM (global system for mobile communications)
CN101815358A (en) * 2009-02-24 2010-08-25 鼎桥通信技术有限公司 Data transmission method between user equipment
WO2012106932A1 (en) * 2011-07-26 2012-08-16 华为技术有限公司 Data exchange establishment method and device, data exchage method and device, and bearer node

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101835131B (en) * 2009-03-10 2012-12-12 华为技术有限公司 Method, device and system for local exchange of data
CN102088688B (en) * 2009-12-07 2014-01-22 华为技术有限公司 Information interaction control method
CN102843779B (en) * 2011-06-22 2017-03-22 中兴通讯股份有限公司 Method and device for establishing and processing connections

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101159905A (en) * 2007-11-07 2008-04-09 华为技术有限公司 Local exchange method, core network equipment and network system of implementing in base station controller
CN101754412A (en) * 2008-12-08 2010-06-23 中兴通讯股份有限公司 Method, equipment and system for implementing local exchange for base station group in GSM (global system for mobile communications)
CN101815358A (en) * 2009-02-24 2010-08-25 鼎桥通信技术有限公司 Data transmission method between user equipment
WO2012106932A1 (en) * 2011-07-26 2012-08-16 华为技术有限公司 Data exchange establishment method and device, data exchage method and device, and bearer node

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP4207828A4 (en) * 2020-09-27 2023-09-20 Huawei Technologies Co., Ltd. Data communication method and communication apparatus

Also Published As

Publication number Publication date
CN104618849A (en) 2015-05-13

Similar Documents

Publication Publication Date Title
WO2021159906A1 (en) Sidelink relay communication method and apparatus, device and medium
JP6718103B2 (en) Communication method
WO2018141284A1 (en) Method, device, and communication system for qos stream processing
WO2018028504A1 (en) Routing method and equipment
WO2018028694A1 (en) Communication method and device for direct device communication system, and communication system
WO2015062287A1 (en) Local exchange method and system of terminal
TWI804992B (en) Methods for signaling transmission in l2 ue via a network relay
JP5088091B2 (en) Base station apparatus, communication method, and mobile communication system
WO2013010420A1 (en) Wireless broadband communication method, device, and system
JP2014511168A (en) Mobile communication network and method
WO2013064104A1 (en) Data transmission method, mobility management entity and mobile terminal
EP3461216B1 (en) Multi-connection communication method and device
WO2013010418A1 (en) Method, apparatus and system for wireless broadband communication
WO2013097586A1 (en) Communication handover method, user equipment and base station
WO2014048224A1 (en) Method, device and system for transmitting data through control plane signaling
WO2012167743A1 (en) Method、user equipment and base station for interacting between wlan and wwan
WO2013075602A1 (en) Method, base station and user equipment for achieving carrier aggregation
WO2013117128A1 (en) Method for data transmission and reception, user equipment, base station and gateway
TW201735715A (en) Method and device for relay transmission and relay terminal equipment
CN110999382B (en) Method and apparatus for controlling packet duplication
WO2022001928A1 (en) Communication method and apparatus
WO2022001761A1 (en) Communication method and apparatus
WO2014153721A1 (en) Method and system for transmitting data packet, terminal device and network device
WO2019192492A1 (en) Indication method for requesting system information, and related device and system
WO2014032311A1 (en) Information transmission method and system for backhaul link, proxy device and access device

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 14857929

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 14857929

Country of ref document: EP

Kind code of ref document: A1