hlr lookup

What is HLR lookup? 

HLR lookup or phone number lookup is the process of getting real time mobile number information from the serving mobile operator for a mobile number. The real time information includes, roaming network,  mobile number portability and status. Mobile number is the MSISDN or Mobile Station International Subscriber Directory Number. The result of successful mobile number lookup have static information (IMSI) and dynamic information (visiting msc). IMSI  and MSISDN , provides number portability information. If IMSI and MSISDN belongs to same mobile operator, number is not ported else it is ported. Visiting MSC , provides the location of a subscriber. Roaming information have visiting country and mobile operator.

Network Elements for HLR lookup:

BTS : Base Transceiver Station is equipment or node in GSM network , having antenna for wireless connection between BTS and mobile device. Cell is the area covered by a BTS. A mobile phone connects to the BTS over a wireless channel.

BSC:  Base Station Control , controls the BTS and allocates the radio resources for a Mobile device. The handovers between cells are controlled by a BSC. Connection between BTS and BSC is a wired connection. A single BSC controls multiple BTS.

MSC in Telecom: Mobile Switching Center,  is the node which connects a wireless network to the rest of the PSTN. It holds the location, does billing  and do handovers between BSCs. A msc implements roaming/ messaging and call control protocols.

VLR: Visitor Location Register, is the database in roaming network. Which is mostly co located with a MSC. It maintains location and other services in roaming network. When a subscriber moves to other VLR, HLR removes the subscriber information from the previous VLR, by sending cancel location.

HLR: Home Location Register, is the database in home network of a mobile operators which controls the subscription of a mobile device. When a person gets a new sim card, the card is provisioned in HLR. The primary key for a subscriber in database is IMSI and MSISDN. The dynamic information is updated in hlr , when a sim card moves from one location to other or on device switchedon, home network gets updates for visiting VLR/MSC. if a subscriber is allowed to roam, HLR sends subscriber data to VLR.

RNC: Radio Network controller, is node between MSC and access antenna. RNC node standardized in 3G  network.

HLR lookup result:

When HLR returns success in result for a HLR lookup query for a MSISDN. Result contains following. 

  • IMSI of subscriber
  • Visiting MSC
  • MCC and MNC of roaming network.
  • Subscriber Status (Success/Failure).
  • Number Portability Information Can be derived by looking on IMSI and MSISDN.
  • Name of the mobile operator the current number belongs to.

When result is failure:

  • Subscriber is not configure for SMS Teleservice.
  • Subscriber is not attached.
  • Query Timeout.
  • SMS service is barred.
  • Protocol Level errors or provider errors.

Mobile Number Portability:

Mobile number portability is the process changing mobile operator without changing mobile number. In many places (e.g India) there are roaming charges with in country as well. So when some one locates from one place to other with in same country can do MNP with in same operator just to avoid roaming charges.  A new sim card is issues by the new mobile operator, sms for number portability request is sent to the original mobile operator. This process takes generally 2 to 3 days. The old sim card get deactivated and new ones get active.

Every country have MNP database (db). The db is accessible to all the mobile operators. When  an application initiates the hlr lookup query , the MNP db lookup is performed to get the serving HLR for the MSISDN.

Call Flow for phone number lookup :

The ss7/sigtran is the communication protocol between  HLR and  hlr lookup node of gateway. The lookup node initiates a GMS MAP 09.02 operation (SRI-SM) towards the HLR, the map operation have MSISDN as key parameter. When SRI-SM reaches to the HLR, the msisdn lookup is performed in database, if subscriber is configured and mobile phone is active or attached, IMSI and MSC number sends back to the lookup node in SRI-SM Response. The lookup node may be connected to all operators (according to coverage) directly or via an aggregator for ss7/sigtran connections. The node in ss7 network is identified by a global tiles (digits ) and point code. Both are allocated by standard GSM bodies. Every mobile operator is given a range of global title and imsi range.

hlr lookup call flow
hlr lookup call flow

Mobile phone attached procedure:

When a mobile phone is switched on in do following procedures.

  • Authentication, mobile device sends SendAuthenticationInformation operation over SS7  network from VLR to HLR. If subscriber is configured on HLR. The authentication information response is send to VLR. Key is the IMSI in authentication request.
  • Update Location,  After successful authentication, VLR sends the update location operation over SS7. Update location have IMSI, VLR and MSC as key parameters. HLR sends the subscription data (TeleService, GPRS data, Call Forwarding, Call Barring.  etc.) to the VLR for providing allowed services to the mobile user. After successful location update, hlr updateds the VLR and MSC in local database. This MSC number is sends back to the lookup node , in hlr lookup response.

Benefits from lookup:

  • Least Cost Routing:  As a result of lookup, the bulk sms service provider gets the location information (visiting country and visiting network). A low cost route or network connection provider can be chosen for sending sms to the mobile subscriber.
  • Marketing database cleanup:  While sending sms to a mobile , the subscriber may be not present permanently. To send this subscriber message again and again incur a cost and there is no outcome for business. HLR lookup service provides status code for a subscriber if lookup fails. If error is permanent failure ( e.g Unknown Subscriber) the database can be cleaned for this subscriber.
  • Billed the correct mobile operator, from lookup result, the mobile number portability information can be obtained. A lookup service provider can send CDRs for billing to the correct mobile operator.
  • Save cost, by using a more cleaned accurate mobile number database , a lookup service use can save cost. There are organizations e.g Colleges or Universities , do very regular messaging to thousands of alumni members. Lookup services cleans the database for inactive numbers , this saves thousand of dollars.
  • Real Time Information, Hlr Lookup , provides real time information for roaming, this enables the service user to plan advertisement according to the roaming places.
  • Used by Voip providers, A voip provider e.g Skype , can make a lookup before terminating call to the roaming device. The information collected can used to setup a low cost call route.
  • Get if a number is mobile or landline,  There are different formats for landline and mobile numbers, in some countries. But in many , the format is same. By just looking at digits can not say if a number is mobile or landline. Sending text to landline number have no use. Hlr lookup provides information if a number belongs to mobile or landline.

Location based content marketing, These days content marketing is very popular and effective. Advertisers want to reach people those are close to the business premises. Hlr lookup returns the current location of a mobile user. Content provider uses location information to advertise product effectively.   

HLR Lookup service provider:

There are companies providing HLR lookup services.  The lookup service can be access via API or from Web interface. The service provider exposes hlr lookup apis. The lookup service runs on a web domain or on public ip. A service user can access lookup server over internet.  To initiate a  lookup API from a software to the service platform. First an account on server should be created for service user.

The service platform check the details of user, using the hlr lookup API, if a user is allowed to use the service, provider does a hlr lookup on ss7 network, and sends result back to the service user.  Some times a SDK is provided to the user for easy to develop lookup service applications.

Cell Id lookup:

The sms service user always tries to get more and more accurate location for a mobile phone. A simple hlr lookup provides the information for roaming country and roaming area. Roaming area might be 20 kilometers wide. Which gives some idea for promoting location based contents, but still not so useful when content marketing is based of just nearby location. E.g sending a restaurant information which is just 500 meter away from a mobile user. For that a new parameter called cell id might be helpful.

Cell Id lookup may be provides additional parameter in hlr lookup result. Cell id gives the more accurate location information. On receiving cell id lookup, hlr has to perform a cell id get operation with the VLR.  VLR returns the LAC (location area code) and Cell (ID) along with MCC and MNC. Service provider can drive approx location coordinates from cell id and other parameters.

Cell Id lookup call flow:

SS7 MAP level,  the lookup nodes sends the ATI or Any Time Interrogation  GSM MAP 09:02 operation to the HLR. HLR sends the PSI or provide subscriber info , to the VLR. On success , the VLR sends the cell id in response of PSI, the cell id information, is relayed to the lookup node in ATI response.

IMSI Lookup: 

IMSI lookup is the process of getting IMSI from a mobile number. IMSI provides full information  about the mobile operator and subscriber.  Next step for a lookup service provider,  should have access to the MCC and MNC database.  One can offer imsi lookup service by using a hlr lookup service and access to the mcc and mnc database.

Hlr lookup service selection:

Once you have decided that you need the lookup service.  There are many hlr lookup service provides , whom to choose? Following are the parameters  which helps you to decide to choose a service provide.

Coverage :

The most important thing is the coverage. E.g if you want to provide your services to the Indian mobile users. But a hlr lookup provider do not have coverage in India, then do not choose this vendor.

Now have coverage in India, next check if all mobile operators are covered with in India , if no then check for other service providers.

Delivery Report :

Delivery report is very important for the end user. Check is service provider conveys the correct error code in the  lookup apis response.  This helps you to design your business logic more accurate.

Sigtran and HLR lookup:

Sigtran is ss7 signaling over ip. Before the sigtran, there was only ss7 link (E1 /T1)  were available for Hlr lookup. Links were deployed by the MNO to connect its infrastructure or premises. A service provider needs to put the box in mobile network operator (MNO) premises for the service. This causes to deploy at least one box for each MNO.   Cause to much expense and results in costly service.  With sigtran , a service provider can set its hlr lookup box in his office and can connect to multiple MNOs from same box.  This reduces the time and money.  Sigtran uses SCTP protocol over IP.

VLR Lookup:

In start we have discusses that what is VLR in telecom.  Here we will discuss about the VLR lookup.  VLR lookup returns.  The roaming information which is useful for routing ss7 signaling in optimization way. There are vlr lookup providers for the service. There are apis those take input as MSISDN and returns VLR information.

 

Mcc Mnc lookup:

In above we have mentioned that , the hlr lookup returns the IMSI and roaming information.  From result , MCC and MNC can be derived.  Service providers uses Mcc Mnc lookup for number portability. For example , if a number has been ported. The service provide will use MCC and MNC to send the message to the correct HLR.  In case of MNP mcc mnc lookup can be also performed from a MNP data base.

 

 

 

 

 

 

 

 

 

 

 

 

1 thought on “hlr lookup”

Leave a Comment

Your email address will not be published. Required fields are marked *