Wireless Networks and Mobile Computing: B Tech IV Year I Semester (JNTUH-R15) Prepared

Download as pdf or txt
Download as pdf or txt
You are on page 1of 262

INSTITUTE OF AERONAUTICAL ENGINEERING

(Autonomous)

Dundigal, Hyderabad - 500 043

DEPARTMENT OF INFORMATION TECHNOLOGY

WIRELESS NETWORKS AND MOBILE


COMPUTING
B Tech IV Year I Semester (JNTUH-R15)
Prepared
by
Mr. E. Sunil Reddy
Assistant Professor, IT

1
UNIT– I
• Introduction to Network Technologies and Cellular
Communications
• HIPERLAN: Protocol Architecture, Physical Layer, Channel-
Access Control sub-layer, MAC sub layer, Information Bases
and Networking
• WLAN: Infrared vs. Radio Transmission, Infrastructure and Ad
Hoc Networks, IEEE 802.11. Bluetooth; User Scenarios,
Physical Layer, MAC Layer, Networking, Security, Link
Management.
• GSM: Mobile Services, System Architecture, Radio Interfaces,
Protocols, Localization, Calling, Handover, Security, New Data
Services.
• Mobile Computing(MC): Introduction to MC, Novel
Applications, Limitations and Architecture. 2
Syllabus

 Mobile Communication
Mobile Computing
 Navel Applications
 Location dependent services
 Effects of device portability
 Wireless n/w‘s in comparison with fixed n/w‘s
 Limitations
 Architecture (simple reference model)

3
Goal of Mobile Computing

 People and their machines should be able to access


information and communicate with each other easily and
securely, in any medium or combination of media
– voice, data, image, video, or multimedia
– any time, anywhere, in a timely, cost-effective way.

4
Mobile Computing
• Mobile computing refers to computing in a distributed
system in which some processes or processors can move.
– Moving processes  logical mobility, realized by
agents.
– Moving processors  physical mobility, realized by
moving devices.
• Mobile computing extends a distributed computing
environment with a new dimension of mobility.
– Most existing mobile computing systems are based on
client-server computing systems.
– Recent mobile computing solutions consider general
distributed computing, namely, peer-to-peer computing
environments.
• Many mobile computing techniques have their root in
distributed systems. 5
Distributed system
• Definition:
– A distributed system consists of a collection of autonomous
computers, connected through a network and distribution
middleware, which enables computers to coordinate their
activities and to share the resources of the system, so that
users perceive the system as a single, integrated computing
facility.
• Multiple autonomous components
• Components are not shared by all users
• Resources may not be accessible
• Software runs in concurrent processes on different processors

6
• The process of computation on a mobile device
• In mobile computing, a set of distributed computing
systems or service provider servers participate, connect, and
synchronize through mobile communication protocols
• Mobile computing as a generic term describing ability to
use the technology to wirelessly connect to and use
centrally located information and/or application software
through the application of small, portable, and wireless
computing and communication devices

7
• Provides decentralized (distributed) computations on
diversified devices, systems, and networks, which are
mobile, synchronized, and interconnected via mobile
communication standards and protocols.
• Mobile device does not restrict itself to just one application,
such as, voice communication
• Offers mobility with computing power
• Facilitates a large number of applications on a single device

8
Mobile Communication
• User Mobility:
– Refers to a user who has access to the same or similar
telecommunication services at different places.
– user mobility: users communicate (wireless) ―anytime,
anywhere, with anyone‖
• Device Portability:
– The communication device moves with or without the user
– device portability: devices can be connected anytime,
anywhere to the network
• A communication device can the exhibit one of the following
characteristics:
– Fixed and wired e.g. Typical desktops computer
– Mobile and wired e.g. some laptops
– Fixed and wireless e.g. WIRELESS LANS 9
– Mobile and wireless e.g. Mobile phones
Mobility Issues
• Bandwidth restrictions and variability
• Location-aware network operation
– User may wake up in a new environment
– Dynamic replication of data
• Querying wireless data & location-based responses
• Busty network activity during connections & handling
disconnections
• Disconnection
– OS and File System Issues - allow for disconnected
operation
– Database System Issues - when disconnected, based on local
data
10
Portability Issues
• Battery power restrictions
• Risks to data
- Physical damage, loss, theft
- Unauthorized access
- encrypt data stored on mobiles
- Backup critical data to fixed (reliable) hosts
• Small user interface
- Small displays due to battery power and aspect ratio
constraints
- Cannot open too many windows
- Difficult to click on miniature icons
- Input - Graffiti, (Dictionary-based) Expectation
- Gesture or handwriting recognition with Stylus Pen Voice
matching or voice recognition 11
Evolutions of the Mobile Systems
1G Analog systems
2G systems
voice communication
Circuit Switched
2.5G systems
Circuit switching for voice
Packet switching for data
3G systems
Packet switching for voice and data
High speed
Compatible with different access technologies

12
Evolutions of the Mobile Systems
3.5G systems
Evolved Radio Interface
IP based core Network
Compatible with different access technologies
4G systems
New Air Interface
Very High bit rate services
Convergence of Wireline, Wireless, and IP worlds

13
Evolutions of the Mobile Systems

2G EARLY 3G LATE 3G 4G
(2 0 0 0 ) (2 0 0 1 ) (2 0 0 3 ) (2 0 0 5 )
A I R IN T E R F A C E

V O IC E C IR C U I T C IR C U I T C IR C U I T

PACKET
DATA C IR C U I T PACKET PACKET

ACCESS NETW K

V O IC E C IR C U I T C IR C U I T
PACKET PACKET

DATA C IR C U I T C IR C U I T

CORE NETW K

V O IC E C IR C U I T
PACKET PACKET PACKET

OVERLAY
DATA 14
PACKET
APPLICATIONS OF MOBILE COMPUTING
Music, news, road conditions, weather reports, and other broadcast
information are received via digital audio broadcasting (DAB) with
1.5 Mbit/s.
For personal communication, a universal mobile
telecommunications system (UMTS) phone might be available
offering voice and data connectivity with 384 kbit/s.
The current position of the car is determined via the global
positioning system (GPS). In case of an accident, not only will the
airbag be triggered, but the police and ambulance service will be
informed via an emergency call to a service provider. Buses, trucks,
and trains are already transmitting maintenance and logistic
information to their home base, which helps to improve
organization (fleet management), and saves time and money.
15
Emergencies: An ambulance with a high-quality wireless
connection to a hospital can carry vital information about injured
persons to the hospital from the scene of the accident. All the
necessary steps for this particular type of accident can be prepared
and specialists can be consulted for an early diagnosis. Wireless
networks are the only means of communication in the case of
natural disasters such as hurricanes or earthquakes. In the worst
cases, only decentralized, wireless ad-hoc networks survive.
Business: Managers can use mobile computers say, critical
presentations to major customers. They can access the latest
market share information. At a small recess, they can revise the
presentation to take advantage of this information.
A travelling salesman today needs instant access to the company‘s
database: to ensure that files on his or her laptop reflect the current
situation, to enable the company to keep track of all activities of
16
their travelling employees, to keep databases consistent etc.
Cellular Subscriber (Sept-2008)

17
Limitations of the Mobile Environment
• Limitations of the Wireless Network
– heterogeneity of fragmented networks
– frequent disconnections
– limited communication bandwidth
– Interference: the quality of service (QoS)
– Bandwidth: connection latency
• Limitations Imposed by Mobility
– lack of mobility awareness by system/applications
– route breakages
– Dynamic changes in communication environment: variations in
signal power within a region, thus link delays and connection
losses
• Limitations of the Mobile Computer
– short battery lifetime
18
– limited capacities
Simple Reference Model

19
Layer functionality

20
Introduction to GSM

Global System for Mobile (GSM) is a second generation cellular


standard developed to cater voice services and data delivery using
digital modulation

21
• Developed by Group Spéciale Mobile (founded 1982) which was an
initiative of CEPT ( Conference of European Post and Telecom )
• Aim : to replace the incompatible analog system
• Presently the responsibility of GSM standardization resides with special
mobile group under ETSI (European telecom Standards Institute )
• GSM have 124 duplex channels, each 200Khz wide, are used for
FDMA.
• GSM offer data rates of up to 9.6Kbps and up to a speed of 250Km/hr
• Under ETSI, GSM is named as ― Global System for Mobile
communication ―
• Today many providers all over the world use GSM (more than 190
countries in Asia, Africa, Europe, Australia, America)
• More than 1300 million subscribers in world & 45 million subscriber in
India. 22
GSM Developments
GSM 900
Mobile to BTS (uplink): 890-915 Mhz
BTS to Mobile(downlink):935-960 Mhz
GSM 1800 (DCS – Digital Cellular System)
Mobile to BTS (uplink): 1710-1785 Mhz
BTS to Mobile(downlink) 1805-1880 Mhz
GSM 1900 (PCS – Personal Communication Service)
Mobile to BTS (uplink): 1850-1910 Mhz
BTS to Mobile(downlink) 1930-1990 Mhz

23
GSM in World

Figures: March, 2005 Arab World

3% Asia Pacific
3%
3% Africa
3% (INDIA)
East Central Asia
4% 37% Europe
Russia
43% 4% India
1%
North America
South America24
GSM in India

Figures: March 2005


Reliance
3%
Spice MTNL Bharti
Aircel
4% 2% BSNL
4% Bharti
27% Hutch
BPL
6% IDEA
BPL
IDEA Aircel
13%
BSNL Spice
Hutch 22% Reliance
19%
MTNL
25
Mobile Services

• Tele-services
• Bearer or Data Services
• Supplementary services

26
Tele Services

• Telecommunication services that enable voice communication


via mobile phones
• Offered services
- Mobile telephony
- Emergency calling

27
Bearer Services
• Include various data services for information transfer between
GSM and other networks like PSTN, ISDN etc at rates from 300
to 9600 bps
• Short Message Service (SMS)
–up to 160 character alphanumeric data transmission to/from the
mobile terminal
• Unified Messaging Services(UMS)
• Group 3 fax
• Voice mailbox
• Electronic mail

28
Supplementary Services
Call related services :
• Call Waiting- Notification of an incoming call while on the
handset
• Call Hold- Put a caller on hold to take another call
• Call Barring- All calls, outgoing calls, or incoming calls
• Call Forwarding- Calls can be sent to various numbers defined
by the user
• Multi Party Call Conferencing - Link multiple calls together
• CLIP – Caller line identification presentation
• CLIR – Caller line identification restriction
• CUG – Closed user group
29
GSM System Architecture PSTN
ISDN
BSC PDN
MS BTS
MSC
GMSC

BTS BSC
VLR
MS

BTS EIR
AUC
MS HLR
30
31
Components
• Mobile Station (MS)
Mobile Equipment (ME)
Subscriber Identity Module (SIM)
• Base Station Subsystem (BSS)
Base Transceiver Station (BTS)
Base Station Controller (BSC)
• Network Switching Subsystem(NSS)
Mobile Switching Center (MSC)
Home Location Register (HLR)
Visitor Location Register (VLR)
Authentication Center (AUC)
Equipment Identity Register (EIR)
32
Mobile Station (MS)
The Mobile Station is made up of two entities:
1. Mobile Equipment (ME)
2. Subscriber Identity Module (SIM)

Mobile Equipment
• Portable,vehicle mounted, hand held device
• Uniquely identified by an IMEI (International Mobile
Equipment Identity)
• Voice and data transmission
• Monitoring power and signal quality of surrounding cells
for optimum handover
• Power level : 0.8W – 20 W
• 160 character long SMS.
33
Subscriber Identity Module (SIM)
• Smart card contains the International Mobile Subscriber Identity
(IMSI)
• Allows user to send and receive calls and receive other
subscribed services
• Encoded network identification details
- Key Ki, Kc and A3,A5 and A8 algorithms
• Protected by a password or PIN
• Can be moved from phone to phone – contains key information
to activate the phone

34
Base Station Subsystem (BSS)
Base Station Subsystem is composed of two parts that
communicate across the standardized Abis interface allowing
operation between components made by different suppliers
1. Base Transceiver Station (BTS)
2. Base Station Controller (BSC)

1. Base Transceiver Station (BTS):


• Encodes, encrypts, multiplexes, modulates and feeds the RF
signals to the antenna.
• Frequency hopping
• Communicates with Mobile station and BSC
• Consists of Transceivers (TRX) units
35
2. Base Station Controller (BSC)

• Manages Radio resources for BTS


• Assigns Frequency and time slots for all MS‘s in its area
• Handles call set up
• Transcoding and rate adaptation functionality
• Handover for each MS
• Radio Power control
• It communicates with MSC and BTS

36
Network Switching Subsystem(NSS)
Mobile Switching Center (MSC)

• Heart of the network


• Manages communication between GSM and other networks
• Call setup function and basic switching
• Call routing
• Billing information and collection
• Mobility management
- Registration
- Location Updating
- Inter BSS and inter MSC call handoff
• MSC does gateway function while its customer roams to other
network by using HLR/VLR.

37
Home Location Registers (HLR)
- permanent database about mobile subscribers in a
large service area(generally one per GSM network
operator)
- database contains IMSI, MSISDN, prepaid/postpaid,
roaming restrictions, supplementary services.
Visitor Location Registers (VLR)
- Temporary database which updates whenever new
MS enters its area, by HLR database
- Controls those mobiles roaming in its area
- Reduces number of queries to HLR
- Database contains IMSI, TMSI, MSISDN, MSRN,
Location Area, authentication key
38
Authentication Center (AUC)
- Protects against intruders in air interface
- Maintains authentication keys and algorithms and
provides security triplets ( RAND, SRES,Kc)
- Generally associated with HLR
Equipment Identity Register (EIR)
- Database that is used to track handsets using the
IMEI (International Mobile Equipment Identity)
- Made up of three sub-classes: The White List, The
Black List and the Gray List
- Only one EIR per PLMN

39
Radio Interface (Um)
• Air Interface: MS to BTS
• Uplink/Downlink of 25MHz
– 890 - 915 MHz for Up link
– 935 - 960 MHz for Down link
• Combination of frequency division and time division
multiplexing
– FDMA - 124 channels of 200 kHz
– TDMA - Burst
• Modulation Method : GMSK (Gaussian Minimum Shift Keying
) @ 270.833 Kbps

40
FDMA/TDMA

41
Physical Channel

42
GSM-Frame Structure

43
Logical Channels
Half rate 11.4kbps
Speech
TCH
(traffic) Full rate 22.8kbps
Data 2.4 kbps
4.8 kbps
9.6 kbps
BCH FCCH(Frequency correction)

SCH(Synchronization)
PCH(Paging)
CCCH
RACH(Random Access)
CCH AGCH(Access Grant)
(control)
Dedicated SDCCH(Stand Alone)
SACCH(Slow-associated)
FACCH(Fast-associated) 44
BCCH
• BTS to MS
• send cell identities, organization info about common
control channels, cell service available, etc
• Radio channel configuration
• Current cell + Neighbouring cells
• Synchronizing information
• Frequencies + frame numbering
• Registration Identifiers
• LA + Cell Identification (CI) + Base Station Identity
Code

45
BCCH Sub-Channels
• Frequency Correction Channel
• send a frequency correction data burst containing all
zeros to effect a constant frequency shift of RF carrier
– Mobile station knows which frequency to use
– Repeated broadcast of Frequency Bursts

• Synchronization Channel
• send TDMA frame number and base station identity
code to synchronize MSs
– MS knows which timeslot to use
– Repeated broadcast of Synchronization Bursts

46
CCC
• Access Grant Channel (AGCH)
• BTS to MS
• Used to assign an SDCCH/TCH to MS
• Paging Channel (PCH)
• BTS to MS
• Page MS
• Random Access Channel (RACH)
• MS => BTS
• Slotted Aloha
• Request for dedicated SDCCH
47
DCCH
• bidirectional point-to-point -- main signaling channels
• SDCCH (stand-alone dedicated control channel): for
service request, subscriber authentication, equipment
validation, assignment to a traffic channel
• SACCH (slow associated control channel): for out-of-
band signaling associated with a traffic channel, eg,
signal strength measurements
• FACCH (fast associated control channel): for
preemptive signaling on a traffic channel, eg, for
handoff messages
• Uses timeslots which are otherwise used by the
TCH

48
Localization and Calling
• Localization means same phone number is valid worldwide
• Periodic location updates
• VLR informs the HLR about MS location changes
• Changing VLRs with uninterrupted availability of all services
called Roaming
• To locate and address to the MS, GSM needs
– MSISDN, MSRN
– IMSI, TMSI
• Two ways of calling:
– Call Originating from MS (MOC)
– Call termination to MS (MTC)

49
Outgoing Call (MOC)
1. MS sends dialled number to BSS
2. BSS sends dialled number to
MSC
3,4 MSC checks VLR if MS is
allowed the requested service.If
so,MSC asks BSS to allocate
resources for call.
5 MSC routes the call to GMSC
6 GMSC routes the call to local
exchange of called user
7, 8,
9,10 Answer back(ring back) tone
is routed from called user to MS
via GMSC,MSC,BSS 50
Incoming Call 1. Calling a GSM
subscribers
(MTC) 2. Forwarding call to
GSMC
3. Signal Setup to HLR
4. 5. Request MSRN
from VLR
6. Forward responsible
MSC to GMSC
7. Forward Call to
current MSC
8. 9. Get current status of
MS
10.11. Paging of MS
12.13. MS answers
14.15. Security checks51
16.17. Set up connection
HANDOVER
• Single cell do not cover the whole service area
• Smaller the cell size, faster the movement of MS, but more
handovers
• However, a handover should not cause a cut-off
• Two reasons to use handover
– Maintain same quality of radio link at receiver
– Load balancing

52
Handover Scenario

• Within 1 – Intra Cell


• Between 1 and 2 – Inter
BTS / Intra BSC
• Between 1 and 3 –
Inter BSC/ Intra MSC
• Between 1 and 4 –
Inter MSC

53
GSM networks various security features
• A wireless radio based network system quite sensitive to the
unauthorized use of resources
• GSM employ various security features designed to :
Designed to protect subscriber privacy
Secured network against misuse of resources by
unregistered users

54
GSM networks various security features
• Controlled access to the network by Mobile station
• Required to use a PIN before it can access the network through
Um interface

55
Security in GSM
• Security Services:
– Access Control and Authentication
– Confidentiality : all user data encrypted
– Anonymity: not disclosed user identity
• GSM Uses the information stored in AuC and SIM
• SIM protected data with PIN against unauthorized use.
• 3 algorithms are specified :
- A3 algorithm for authentication
- A5 algorithm for encryption
- A8 algorithm for key generation

56
Authentication
• An AuC (authentication centre) for the operation and maintenance
subsystem of the GSM network
• Authentication of the Mobile station
• The AuC first authenticates the subscriber Mobile station and
only then does the MSC provide the switching service to another
terminal TE

57
Authentication algorithm
• Use a random number sent by the AuC during the connection set
up
• An authentication key which is already saved in the SIM
• Authentication algorithm used differs for different mobile
service provider

58
AuC sending random number for BTS and
BTS sending cipher key for encryption
Cipher key
for Mobile
station

For BTS
a Random
Number

59
Authentication in GSM

60
IMSI and TMSI of the Mobile station

• Its public identity


• TMSI is the identity granted on moving to a particular
location
• When a Mobile station moves to a new location area, the
VLR (visitor location register) assigns a TMSI which is
stored in the SIM of the Mobile station

61
TMSI
• The identification of the subscriber during communication done
not using the IMSI but the TMSI
• The VLR assigned TMSI generates that ID
• This protects the Mobile station against eavesdropping from
external sources

62
Encryption

• The BTS and the Mobile station perform ciphering before call
initiation or before connecting for receiving a call
• The Mobile station uses a cipher (encryption key) for encryption

63
The cipher

• A result of performing mathematical operations on (a) the cipher


key saved in the SIM and (b) the cipher number received from
the BTS when the call setup is initiated
• The BTS transmits the cipher number before a call is set up or
transmitted

64
Encryption

65
Advantages of GSM over Analog system

• Capacity increases
• Reduced RF transmission power and longer battery life.
• International roaming capability.
• Better security against fraud (through terminal validation and
user authentication).
• Encryption capability for information security and privacy.
• Compatibility with ISDN, leading to wider range of services

66
New Data Services: HSCSD
• High Speed Circuit Switched Data (HSCSD)
– Combined several GSM 9.6 Kbps channels to increase
bandwidth
– It allocates several TDMA slots within a TDMA frame
– In theory, an MS could use all 8 slots within a TDMA frame to
achieve an Air Interface User Rate (AIUR).
– Only requires software upgrades in an MS and MSC
• HSCSD exhibits some major limitations
– Still uses connection-oriented mechanism
– Not efficient for bursty and asymmetrical traffic
– Charged based on channels allocated

67
New Data Services: GPRS
• General Packet Radio Service (GPRS) features:
– It is a 2.5G system, is poised to take off this year in popularity.
– Building on the GSM network, it will provide the much needed
packet data services to most areas of the world.
– Useful for frequent small volume or infrequent small/medium
volume of data
– Time slots are not allocated in a fixed or pre-determined
manner, but on demand
– Allow broadcast, multicast and unicast service
– ―Always On‖, no connection has to be setup prior to data
transfer
– Resources are reserved only when needed and charged
accordingly
68
GPRS [2]
• It offers point-to-point packet transfer in 2 versions
– PTP connection-oriented service (PTP-CONS)
– PTP connectionless service (PTP-CNLS)

• It also offers Multicasting, called Point-to-Multipoint (PTM)


service

• User specify QoS profile


– Service precedence (high, normal, low)
– Reliability class
– Delay class
– Peak throughput class for data
– Mean throughput class for data

69
GPRS Architecture

SGSN Other GPRS


Gn PLMN

Gn GGSN
Gn
SGSN
BSC Gb

BTS Gi
GGSN PDN

BTS HLR/GR
MS
EIR MSC/VLR

PLMN : GSM Public Land Mobile N/w


PDN: Public Data Network
70
Entities
• The Serving GPRS Support Node (SGSN)
– Mobility Management
– Authentication
– Requests user information from the GPRS Register (GR)
– Gathers Charging Information
• Gateway GPRS Support Node (GGSN)
– Gateway between UMTS Core Network and external
networks
– Address allocation for MS
– Gathers Charging Information
– Filtering
• Base Station Subsystem (BSS) : BSC, BTS

71
Physical Layer = L1
PLL+RFL = Radio
GMSK= Gaussian minimum shift keying 72
Top Layer = IP/X.25
Layer Functionalities
• All data within GPRS backbone (b/w GSNs), is transferred using the
GTP (GPRS Tunneling Protocol).
• GTP can uses two transport protocol TCP and UDP.
• The N/w protocol for the GPRS backbone is IP.
• The Sub Network Dependent Convergence Protocol (SNDCP) used to
adapt different characteristics of the underlying n/ws b/w an MS and
SGSN.
• On top of SNDCP and GTP, user data packet is tunneled from the MS
to the SGSN and vice versa.
• To achieve a high reliability of packet transfer b/w SGSN and MS, a
special LLC is used, which compute ARQ and FEC.
• A Base Station Subsystem GPRS Protocol (BSSGP) is used to convey
routing and QoS related info b/w BSS and SGSN.
• BSSGP does not perform error correction and works on the top of
frame relay (FR),
• The Radio Link Control (RLC) provides a reliable link, while MAC 73
controls access with signaling procedure for radio channel.
Future Of GSM
2nd Generation
 GSM -9.6 Kbps (data rate)

2.5 Generation ( Future of GSM)


HSCSD (High Speed ckt Switched data)
Data rate : 76.8 Kbps (9.6 x 8 kbps)
GPRS (General Packet Radio service)
Data rate: 14.4 - 171.2 Kbps
EDGE (Enhanced data rate for GSM Evolution)
Data rate: 547.2 Kbps (max)
 3 Generation
WCDMA(Wide band CDMA)
Data rate : 0.348 – 2.0 Mbps
74
UNIT-II

75
Syllabus

Wireless Medium Access Control (MAC)


Motivation for a specialized MAC(Hidden and exposed terminals.
Near and far terminals), SDMA, FDMA, TDMA, CDMA, Wireless
LAN (IEEE802.11)., Collision Avoidance(MACA, MACAW)
protocols.

76
1. Motivation for Specialized MAC

77
78
79
MULTIPLEXING
• A fundamental mechanism in communication system and
networks
• Enables multiple users to share a medium
• For wireless communication, multiplexing can be carried out in
four dimensions: space, time, frequency and code

80
Access Methods

81
2. Space Division Multiple Access (SDMA)
• Channels are assigned on the basis of ―space‖ (but operate on
same frequency)
• The assignment makes sure that the transmission do not interfere
with each (with a guard band in between)

82
83
3. FDMA: Frequency Division Multiple Access

1. Frequency domain is subdivided into several non-overlapping


frequency bands
2. Each channel is assigned its own frequency band (with guard
spaces in between)

84
85
3. TDMA : Time Division Medium Access

• A channel is given the whole bandwidth for a certain amount of


time
– All senders use the same frequency, but at different point of
time
• Synchronization can be done by using
– Fixed Allocation Scheme or
– Dynamic Allocation Scheme

86
87
88
Reservation Algorithms

89
Packet Reservation Multiple Access (PRMA)
/ Implicit Reservation

90
Carrier Sense Multiple Access Protocols
(CSMA)
• In this each terminal on the network is able to monitor the status
of the channel before transmitting information
• Variations:
– 1-persistent CSMA
– non-persistent CSMA -
– p-persistent CSMA
– CSMA/CA
– Elimination yield – non-preemptive multiple access (EY-
NMPA)

91
Multiple Access with Collision Avoidance
(MACA)

92
93
POLLING

94
Inhibit Sense Multiple Access (ISMA)

95
4. CDMA: Code Division Multiple Access
 separation of channels achieved by assigning each
channel its own code
 guard spaces are realized by having distance in code
space (e.g. orthogonal codes)
 transmitter can transmit in the same frequency band
at the same time, but have to use different code
 Provides good protection against interference and
tapping
 but the receivers have relatively high complexity.

96
Spread Aloha Multiple Access (SAMA)

97
Comparisons of S/T/F/CDMA

98
Mobile Network Layer
CONTENTS
1. Mobile IP
i) Goals, Assumptions &
Requirements
ii) Entities and Terminology
iii) IP Packet Delivery
iv) Agent Advertisement &
Discovery
v) Registration
vi) Tunneling & Encapsulation
vii) Optimizations
2. DHCP
i) Basic Configuration
ii) Client Initialization 99
Goal of Network Layer
• Goal of Routing Protocols
– decrease routing-related overhead
– find short routes
– find ―stable‖ routes (despite mobility)

• Goal of Mobile IP
– Supporting end-system mobility while maintaining scalability,
efficiency and compatibility in all respects with existing
systems.

100
Mobile IP : Motivation
• Traditional routing
– based on IP address; network prefix determines the subnet
– change of physical subnet implies
• change of IP address (conform to new subnet), or
• special routing table entries to forward packets to new
subnet

101
Quick Solution
• Changing of IP address
– Use DHCP to have a new IP address when mobile device
moves to a new subnet, but then the new address may not be
known to anyone
– Take help of DNS to update the entry, but DNS updates
take long time
– TCP connections break
– security problems
• Changing entries in routing tables
– change routing table entries as the Mobile Node moves from
one network to another does not scale with the number of
mobile hosts and frequent changes in the location
– security problems

102
Requirements
• Compatibility
– support of the same layer 2 protocols as IP
– no changes to current end-systems and routers required
– mobile end-systems can communicate with fixed systems
• Transparency
– mobile end-systems keep their IP address
– continuation of communication after interruption of link
possible
– point of connection to the fixed network can be changed
• Efficiency and scalability
– only little additional messages to the mobile system required
(connection typically via a low bandwidth radio link)
– world-wide support of a large number of mobile systems
• Security
– authentication of all registration messages

103
Terminology
• Mobile Node (MN) - is an end-system that can change the point of connection to
the network without changing its IP address.

• Home Network (HN) – is the subnet the MN belongs to with respect to its IP
address.

Foreign Network (FA) – is the current subnet the MN visits.

• Correspondent Node (CN) – is a fixed or Mobile Node act as partner for


communication with MN.

• Care-of Address (COA)


– address of the current tunnel end-point for the MN (at FA or MN)
– actual location of the MN from an IP point of view
– can be chosen, e.g., via DHCP

• Home Agent (HA)


– Is a system (or router) located in the home network of the MN,
– registers the location of the MN, then tunnels IP datagram's to the COA

• Foreign Agent (FA)


– system in the current foreign network of the MN, typically a router 104
– typically the default router for the MN
Mobility: Vocabulary
home network:
permanent
“home” of mobile home agent: entity that
visited network:
(e.g., 128.119.40/24) will perform mobility network in which mobile
functions on behalf of currently resides (e.g.,
79.129.13/24)
mobile, when mobile is
remote Permanent address:
remains constant
(e.g., 128.119.40.186)

wide area
Permanent address: network
address in home Care-of-address:
network, can always be address in visited
used to reach mobile network.
e.g., 128.119.40.186 (e.g., 79,129.13.2)
correspondent: Foreign agent: entity in visited
wants to network that performs
communicate with mobility functions on behalf of105
mobile mobile.
106
Three Phases
To communicate with a remote host, a mobile host goes
through three phases: agent discovery, registration, and
data transfer.

107
Phase-III : Data Transfer or IP Packet Delivery
• Step 1: CN send the packet as usual to the IP address of MN.
• Step 2: The HA intercepts the packet and the forwarded into the
subnet as usual, but encapsulated and tunneled to the COA.
• Step 3: The FA now decapsulates the packet and forwards the
original packet with CN as source and MN as destination to
the MN
• Step 4: The MN sends the packet as usual with its own fixed IP
address as source and CN‘s address as the destination.

108
109
110
Phase – I : Agent Discovery
• HA and FA periodically send Advertisement messages into air
• MN listens to these messages and detects, if it is in the home or
a foreign network
– If MN does not wish to wait for the periodic advertisement, it
can send out Agent Solicitation messages that will be
responded by HA or FS
• MN reads a COA from the FA advertisement messages

111
Mobile IP: agent discovery
 agent advertisement: foreign/home agents advertise service by
broadcasting ICMP messages (type field = 9)

0 8 16 24

typ e = 9 c ode = 0 chec k s um


= 9 = 9

H,F bits: home s t a n d a rd


and/or foreign agent ro u t e r a d d re s s
I C M P f ie ld s

R bit: registration
required typ e = 1 6 le n g t h s equenc e #

R BH FM G V
re g is t ra t io n lif e t im e re s e rv e d
b it s m o b ilit y a g e n t
a d v e rt is e m e n t

0 o r m o re c a re -o f- e x t e n s io n

a d d re s s e s
112
Field Description
• Type – ICMP packet type ( 9 – Router Advt)
• Code – 0 - agent routes traffic for mobile/non- mobile node – 16
– only for mobile traffic
• #address – number of router addresses
• Life time – length of time this advertise valid
• Preference – choose the router, most eager one to get a new node.
• Flags: R – Registration, B- Busy, H – HA, F- FA,M – minimal
encapsulation, G – Generic routing encapsulation, r-zero, T –
reverse tunnel

113
ICMP Message Types

114
Code Bits

115
Phase-II: Registration

• MN signals COA to the HA via the FA, HA acknowledges via FA


to MN
– these actions have to be secured by authentication

116
Registration
Two Ways : 1. Via FA
2. directly with HA

117
Registration Request

 Type is set to 1 for registration request


 Flags – S – simultaneous bindings, B – receive Broadcast pkts,
D – de-capsulation, M & G – Minimal & generic encapsulation,
T – reverse tunnel (replaced with V)
 Identification used for replay protection 118
 Uses UDP messages
Registration request flag field bits

119
Registration Reply

 Type field set to 3


 Extensions must at least contain parameter for authentication
 Code field describes status information, e.g. why the registration
failed. These include
120
• authentication failed, ID mismatch , unknown HA
Tunneling and Encapsulation
• It describes the mechanism used for forwarding packets between
the HA and COA.
• A tunnel establishes the virtual pipe for data packets between
a tunnel entry and tunnel end point.
• Encapsulation is the mechanism of taking a packet
consisting of packet header and data and put into a data part of
another packet.
• Outer Header – Header of New Packet
• Inner Header – identical to header of Original Packet or can be
computed during encapsulation.
• There are different ways of performing the encapsulation – IP-in-
IP (mandatory), minimal and generic routing.

121
IP Encapsulation

122
IP-in-IP Encapsulation

• Tunneling
between HA
and COA

123
IP-in-IP Encapsulation

124
Field Description
• The outer IP header source & destination address identify the
tunnel endpoints (i.e. HA & FA).
• Ver – is ‗4‘ for IP protocol.
• TOS – now it is DS in the context of Differentiated Services.
• The inner IP header source and destination address identify the
original sender & recipient
• Other headers for authentication might be added to outer header.
• Some outer IP header fields are copied from the inner IP fields
(TOS), most are re-computed (checksum, length) based on new
datagram.
• The outer TTL must be high enough so that packet can reach the
tunnel end-point. The inner TTL decremented by one only, that is,
whole tunnel to be considered as single hop.
125
Minimal Encapsulation
• We can save space by recognizing that much of the inner header
can be derived from the outer header
– Copy inner header
– Modify protocol field to be 55, for the minimal protocol
– Destination address replaced by tunnel exit
– If encapsulator isn‘t originator of message, replace source
address with address of encapsulator
– Increment total length by the size of the additional header
(either 12 or 8 octets)
– Recompute checksum
• Sender sends all packets via HA to MN
• Higher latency and network load

126
Minimal Encapsulation Header

127
Generic Routing Encapsulation
It allows the encapsulation of packets of one protocol suite in to
the payload portion of a packet of another protocol suite.

Fig: GRE 128


Protocol fields for GRE

129
Optimizations

• The inefficient behavior of a


non-optimized mobile IP is
called Triangular Routing.
• In this all packets to through
the HA. This cause
unnecessary overhead
between CN & HA and HA
& COA/FA .
• One way to optimize the
route is inform the CN of the
current location of MN.
• The optimized mobile IP
needs 4 additional messages.
130
Four Messages
• Binding Request (BR) – Any node wants to know the current
location of MN can send BR to the HA.
• Binding Update (BU) – It is sent by the HA to CN reveals the
current location of MN.
• Binding ACK (BA) – If requested, a node returns this ACK after
receiving a BU.
• Binding Warning (BW) – If a node decapsulates a packet for an
MN, but it is not the current FA for this MN, this nods send this
BW.

131
Change of FA with an Optimized mobile IP

132
133
134
135
136
137
138
Unit-III

139
Syllabus
Mobile Network Layer
Mobile IP Network Layer: IP and mobile IP Network Layers,
Packet Delivery and handover Management, Location
Management, Registration, Tunneling and Encapsulation, Route
Optimization, DHCP.

Mobile Transport Layer: Conventional TCP/IP Protocols, Indirect


TCP, Snooping TCP, Mobile TCP, other transport layers protocols
for Mobile Networks.

140
 Supporting mobility up to the network layer is not enough to
support mobility support for applications.
 Most application rely on a transport layer, such as TCP in case
of internet.
 Two functions of the transport layer in the internet are
– Check summing user data
– Mux/demux of data to/from application
 While network layer only addresses a host, ports in UDP/TCP
allow dedicated services to be addressed.
 The connectionless UDP does not offer much more than TCP,
so, this unit concentrates only on TCP.
 Mobility Support in IP (like Mobile IP) is already enough for
UDP to work.
 TCP has built-in mechanism to behave in a ‗network friendly‘
manner.
141
Traditional TCP
Transport protocols typically designed for
– Fixed end-systems
– Fixed, wired networks
Research activities
– Performance
– Congestion control
– Efficient retransmissions
Congestion control
– packet loss in fixed networks typically due to (temporary)
overload situations
– router have to discard packets as soon as the buffers are full
– TCP recognizes congestion only indirect via missing
acknowledgements, retransmissions unwise, they would only
contribute to the congestion and make it even worse 142
Slow-start
– sender calculates a congestion window for a receiver
– start with a congestion window size equal to one segment
– exponential increase of the congestion window up to the congestion
threshold, then linear increase
– missing acknowledgement causes the reduction of the congestion
threshold to one half of the current congestion window
– congestion window starts again with one segment
Fast retransmit/fast recovery
– TCP sends an acknowledgement only after receiving a packet
– if a sender receives several acknowledgements for the same packet,
this is due to a gap in received packets at the receiver
– however, the receiver got all packets up to the gap and is actually
receiving packets
– therefore, packet loss is not due to congestion, continue with current
congestion window (do not use slow-start)
143
Implications on mobility
TCP assumes congestion if packets are dropped
– typically wrong in wireless networks, here we often have
packet loss due to transmission errors
– furthermore, mobility itself can cause packet loss, if e.g. a
mobile node roams from one access point (e.g. foreign agent
in Mobile IP) to another while there are still packets in transit
to the wrong access point and forwarding is not possible
The performance of an unchanged TCP degrades severely
– however, TCP cannot be changed fundamentally due to the
large base of installation in the fixed network, TCP for
mobility has to remain compatible
– the basic TCP mechanisms keep the whole Internet together

144
Classical TCP Improvements
 Indirect TCP (I-TCP)
 Snooping TCP
 Mobile TCP (M-TCP)
 Fast retransmit/fast recovery
 Transmission/time-out freezing
 Selective retransmission
 Transaction-oriented TCP (T/TCP)

145
Indirect TCP (I-TCP)
Indirect TCP segments the connection
– no changes to the TCP protocol for hosts connected to the wired
Internet, millions of computers use (variants of) this protocol
– optimized TCP protocol for mobile hosts
– splitting of the TCP connection at, e.g., the foreign agent into 2
TCP connections, no real end-to-end connection any longer
– hosts in the fixed part of the net do not notice the characteristics of
the wireless part

mobile host access point


(foreign agent) “wired“ Internet
Correspondent
Host

“wireless” TCP standard TCP

146
Indirect TCP (I-TCP) [2]

access point1

socket migration
and state transfer Internet
Correspondent
Host

access point2
mobile host
Figure: I-TCP socket and state migration

147
Indirect TCP or I-TCP [3]
Advantages
– no changes in the fixed network necessary, no changes for the hosts
(TCP protocol) necessary, all current optimizations to TCP still work
– transmission errors on the wireless link do not propagate into the fixed
network
– simple to control, mobile TCP is used only for one hop between, e.g., a
foreign agent and mobile host
– therefore, a very fast retransmission of packets is possible, the short
delay on the mobile hop is known
Disadvantages
– loss of end-to-end semantics, an acknowledgement to a sender does
now not any longer mean that a receiver really got a packet, foreign
agents might crash
– higher latency possible due to buffering of data within the foreign
agent and forwarding to a new foreign agent
148
Snooping TCP
―Transparent‖ extension of TCP within the foreign agent
– buffering of packets sent to the mobile host
– lost packets on the wireless link (both directions!) will be retransmitted
immediately by the mobile host or foreign agent, respectively (so called
―local‖ retransmission)
– the foreign agent therefore ―snoops‖ the packet flow and recognizes
acknowledgements in both directions, it also filters ACKs
– changes of TCP only within the foreign agent
local retransmission correspondent
foreign host
agent
“wired“ Internet

snooping of ACKs buffering of data


mobile
host end-to-end TCP connection

149
Snooping TCP [2]
Data transfer to the mobile host
– FA buffers data until it receives ACK of the MH, FA detects packet
loss via duplicated ACKs or time-out
– fast retransmission possible, transparent for the fixed network
Data transfer from the mobile host
– FA detects packet loss on the wireless link via sequence numbers, FA
answers directly with a NACK to the MH
– MH can now retransmit data with only a very short delay
Integration of the MAC layer
– MAC layer often has similar mechanisms to those of TCP
– thus, the MAC layer can already detect duplicated packets due to
retransmissions and discard them
Problems
– snooping TCP does not isolate the wireless link as good as I-TCP 150
– snooping might be useless depending on encryption schemes
Mobile TCP (M-TCP)
Special handling of lengthy and/or frequent disconnections
M-TCP splits as I-TCP does
– unmodified TCP fixed network to supervisory host (SH)
– optimized TCP SH to MH
Supervisory host
– no caching, no retransmission
– monitors all packets, if disconnection detected
• set sender window size to 0
• sender automatically goes into persistent mode
– old or new SH reopen the window
Advantages
– maintains semantics, supports disconnection, no buffer forwarding
Disadvantages
– loss on wireless link propagated into fixed network
151
– adapted TCP on wireless link
Fast retransmit/fast recovery
Change of foreign agent often results in packet loss
– TCP reacts with slow-start although there is no congestion
Forced fast retransmit
– as soon as the mobile host has registered with a new foreign
agent, the MH sends duplicated acknowledgements on purpose
– this forces the fast retransmit mode at the communication partners
– additionally, the TCP on the MH is forced to continue sending
with the actual window size and not to go into slow-start after
registration
Advantage
– simple changes result in significant higher performance
Disadvantage
– further mix of IP and TCP, no transparent approach
152
Transmission/time-out freezing
Mobile hosts can be disconnected for a longer time
– no packet exchange possible, e.g., in a tunnel, disconnection
due to overloaded cells or multiplexing with higher priority
traffic
– TCP disconnects after time-out completely
TCP freezing
– MAC layer is often able to detect interruption in advance
– MAC can inform TCP layer of upcoming loss of connection
– TCP stops sending, but does now not assume a congested link
– MAC layer signals again if reconnected
Advantage
– scheme is independent of data
Disadvantage
– TCP on mobile host has to be changed, mechanism depends153on
Selective retransmission
TCP acknowledgements are often cumulative
– ACK n acknowledges correct and in-sequence receipt of packets
up to n
– if single packets are missing quite often a whole packet sequence
beginning at the gap has to be retransmitted (go-back-n), thus
wasting bandwidth
Selective retransmission as one solution
– RFC2018 allows for acknowledgements of single packets, not only
acknowledgements of in-sequence packet streams without gaps
– sender can now retransmit only the missing packets
Advantage
– much higher efficiency
Disadvantage
– more complex software in a receiver, more buffer needed at the
154
receiver
Transaction oriented TCP (T/TCP)
TCP phases
– connection setup, data transmission, connection release
– using 3-way-handshake needs 3 packets for setup and release,
respectively
– thus, even short messages (one byte) need a minimum of 7
packets!
Transaction oriented TCP
– RFC1644, T-TCP, describes a TCP version to avoid this overhead
– connection setup, data transfer and connection release can be
combined
– thus, only 2 or 3 packets are needed
Advantage
– efficiency
Disadvantage
– requires changed TCP
155
– mobility not longer transparent
Transaction oriented TCP [2]

Client Server
TCP SYN
TCP SYN/ACK Connection
setup
TCP ACK
HTTP request
Data
HTTP response transmission

>15 s
no data
GPRS: 500ms! Connection
release

Figure: Example TCP Connection setup overhead

156
Comparison of different approaches for a
“mobile” TCP
A p p ro ach M e c h a n is m A d v a n ta g e s D is a d v a n t a g e s
In d ir e c t T C P s p lits T C P c o n n e c tio n is o la tio n o f w ir e le s s lo s s o f T C P s e m a n tic s ,
in to tw o c o n n e c tio n s lin k , s im p le h ig h e r la te n c y a t
handover
S n o o p in g T C P “ s n o o p s ” d a ta a n d tr a n s p a re n t fo r e n d - to - p r o b le m a tic w ith
a c k n o w le d g e m e n ts , lo c a l e n d c o n n e c tio n , M A C e n c r y p tio n , b a d is o la tio n
r e tra n s m is s io n in te g ra tio n p o s s ib le o f w ir e le s s lin k
M -T C P s p lits T C P c o n n e c tio n , M a in ta in s e n d - to - e n d B a d is o la tio n o f w ir e le s s
c h o k e s s e n d e r v ia s e m a n tic s , h a n d le s lin k , p r o c e s s in g
w in d o w s iz e lo n g te r m a n d fr e q u e n t o v e r h e a d d u e to
d is c o n n e c tio n s b a n d w id th m a n a g e m e n t
F a s t r e tr a n s m it/ a v o id s s lo w - s ta r t a fte r s im p le a n d e ffic ie n t m ix e d la y e r s , n o t
fa s t re c o v e r y r o a m in g tr a n s p a re n t
T r a n s m is s io n / fr e e z e s T C P s ta te a t in d e p e n d e n t o f c o n te n t c h a n g e s in T C P
tim e -o u t fre e z in g d is c o n n e c t, re s u m e s o r e n c r y p tio n , w o r k s fo r r e q u ire d , M A C
a fte r re c o n n e c tio n lo n g e r in te r r u p ts dependant
S e le c tiv e r e tra n s m it o n ly lo s t d a ta v e r y e ffic ie n t s lig h tly m o r e c o m p le x
r e tra n s m is s io n r e c e iv e r s o ftw a r e , m o re
b u ffe r n e e d e d
T r a n s a c tio n c o m b in e c o n n e c tio n E ffic ie n t fo r c e rta in c h a n g e s in T C P
o r ie n te d T C P s e tu p /r e le a s e a n d d a ta a p p lic a tio n s r e q u ire d , n o t tr a n s p a r e n t
tr a n s m is s io n
157
UNIT-IV

158
Syllabus
Database Issues: Database Hoarding & Caching Techniques, C-S
Computing & Adaptation, Transactional Models, Query Processing,
Data Recovery Process & QoS Issues.

Data Dissemination and Synchronization: Communications


Asymmetry, Classification of Data Delivery Mechanisms, Data
Dissemination Broadcast Models, Selective Tuning and Indexing
Methods, Digital Audio and Video Broadcasting(DAB & DVB).
Data Synchronization- Introduction, Software, and Protocols.

159
Database Hoarding Techniques
• A mobile device cannot store a large database due to memory
constraints.
• The large databases are available on the servers, remote
computing systems, or networks.
• Retrieving the required data from a database server during every
computation- impractical due to time constraints
• A mobile device is not always connected to the server or
network; neither does the device retrieve data from a server or a
network for each computation.

160
Database Hoarding Techniques
• Rather, the device caches some specific data, which may be required
for future computations, during the interval in which the device is
connected to the server or network.
• Cache is a list or database consisting of saved items or records at the
device, which the device saves for faster access at a later time, rather
than reselecting or re-tuning or re-fetching the data when required.
• The cached items are the ones which the device fetches by request ,
demand or subscription to the server and saves in the list or
database.
• Caching entails saving a copy of select data or a part of a database
from a connected system with a large database.
• The cached data is hoarded in the mobile device database as and
when the device connects to the server or network
• Hoarding of the cached data in the database ensure that even when
the device is not connected to a network or server(disconnected
mode), the data required from the database is available instantly for
computing 161
Example-caching and hoarding:
• Consider the train schedules in a railway timetable.
• The schedule of specific trains to and from the device user
location is stored in the huge databases of the servers and
networked of the company operating the trains.
• The user device caches and hoards some specific information
from the database and the hoarded device-database is used during
computations from retrieving the data for a specific set of train
schedules

162
Database Hoarding

• Database hoarding may be done at the application tier itself. The


following figure shows a simple architecture in which a mobile
device API directly retrieves the data from a database.
• It also shows another simple architecture in which a mobile
device API directly retrieves the data from a database through a
program, for ex: IBM DB2 Everyplace (DB2e).

163
(a) API at mobile device sending queries and retrieving data from local
database (Tier 1) (b) API at mobile device retrieving data from database
using DB2e (Tier 1) 164
Database Hoarding
• Both the two architectures belong to the class of one-tier database
architecture.
• Some examples are downloaded ringtones, music etc. IBM DB2
Everyplace (DB2e) is a relational database engine which has
been designed to reside at the device.
• It supports J2ME and most mobile device operating systems.

165
Hoarding multi-tier database
• In two-tier or multi-tier databases the databases reside in the
remote servers and the copies of these databases are cached at the
client tiers.
• This type of architecture is known as client-server computing
architecture.
• Cache is a list or database consisting of saved items or records at
the device.
• The device may select and save the item from a set of records
broadcasted or pushed by a server or the device may access (by
request ,demand, or subscription) the item at the server and save
it to the list or database
• Databases are hoarded at the application or enterprise tier, where
the database server uses business logic and connectivity for
retrieving the data and then transmitting it to the device.
• The server provides and updates local copies of the database at
each mobile device connected to it

167
(a) Distributed data caches in mobile devices (b) Similar architecture for
a distributed cache memory in multiprocessor systems
168
• The computing API at the mobile device (first tier) uses the
cached local copy.
• At first tier (tier 1), the API uses the cached data records using
the computing architecture.
• From tier 2 or tier 3, the server retrieves and transmits the data
records to tier 1 using business logic and synchronizes the local
copies at the device.

169
Advantage of hoarding
• The advantage of hoarding is that there is no access latency
(delay in retrieving the queried record from the server over
wireless mobile networks).
• The client device API has instantaneous data access to hoarded or
cached data.
• After a device caches the data distributed by the server, the data
is hoarded at the device.
• The disadvantage of hoarding is that the consistency of the
cached data with the database at the server needs to be
maintained.

170
Data Caching
• Hoarded copies of the databases at the servers are distributed or
transmitted to the mobile devices from the enterprise servers or
application databases.
• The copies cached at the devices are equivalent to the cache
memories at the processors in a multiprocessor system with a
shared main memory and copies of the main memory data stored
at different locations.

171
• Cache Access Protocols: A client device caches the pushed
(disseminated) data records from a server.
• Caching of the pushed data leads to a reduced access interval as
compared to the pull (on-demand) mode of data fetching.
• Caching of data records can be-based on pushed 'hot records' (the
most needed database records at the client device).
• Also, caching can be based on the ratio of two parameters—
access probability (at the device) and pushing rates (from the
server) for each record.
• This method is called cost-based data replacement or caching

172
• Pre-fetching: Pre-fetching is another alternative to caching of
disseminated data.
• The process of pre-fetching entails requesting for and pulling
records that may be required later.
• The client device can pre-fetch instead of caching from the
pushed records keeping future needs in view.
• Pre-fetching reduces server load. Further, the cost of cache-
misses can thus be reduced.
• The term 'cost of cache-misses' refers to the time taken in
accessing a record at the server in case that record is not found in
the device database when required by the device API.

173
Caching Invalidation Mechanisms
• A cached record at the client device may be invalidated.
• This may be due to expiry or modification of the record at the
database server.
• Cache invalidation is a process by which a cached data item or
record becomes invalid and thus unusable because of
modification, expiry, or invalidation at another computing system
or server.
• Cache invalidation mechanisms are used to synchronize the data
at other processors whenever the cache-data is written (modified)
by a processor in a multiprocessor system.

174
Caching Invalidation Mechanisms contd…
• A cache consists of several records. Each record is called a
cache-line, copies of which can be stored at other devices or
servers.
• The cache at the mobile devices or server databases at any given
time can be assigned one of four possible tags indicating its state
• —modified (after rewriting), exclusive, shared, and invalidated
(after expiry or when new data becomes available) at any given
instance.
• These four states are indicated by the letters M, E, S, and I,
respectively (MESI).

175
The states indicated by the various tags are as follows:
• a) The E tag indicates the exclusive state which
means that the data record is for internal use and
cannot be used by any other device or server.
• b) The S tag indicates the shared state which indicates
that the data record can be used by others.
• c) The M tag indicates the modified state which
means that the device cache
• d) The I tag indicates the invalidated state which
means that the server database no longer has a copy of
the record which was shared and used for
computations earlier.

176
The following figure shows the four possible states of a data record i at any instant
in the server database and its copy at the cache of the mobile device j.

Four possible states (M, E, S, or /) of a data record /at any instance at the
177
server database and device j cache
Cache consistency
• Another important factor for cache maintenance in a
mobile environment is cache consistency (also called
cache coherence).
• This requires a mechanism to ensure that a database
record is identical at the server as well as at the device
caches and that only the valid cache records are used
for computations.

178
Data Cache Maintenance in Mobile
Environment
• Device needs a data-record while running an application.
• A request must be sent to the server for the data record(this
mechanism is called pulling)
• The time taken for the application software to access a particular
record is known as access latency.
• Caching and hoarding the record at the device reduces access
latency to zero.
• Data cache maintenance is necessary in a mobile environment to
overcome access latency.
• Data cache inconsistency means that data records cached for
applications are not invalidated at the device when modified at the
server but not modified at the device

179
• Data cache consistency can be maintained by the three methods:
– Cache invalidation mechanism(server-initiated case)
– Polling mechanism(client-initiated case)
– Time-to-live mechanism(client-initiated case)

180
Cache invalidation mechanisms
• Cache invalidation mechanisms in mobile devices are triggered or
initiated by the server.
• There are four possible invalidation mechanisms –
– Stateless asynchronous,
– stateless synchronous,
– stateful asynchronous and
– stateful synchronous.

181
Stateless Asynchronous:
• Stateless Asynchronous: A stateless mechanism entails
broadcasting of the invalidation of the cache to all the clients of the
server.
• The server does not keep track of the records stored at the device
caches.
• It just uniformly broadcasts invalidation reports to all clients
irrespective of whether the device cache holds that particular
record or not.
• The term 'asynchronous' indicates that the invalidation information
for an item is sent as soon as its value changes.
• The server advertises the invalidation information only. The client
can either request for a modified copy of the record or cache the
relevant record when data is pushed from the server.
• The server advertises as and when the corresponding data-record at
the server is invalidated and modified (deleted or replaced).

182
• The advantage of the asynchronous approach is that there are no
frequent, unnecessary transfers of data reports, thus making the
mechanism more bandwidth efficient.
• The disadvantages of this approach are—
• (a) every client device gets an invalidation report, whether that
client requires that copy or not and
• (b) client devices presume that as long as there is no invalidation
report, the copy is valid for use in computations.
• Therefore, even when there is link failure, the devices may be
using the invalidated data and the server is unaware of state
changes at the clients after it sends the invalidation report.

183
Stateless Synchronous
• Stateless Synchronous: This is also a stateless mode, i.e., the
server has no information regarding the present state of data
records at the device caches and broadcasts to all client devices.
• However, unlike the asynchronous mechanism, here the server
advertises invalidation information at periodic intervals as well as
whenever the corresponding data-record at server is invalidated
or modified.
• This method ensures synchronization because even if the in-
between period report is not detected by the device due to a link
failure, the device expects the period-end report of invalidation
and if that is not received at the end of the period, then the device
sends a request for the same (deleted or replaced).
• In case the client device does not get the periodic report due to
link failure, it requests the server to send the report.

184
Polling mechanism(client-initiated case)
• Polling means checking the state of the data record, from the
server and determining whether the record is in the valid, invalid,
modified, or exclusive state.
• Each cached record copy is polled whenever required by the
application software during computation
• The device connects to the server and finds out whether the
cached data record copy at the device has become invalid or has
been modified at the server
• If the record is found to be modified or invalidated, then the
device requests for the modified data and replaces the earlier
cached record copy.

185
Time-to-live mechanism(client-initiated case)
• Each cached record is assigned a TTL value
• The TTL assignment is adaptive for previous update intervals of
that record.
• The client device requests the server to check whether the cached
data record is invalid or modified at the end of the TTL time.
• If it is modified , then the device requests the server to replace
the invalid cached record with the modified data.
• when TTL is set 0, the TTL mechanism is equivalent to the
polling mechanism

186
Client-server computing for mobile computing
and adaptation
• The network architecture can be designed so that a node is either
client or server
• A client node runs application software which depends on server
nodes resources(files, databases, web pages, processor power or
other devices or computers connected or networked to it)
• The server node has larger resources and computing power than
the client nodes.
• This architecture is known as client-server computing
architecture
• It is different from peer-to-peer architecture, where each node on
the network has similar resources and the various nodes depend
on each others resources
• Client-server architecture is used for mobile computing
• Mobile devices function as client nodes due to their resources
187
constraints.
Two Network Based Computing

• Client-Server:
• Client nodes depends on server resources
• A client requests the server for data or responses which the client
then uses in computations
• The client can either access the data records at the server or cache
these records through broadcasArchitecturests or distribution
from the server

188
Client-server Computing
• • An N-tier architecture (N = 1, 2, …)
• • On the same computing system (not on a network), then the
number of tiers, N = 1
• • When the client and the server are on different computing
systems on the network, then N = 2

189
Server networks or connecting to
other computing systems
• • if server connecting to other systems provide additional
resources to the server for the client then N > 2
• • N > 1 means that the client device at tier 1 connects to the
server at tier 2 which, in turn, may connected to other

190
Application server in two-tier client–
server computing architecture
• A client is a program(API) used to retrieve records from
databases.
• A server is a program that connects to database and sends the
outputs(response) to the client
• A server is defines as a computing system, which responds to
request from one or more clients
• A client is defined as a computing system, which request the
server for a resources or for executing a task.

191
Two-tier Client–Server Architecture

192
APIs and Synchronization API
• • Various APIs synchronization with each other
• • Synchronization─ means that when copies at the server-end
modifies, the cached copies accordingly modified
• • The APIs designed independent of hardware and software
platforms as far as possible as different devices may have
different platforms

193
Three-tier Client–Server Architecture
• • The application interface, the functional logic, and the database
are maintained at three different layers
• • The database is associated with the enterprise server tier (tier 3)
• • Only local copies of the database exist at mobile devices

195
Three-tier Client–Server Architecture
• Data records at tier 3 are sent to tier 1 through synchronization-
cum-application server at tier 2.
• The synchronization-cum application server has synchronization
server programs, which retrieves data records from the enterprise
tier (tier 3) using business logic,
• The enterprise tier connects to the databases using a connectivity
protocol and sends the database records as per the business logic
query to tier 2
• There is an in-between server, called synchronization which
sends and synchronizes the copies at the multiple devices

196
Data Dissemination
• Ongoing advances in communications including the proliferation
of internet, development of mobile and wireless networks, high
bandwidth availability to homes have led to development of a
wide range of new-information centered applications.
• Many of these applications involve data dissemination, i.e.
delivery of data from a set of producers to a larger set of
consumers.

197
• Data dissemination entails distributing and pushing data
generated by a set of computing systems or broadcasting data
from audio, video, and data services.
• The output data is sent to the mobile devices. A mobile device
can select, tune and cache the required data items, which can be
used for application programs.

198
• Efficient utilization of wireless bandwidth and battery
power are two of the most important problems facing
software designed for mobile computing.
• Broadcast channels are attractive in tackling these two
problems in wireless data dissemination.
• Data disseminated through broadcast channels can be
simultaneously accessed by an arbitrary number of mobile
users, thus increasing the efficiency of bandwidth usage.

199
Communications Asymmetry
• One key aspect of dissemination-based applications is their
inherent communications asymmetry.
• That is, the communication capacity or data volume in the
downstream direction (from servers-to-clients) is much greater
than that in the upstream direction (from clients-to-servers).
• Content delivery is an asymmetric process regardless of whether
it is performed over a symmetric channel such as the internet or
over an asymmetric one, such as cable television (CATV)
network.
• Techniques and system architectures that can efficiently support
asymmetric applications will therefore be a requirement for
future use.

200
• Mobile communication between a mobile device and a static
computer system is intrinsically asymmetric. A device is
allocated a limited bandwidth.
• This is because a large number of devices access the network.
Bandwidth in the downstream from the server to the device is
much larger than the one in the upstream from the device to the
server.
• This is because mobile devices have limited power resources
and also due to the fact that faster data transmission rates for
long intervals of time need greater power dissipation from the
devices.
• In GSM networks data transmission rates go up to a maximum
of 14.4 kbps for both uplink and downlink.
• The communication is symmetric and this symmetry can be
maintained because GSM is only used for voice
communication.

201
Data Dissemination

Communication asymmetry in uplink and downlink and participation of


device APIs and distributed computing systems when an application runs
The above figure shows communication asymmetry in uplink and downlink in a
mobile network. The participation of device APIs and distributed computing
systems in the running of an application is also shown.
202
Communication Asymmetry
• • Intrinsically asymmetric Mobile
• communication between the mobile
• device and static computer system
• • Device allocated a limited bandwidth
• • Because of a large number of devices

203
• • Bandwidth in the downstream from the
• server to device much larger than the
• one in the upstream from the device to
• server
• • Because mobile devices have limited
• power resources
• • Faster data transmission rates for long
• intervals of time need greater power
• dissipation from the devices

204
Communication asymmetry in uplink
and downlink in a mobile network

205
GSM networks data transmission
• • Rates go up to a maximum of 14.4 kbps
• for both uplink and downlink
• • Symmetric communication
• • Only used for voice communication

206
i-mode for many applications
• • Used for voice, multimedia transmission,
• Internet access, voice communication
• • Base station provides downlink 384 kbps
• • Uplink from the devices restricted to 64
• kbps
• • Asymmetric communication

207
The characteristics in wireless signals
• • Interference and time-dispersion
• • Signal distortion and transmission errors
• at the receiver end
• • Lead to path loss and signal fading,
• which cause data loss
• • Greater access latency compared to
• wired networks

208
The characteristics in wireless signals
• • Data loss has to be taken care of by
• repeat transmissions
• • Transmission errors have to be corrected
• • Taken care of by appending additional
• bits, such as the forward error correction
• bits

209
The characteristics in Mobile
communication
• Mobile devices also have low storage
• capacity (memory)
• Cannot hoard large databases
• Accessing the data online not only has a
• latency period (is not instantaneous) but
• also dissipates bandwidth resources of
• the device

210
Broadcasting
• • Corresponds to unidirectional (downlink
• from the server to the devices)
• • Unicast communication─ Unicast means
• the transmission of data packets in a
• computer network such that a single
• destination receives the packets

211
Broadcasting or application distribution
service
• This destination generally the one which
• has subscribed to the service
• Mobile TV─ an example of unidirectional
• unicast mode of broadcasting
• Each device receives broadcast data
• packets from the service provider‘s
• application– distribution system

212
Broadcasting or application distribution
service

• Application–distribution system
• broadcasts data of text, audio, or video
• services

213
A broadcasting architecture

214
Summary
• • GSM symmetric and voice only
• • Mobile communication asymmetric in
• general
• • Limited device capability
• • Device memory, energy and uplink and
• downlink bandwidths
• • Broadcast architecture

215
Classification of Data-Delivery Mechanisms
• There are two fundamental information delivery methods for
wireless data applications: Point-to-Point access and Broadcast.
• Compared with Point-to-Point access, broadcast is a more
attractive method. A single broadcast of a data item can satisfy
all the outstanding requests for that item simultaneously.
• As such, broadcast can scale up to an arbitrary number of users.
There are three kinds of broadcast models, namely push-based
broadcast, On-demand (or pull-based) broadcast, and hybrid
broadcast.
• In push based broadcast, the server disseminates information
using a periodic/aperiodic broadcast program (generally without
any intervention of clients).

216
• In on demand broadcast, the server disseminates information based
on the outstanding requests submitted by clients; In hybrid
broadcast, push based broadcast and on demand data deliveries are
combined to complement each other.
• In addition, mobile computers consume less battery power on
monitoring broadcast channels to receive data than accessing data
through point-to-point communications.
• Data-delivery mechanisms can be classified into three categories,
namely, push-based mechanisms (publish-subscribe mode), pull-
based mechanisms (on-demand mode), and hybrid mechanisms
(hybrid mode).

217
Classification of Data-Delivery
Mechanisms
• Push-based mechanisms (publish–
• subscribe mode)
• Pull-based mechanisms (on-demand
• mode)
• Hybrid mechanisms (hybrid mode)

218
Push-based Mechanisms
• The server pushes data records from a set of distributed
computing systems.
• Examples are advertisers or generators of traffic congestion,
weather reports, stock quotes, and news reports.
• The following figure shows a push-based data-delivery
mechanism in which a server or computing system pushes the
data records from a set of distributed computing systems.
• The data records are pushed to mobile devices by broadcasting
without any demand.
• The push mode is also known as publish-subscribe mode in
which the data is pushed as per the subscription for a push
service by a user.
• The subscribed query for a data record is taken as perpetual
query till the user unsubscribe to that service. Data can also be
pushed without user subscription.

219
Push-based data-delivery mechanism

220
Push-based mechanisms function in the
following manner:
• 1. A structure of data records to be pushed is selected. An
algorithm provides an adaptable multi-level mechanism that
permits data items to be pushed uniformly or non-uniformly after
structuring them according to their relative importance.
• 2. Data is pushed at selected time intervals using an adaptive
algorithm. Pushing only once saves bandwidth. However,
pushing at periodic intervals is important because it provides the
devices that were disconnected at the time of previous push with
a chance to cache the data when it is pushed again.
• 3. Bandwidths are adapted for downlink (for pushes) using an
algorithm. Usually higher bandwidth is allocated to records
having higher number of subscribers or to those with higher
access probabilities.
• 4. A mechanism is also adopted to stop pushes when a device is
handed over to another cell.

221
• Advantages of Push based mechanisms:
–  Push-based mechanisms enable broadcast of data services to
multiple devices.
–  The server is not interrupted frequently by requests from
mobile devices.
– These mechanisms also prevent server overload, which might
be caused by flooding of device requests
–  Also, the user even gets the data he would have otherwise
ignored such as traffic congestion, forthcoming weather reports
etc
• Disadvantages:
–  Push-based mechanisms disseminate of unsolicited,
irrelevant, or out-of-context data, which may cause
inconvenience to the user.
222
Pull based Mechanisms
• The user-device or computing system pulls the data records from
the service provider's application database server or from a set of
distributed computing systems.
• Examples are music album server, ring tones server, video clips
server, or bank account activity server.
• Records are pulled by the mobile devices on demand followed by
the selective response from the server.
• Selective response means that server transmits data packets as
response selectively, for example, after client-authentication,
verification, or subscription account check. The pull mode is also
known as the on-demand mode.
• The following figure shows a pull-based data-delivery
mechanism in which a device pulls (demands) from a server or
computing system, the data records generated by a set of
distributed computing systems.

223
Pull-based mechanisms function in the
following manner:
– 1. The bandwidth used for the uplink channel depends
upon the number of pull requests.
– 2. A pull threshold is selected. This threshold limits the
number of pull requests in a given period of time. This
controls the number of server interruptions.
– 3. A mechanism is adopted to prevent the device from
pulling from a cell, which has handed over the
concerned device to another cell. On device handoff, the
subscription is cancelled or passed on to the new service
provider cell
• In pull-based mechanisms the user-device receives data
records sent by server on demand only. 224
• Advantages of Pull based mechanisms:
– With pull-based mechanisms, no unsolicited or
irrelevant data arrives at the device and the relevant
data is disseminated only when the user asks for it.
– Pull-based mechanisms are the best option when the
server has very little contention and is able to respond
to many device requests within expected time
intervals.
• Disadvantages:
– The server faces frequent interruptions and queues
of requests at the server may cause congestion in cases
of sudden rise in demand for certain data record.
– In on-demand mode, another disadvantage is the
energy and bandwidth required for sending the
requests for hot items and temporal records
225
Hybrid Mechanisms
• A hybrid data-delivery mechanism integrates pushes and
pulls. The hybrid mechanism is also known as
interleaved-push-and-pull (IPP) mechanism.
• The devices use the back channel to send pull requests for
records, which are not regularly pushed by the front
channel.
• The front channel uses algorithms modeled as broadcast
disks and sends the generated interleaved responses to the
pull requests.
• The user device or computing system pulls as well
receives the pushes of the data records from the service
provider's application server or database server or from a
set of distributed computing systems.
• Best example would be a system for advertising and
selling music albums. The advertisements are pushed and
the mobile devices pull for buying the album. 226
• The above figure shows a hybrid interleaved, push-pull-based
data-delivery mechanism in which a device pulls (demands) from
a server and the server interleaves the responses along with the
pushes of the data records generated by a set of distributed
computing systems.

227
Hybrid mechanisms function in the following

manner:
1. There are two channels, one for pushes by front channel and the other
for pulls by back channel.
• 2. Bandwidth is shared and adapted between the two channels depending
upon the number of active devices receiving data from the server and the
number of devices requesting data pulls from the server.
• 3. An algorithm can adaptively chop the slowest level of the scheduled
pushes successively The data records at lower level where the records are
assigned lower priorities can have long push intervals in a broadcasting
model.
• Advantages of Hybrid mechanisms:
–  The number of server interruptions and queued requests are
significantly reduced.
• Disadvantages:
–  IPP does not eliminate the typical server problems of too many
interruptions and queued requests.
– Another disadvantage is that adaptive chopping of the slowest level
228
Selective Tuning and Indexing Techniques
• The purpose of pushing and adapting to a broadcast model is to
push records of greater interest with greater frequency in order to
reduce access time or average access latency.
• A mobile device does not have sufficient energy to continuously
cache the broadcast records and hoard them in its memory.
• A device has to dissipate more power if it gets each pushed item
and caches it.
• Therefore, it should be activated for listening and caching only
when it is going to receive the selected data records or buckets of
interest.
• During remaining time intervals, that is, when the broadcast data
buckets or records are not of its interest, it switches to idle or
power down mode.

229
• Selective tuning is a process by which client device selects only the
required pushed buckets or records, tunes to them, and caches them.
• Tuning means getting ready for caching at those instants and
intervals when a selected record of interest broadcasts. Broadcast
data has a structure and overhead.
• Data broadcast from server, which is organized into buckets, is
interleaved. The server prefixes a directory, hash parameter (from
which the device finds the key), or index to the buckets.
• These prefixes form the basis of different methods of selective
tuning. Access time (taccess) is the time interval between pull
request from device and reception of response from broadcasting or
data pushing or responding server. Two important factors affect
taccess –
– (i) number and size of the records to be broadcast and
– (ii) directory- or cache-miss factor (if there is a miss then the
response from the server can be received only in subsequent
broadcast cycle or subsequent repeat broadcast in the cycle).

230
Directory Method
• One of the methods for selective tuning involves broadcasting a
directory as overhead at the beginning of each broadcast cycle.
• If the interval between the start of the broadcast cycles is T, then
directory is broadcast at each successive intervals of T.
• A directory can be provided which specifies when a specific
record or data item appears in data being broadcasted.
• For example, a directory (at header of the cycle) consists of
directory start sign, 10, 20, 52, directory end sign.
• It means that after the directory end sign, the 10th, 20th and
52nd buckets contain the data items in response to the device
request. The device selectively tunes to these buckets from the
broadcast data.

231
• A device has to wait for directory consisting of start sign, pointers
for locating buckets or records, and end sign.
• Then it has to wait for the required bucket or record before it can
get tuned to it and, start caching it.
• Tuning time ttune is the time taken by the device for selection of
records.
• This includes the time lapse before the device starts receiving data
from the server. In other words, it is the sum of three periods—
time spent in listening to the directory signs and pointers for the
record in order to select a bucket or record required by the device,
waiting for the buckets of interest while actively listening (getting
the incoming record wirelessly), and caching the broadcast data
record or bucket.

232
• The device selectively tunes to the broadcast data to download
the records of interest.
• When a directory is broadcast along with the data records, it
minimizes ttune and taccess.
• The device saves energy by remaining active just for the periods
of caching the directory and the data buckets.
• For rest of the period (between directory end sign and start of the
required bucket), it remains idle or performs application tasks.
Without the use of directory for tuning, ttune = taccess and the
device is not idle during any time interval.

233
Hash-Based Method
• Hash is a result of operations on a pair of key and record.
• Advantage of broadcasting a hash is that it contains a fewer bits
compared to key and record separately.
• The operations are done by a hashing function. From the server
end the hash is broadcasted and from the device end a key is
extracted by computations from the data in the record by
operating the data with a function called hash function
(algorithm).
• This key is called hash key.
• Hash-based method entails that the hash for the hashing
parameter (hash key) is broadcasted.
• Each device receives it and tunes to the record as per the
extracted key.
• In this method, the records that are of interest to a device or those
required by it are cached from the broadcast cycle by first
extracting and identifying the hash key which provides the
location of the record.
234
• This helps in tuning of the device. Hash-based method can be
described as follows:
– 1. A separate directory is not broadcast as overhead with each
broadcast cycle.
– 2. Each broadcast cycle has hash bits for the hash function H, a
shift function S, and the data that it holds. The function S
specifies the location of the record or remaining part of the
record relative to the location of hash and, thus, the time interval
for wait before the record can be tuned and cached.
– 3. Assume that a broadcast cycle pushes the hashing parameters
H(Rí) [H and S] and record Rí. The functions H and S help in
tuning to the H(Rí) and hence to Rí as follows—H gives a key
which in turn gives the location of H(Rí) in the broadcast data.
In case H generates a key that does not provide the location of
H(Rí) by itself, then the device computes the location from S
after the location of H(Rí). That location has the sequential
records Rí and the devices tunes to the records from these
locations.
– 4. In case the device misses the record in first cycle, it tunes and
caches that in next or some other cycle. 235
Index-Based Method
• Indexing is another method for selective tuning. Indexes
temporarily map the location of the buckets.
• At each location, besides the bits for the bucket in record of
interest data, an offset value may also be specified there.
• While an index maps to the absolute location from the beginning
of a broadcast cycle, an offset index is a number which maps to
the relative location after the end of present bucket of interest.
• Offset means a value to be used by the device along with the
present location and calculate the wait period for tuning to the
next bucket. All buckets have an offset to the beginning of the
next indexed bucket or item.

236
• Indexing is a technique in which each data bucket, record, or
record block of interest is assigned an index at the previous data
bucket, record, or record block of interest to enable the device to
tune and cache the bucket after the wait as per the offset value.
• The server transmits this index at the beginning of a broadcast
cycle as well as with each bucket corresponding to data of
interest to the device.
• A disadvantage of using index is that it extends the broadcast
cycle and hence increases taccess.

237
• The index I has several offsets and the bucket type and flag information.
A typical index may consist of the following:
– 1. Ioffset(1) which defines the offset to first bucket of nearest index.
– 2. Additional information about Tb, which is the time required for
caching the bucket bits in full after the device tunes to and starts
caching the bucket. This enables transmission of buckets of variable
lengths.
– 3. Ioffset (next) which is the index offset of next bucket record of
interest.
– 4. Ioffset(end) which is the index offset for the end of broadcast
cycle and the start of next cycle. This enables the device to look for
next index I after the time interval as per Ioffset(end). This also
permits a broadcast cycle to consist of variable number of buckets.
– 5. Itype, which provides the specification of the type of contents of
next bucket to be tuned, that is, whether it has an index value or
data.
– 6. A flag called dirty flag which contains the information whether
the indexed buckets defined by Ioffset(1) and Ioffset(next) are dirty
or not. An indexed bucket being dirty means that it has been
rewritten at the server with new values. Therefore, the device should
invalidate the previous caches of these buckets and update them 238 by
tuning to and caching them.
Distributed Index Based Method
• Distributed index-based method is an improvement
on the (I, m) method.
• In this method, there is no need to repeat the
complete index again and again.
• Instead of replicating the whole index m times, each
index segment in a bucket describes only the offset I'
of data items which immediately follow. Each index
I is partitioned into two parts—I' and I".
• I" consists of unrepeated k levels (sub-indexes),
which do not repeat and I' consists of top I repeated
levels (sub-indexes).
• Assume that a device misses I(includes I' and I' once)
transmitted at the beginning of the broadcast cycle.
As I' is repeated m - I times after this, it tunes to the
pushes by using I', The access latency is reduced as 239
I'
has lesser levels.
Flexible Indexing Method
• Assume that a broadcast cycle has number of data
segments with each of the segments having a variable set
of records. For example, let n records, Ro to Rn-1, be
present in four data segments, R() to Ri-1, Ri to Rj-1 , Rj
to Rj-1 and Rk to Rn-1.
• Some possible index parameters are (i) Iseg,having just 2
bits for the offset, to specify the location of a segment in a
broadcast cycle, (ii) Irec, having just 6 bits for the offset,
to specify the location of a record of interest within a
segment of the broadcast cycle, (iii) Ib, having just 4 bits
for the offset, to specify the location of a bucket of interest
within a record present in one of the segments of the
broadcast cycle.
• Flexible indexing method provides dual use of the
parameters (e.g., use of Iseg or Irec in an index segment to
tune to the record or buckets of interest) or multi-
parameter indexing (e.g., use of Iseg, Irec, or Ib in240an
index segment to tune to the bucket of interest).
• Assume that broadcast cycle has m sets of records
(called segments). A set of binary bits defines the
index parameter Iseg,. A local index is then assigned
to the specific record (or bucket). Only local index
(Irec or Ib) is used in (Iloc, m) based data tuning
which corresponds to the case of flexible indexing
method being discussed. The number of bits in a
local index is much smaller than that required when
each record is assigned an index. Therefore, the
flexible indexing method proves to be beneficial.

241
Unit-V

242
Syllabus
Introduction, Applications & Challenges of a MANET, Routing,
Classification of Routing Algorithms, Algorithms such as DSR,
AODV, DSDV, etc., Mobile Agents, Service Discovery.
Protocols and Platforms for Mobile Computing: WAP,
Bluetooth, XML, J2ME, JavaCard, PalmOS, Windows CE,
Symbian OS, Linux for Mobile Devices.

243
Mobile Ad hoc NETworks (MANETs)
• Mobile Ad hoc Networks (MANETs) are wireless networks which
are characterized by dynamic topologies and no fixed infrastructure.
• Each node in a MANET is a computer that may be required to act as
both a host and a router and, as much, may be required to forward
packets between nodes which cannot directly communicate with one
another.
• Each MANET node has much smaller frequency spectrum
requirements that that for a node in a fixed infrastructure network.
• A MANET is an autonomous collection of mobile users that
communicate over relatively bandwidth constrained wireless links.
• Since the nodes are mobile, the network topology may change
rapidly and unpredictably over time.
• The network is decentralized, where all network activity including
discovering the topology and delivering messages must be executed
by the nodes themselves, i.e., routing functionality will244be
incorporated into mobile nodes.
A mobile ad hoc network is a collection of wireless nodes
that can dynamically be set up anywhere and anytime without
using any pre-existing fixed network infrastructure.

245
MANET- Characteristics
• Dynamic network topology
• Bandwidth constraints and variable link capacity
• Energy constrained nodes
• Multi-hop communications
• Limited security
• Autonomous terminal
• Distributed operation
• Light-weight terminals

246
Need for Ad Hoc Networks
• Setting up of fixed access points and backbone infrastructure is
not always viable
– Infrastructure may not be present in a disaster area or war zone
– Infrastructure may not be practical for short-range radios;
Bluetooth (range ~ 10m)
• Ad hoc networks:
– Do not need backbone infrastructure support
– Are easy to deploy
– Useful when infrastructure is absent, destroyed or impractical

247
Properties of MANETs
•  MANET enables fast establishment of networks. When anew
network is to be established, the only requirement is to provide a
new set of nodes with limited wireless communication range. A
node has limited capability, that is, it can connect only to the nodes
which are nearby. Hence it consumes limited power.
•  A MANET node has the ability to discover a neighboring node
and service. Using a service discovery protocol, a node discovers
the service of a nearby node and communicates to a remote node in
the MANET.
• MANET nodes have peer-to-peer connectivity among themselves.
•  MANET nodes have independent computational, switching (or
routing), and communication capabilities.
•  The wireless connectivity range in MANETs includes only
nearest node connectivity.
•  The failure of an intermediate node results in greater latency 248in
• Limited bandwidth available between two intermediate nodes
becomes a constraint for the MANET. The node may have
limited power and thus computations need to be energy-efficient.
•  There is no access-point requirement in MANET. Only
selected access points are provided for connection to other
networks or other MANETs.
•  MANET nodes can be the iPods, Palm handheld computers,
Smartphones, PCs, smart labels, smart sensors, and automobile-
embedded systems\
•  MANET nodes can use different protocols, for example,
IrDA, Bluetooth, ZigBee, 802.11, GSM, and TCP/IP.MANET
node performs data caching, saving, and aggregation.
•  MANET mobile device nodes interact seamlessly when they
move with the nearby wireless nodes, sensor nodes, and
embedded devices in automobiles so that the seamless 249
connectivity is maintained between the devices.
MANET challenges
• To design a good wireless ad hoc network, various challenges have
to be taken into account:
• Dynamic Topology: Nodes are free to move in an arbitrary fashion
resulting in the topology changing arbitrarily. This characteristic
demands dynamic configuration of the network.
• Limited security: Wireless networks are vulnerable to attack.
Mobile ad hoc networks are more vulnerable as by design any node
should be able to join or leave the network at any time. This requires
flexibility and higher openness.
• Limited Bandwidth: Wireless networks in general are bandwidth
limited. In an ad hoc network, it is all the more so because there is no
backbone to handle or multiplex higher bandwidth
• Routing: Routing in a mobile ad hoc network is complex. This
depends on many factors, including finding the routing path,
selection of routers, topology, protocol etc. 250
Applications of MANETS
• The set of applications for MANETs is diverse,
ranging from small, static networks that are
constrained by power sources, to large-scale, mobile,
highly dynamic networks.
• The design of network protocols for these networks is
a complex issue. Regardless of the application,
MANETs need efficient distributed algorithms to
determine network organization, link scheduling, and
routing. Some of the main application areas of
MANET‘s are:

251
252
Applications of MANETS
• Military battlefield– soldiers, tanks, planes. Ad- hoc networking
would allow the military to take advantage of commonplace
network technology to maintain an information network between
the soldiers, vehicles, and military information headquarters.
• Sensor networks – to monitor environmental conditions over a
large area
• Local level – Ad hoc networks can autonomously link an instant
and temporary multimedia network using notebook computers or
palmtop computers to spread and share information among
participants at e.g. conference or classroom. Another
appropriate local level application might be in home networks
where devices can communicate directly to exchange
information.

253
• Personal Area Network (PAN) – pervasive computing i.e. to
provide flexible connectivity between personal electronic
devices or home appliances. Short-range MANET can simplify
the intercommunication between various mobile devices (such
as a PDA, a laptop, and a cellular phone). Tedious wired cables
are replaced with wireless connections. Such an ad hoc network
can also extend the access to the Internet or other networks by
mechanisms e.g. Wireless LAN (WLAN), GPRS, and UMTS.
• Vehicular Ad hoc Networks – intelligent transportation i.e. to
enable real time vehicle monitoring and adaptive traffic control

254
• Civilian environments – taxi cab network, meeting rooms,
sports stadiums, boats, small aircraft
• Emergency operations – search and rescue, policing and fire
fighting and to provide connectivity between distant devices
where the network infrastructure is unavailable. Ad hoc can be
used in emergency/rescue operations for disaster relief efforts,
e.g. in fire, flood, or earthquake. Emergency rescue operations
must take place where non-existing or damaged communications
infrastructure and rapid deployment of a communication network
is needed. Information is relayed from one rescue team member
to another over a small hand held.

255
Routing in MANET‘s
• Routing in Mobile Ad hoc networks is an important issue as these networks do
not have fixed infrastructure and routing requires distributed and cooperative
actions from all nodes in the network. MANET‘s provide point to point
routing similar to Internet routing.
• The major difference between routing in MANET and regular internet is the
route discovery mechanism. Internet routing protocols such as RIP or OSPF
have relatively long converge times, which is acceptable for a wired network
that has infrequent topology changes. However, a MANET has a rapid
topology changes due to node mobility making the traditional internet routing
protocols inappropriate.
• MANET-specific routing protocols have been proposed, that handle topology
changes well, but they have large control overhead and are not scalable for
large networks.
• Another major difference in the routing is the network address. In internet
routing, the network address (IP address) is hierarchical containing a network
ID and a computer ID on that network. In contrast, for most MANET‘s the
network address is simply an ID of the node in the network and is not
hierarchical. The routing protocol must use the entire address to decide 256the
next hop.
Some of the fundamental differences between
wired networks & ad-hoc networks are:
• Asymmetric links: - Routing information collected for one direction is of
no use for the other direction. Many routing algorithms for wired networks
rely on a symmetric scenario.
• Redundant links: - In wired networks, some redundancy is present to
survive link failures and this redundancy is controlled by a network
administrator. In ad-hoc networks, nobody controls redundancy resulting in
many redundant links up to the extreme of a complete meshed topology.
• Interference: - In wired networks, links exist only where a wire exists, and
connections are planned by network administrators. But, in ad-hoc
networks links come and go depending on transmission characteristics, one
transmission might interfere with another and nodes might overhear the
transmission of other nodes.
• Dynamic topology: - The mobile nodes might move in an arbitrary manner
or medium characteristics might change. This result in frequent changes in
topology, so snapshots are valid only for a very short period of time. So, in
ad-hoc networks, routing tables must somehow reflect these frequent 257
changes in topology and routing algorithms have to be adopted.
Summary of the difficulties faced for
routing in ad-hoc networks
• Traditional routing algorithms known from wired networks will
not work efficiently or fail completely. These algorithms have not
been designed with a highly dynamic topology, asymmetric links,
or interference in mind.
• Routing in wireless ad-hoc networks cannot rely on layer three
knowledge alone. Information from lower layers concerning
connectivity or interference can help routing algorithms to find a
good path.
• Centralized approaches will not really work, because it takes too
long to collect the current status and disseminate it again. Within
this time the topology has already changed.

258
Summary of the difficulties faced for
routing in ad-hoc networks
• Many nodes need routing capabilities. While there might be some
without, at least one router has to be within the range of each
node. Algorithms have to consider the limited battery power of
these nodes.
• The notion of a connection with certain characteristics cannot
work properly. Ad-hoc networks will be connectionless, because
it is not possible to maintain a connection in a fast changing
environment and to forward data following this connection.
Nodes have to make local decisions for forwarding and send
packets roughly toward the final destination.
• A last alternative to forward a packet across an unknown topology
is flooding. This approach always works if the load is low, but it
is very inefficient. A hop counter is needed in each packet to
avoid looping, and the diameter of the ad-hoc network. 259
Routing Algorithms
– Always maintain routes:- Little or no delay for route
determination
– Consume bandwidth to keep routes up-to-date
– Maintain routes which may never be used
– Advantages: low route latency, State information, QoS
guarantee related to connection set-up or other real-time
requirements
– Disadvantages: high overhead (periodic updates) and route
repair depends on update frequency

260
only obtain route information when needed
– Advantages: no overhead from periodic update, scalability as
long as there is only light traffic and low mobility.
– Disadvantages: high route latency, route caching can reduce
latency

• Hybrid algorithms: maintain routes to nearby nodes even if they


are not needed and maintain routes to far away nodes only when
needed. Example is Zone Routing Protocol (ZRP).

261
Destination sequence distance vector
(DSDV)
• Destination sequence distance vector (DSDV) routing is an
example of proactive algorithms and an enhancement to distance
vector routing for ad-hoc networks.
• Distance vector routing is used as routing information protocol
(RIP) in wired networks. It performs extremely poorly with
certain network changes due to the count-to-infinity problem.
• Each node exchanges its neighbor table periodically with its
neighbors. Changes at one node in the network propagate slowly
through the network.
• The strategies to avoid this problem which are used in fixed
networks do not help in the case of wireless ad-hoc networks, due
to the rapidly changing topology. This might create loops or
unreachable regions within the network.
262
Security in MANET’s
• Securing wireless ad-hoc networks is a highly challenging issue.
• Understanding possible form of attacks is always the first step
towards developing good security solutions.
• Security of communication in MANET is important for secure
transmission of information.
• Absence of any central co-ordination mechanism and shared
wireless medium makes MANET more vulnerable to
digital/cyber attacks than wired network there are a number of
attacks that affect MANET.

263
These attacks can be classified into two types:
• 1. External Attack:
– External attacks are carried out by nodes that do not belong to
the network.
– It causes congestion sends false routing information or causes
unavailability of services.
• 2. Internal Attack:
– Internal attacks are from compromised nodes that are part of
the network. In an internal attack the malicious node from the
network gains unauthorized access and impersonates as a
genuine node.
– It can analyze traffic between other nodes and may participate
in other network activities.

264

You might also like