distributed system (18790)

20
i Hochschule Rhein-Waal Rhine-Waal University of Applied Sciences Faculty of Communication and Environment Degree Program Information Engineering and Computer Science, M. Sc. Mr. Adnan Mirza P2P in Mobile Environments Term Paper SS 2014/2015 Module “Distributed System” By Muhammad Ahsan Nawaz (Matriculation Number: 18790)

Upload: ahsan-nawaz

Post on 15-Jan-2017

45 views

Category:

Documents


3 download

TRANSCRIPT

i

Hochschule Rhein-Waal

Rhine-Waal University of Applied Sciences

Faculty of Communication and Environment

Degree Program Information Engineering and Computer Science, M. Sc.

Mr. Adnan Mirza

P2P in Mobile Environments

Term Paper

SS 2014/2015

Module “Distributed System”

By

Muhammad Ahsan Nawaz (Matriculation Number: 18790)

ii

Abstract In today’s world peer to peer networks and their application used & gaining a lot of importance

in the networking field. Right now most of the IP traffic is caused by P2P applications. There

are a lot of search has been done in peer to peer and their application and found many of the

result which is very beneficial for new search era. The research is still going and there are

growing demands like less data rate consumption, faster and more reliable search responses and

the development of application attracts many of researchers all over the world. In this research

paper we will discuss about the communication of peer to peer in a mobile environment is

presented. First of all, we discussed about the peer to peer network why it is very famous in

networking and after that we will discuss about the peer to peer in mobile environment. There

are many challenges related to mobile peer to peer (MPTP) networks and after that there are

some solution related to mobile peer to peer. However, the approach we used in not limited to

any specific communication technology. There is one solution related to MPTP we discussed in

this paper is JXTA software.

Keywords: Mobile Peer to Peer (MPTP), Mobile environment, Peer to Peer, Juxtapose (JXTA)

iii

Table of Contents

Abstract ........................................................................................................................................... ii

1. Introduction ........................................................................................................................... 1

1.1. History ............................................................................................................................. 2

1.2. Advantages ...................................................................................................................... 3

1.3. Weakness ......................................................................................................................... 3

1.4. Mobile Peer to Peer ........................................................................................................ 4

2. Peer to Peer communication in Mobile Environment ........................................................ 5

2.1. Requirements of MPTP ................................................................................................. 7

2.2. Challenges of MPTP Environment ............................................................................... 8

2.2.1. Characteristics of wireless mobile communications ............................................ 8

2.2.2. Peer to Peer searches and Peer discovery in MANET......................................... 8

2.3. Solution of Mobile Peer to Peer .................................................................................... 9

2.3.1. JXTA software Architecture .................................................................................. 9

2.3.2. JXTA Network Architecture ............................................................................... 11

2.3.3. JXTA Design Constraints..................................................................................... 11

2.3.4. JXTA Technology Protocols ................................................................................ 12

1. Summary & Outlook ........................................................................................................... 14

References ..................................................................................................................................... 15

Appendix/Glossary ....................................................................................................................... 16

iv

List Of Figures

Figure 1: Peer to Peer Network ------------------------------------------------------------------------------ 1

Figure 2: Peer to Peer System ------------------------------------------------------------------------------- 2

Figure 3: Weak point of Client-Server --------------------------------------------------------------------- 4

Figure 4: Mobile Peer to Peer Network -------------------------------------------------------------------- 5

Figure 5: Peer to Peer in mobile environment ------------------------------------------------------------- 6

Figure 6: JXTA Software Architecture -------------------------------------------------------------------- 10

Figure 7: JXTA Network Architecture -------------------------------------------------------------------- 11

1

1. Introduction

In Peer to Peer networks, every machine which is related to networking plays a vital role of

client, server simultaneously. However a peer to peer network has a number of pros. Over the

traditional client-server model in terms of efficiency, fast speeding, fault tolerance, additional

security threats can be introduced. Users & IT administrators need to be aware of the risks from

propagation of malicious code, the legality of downloaded content & vulnerabilities within peer

to peer software. For end-users and/or home users, precautions must also be taken to avoid the

possible spread of viruses over peer-to-peer networks. In peer to peer network peer can initiate

requests to other peers & at the same time respond to incoming requests from other peers on the

network. This procedure is totally differs from the traditional client-server model where client

can send a request to server and then waits for the server’s response.

Figure 1: Peer to Peer Network

Source: https://academiccollegeprojects.com/wp-content/uploads/2015/07/Peer-to-Peer-Network-Projects-with-Expert-support.jpg

In figure 1 it is clearly mentioned how a peer to peer networks work each other. Every work

station is connected to one hub and for the other workstation there are other devices attached

2

like; printer, scanner, etc. In peer to peer exchange, both devices are considered equal in the

communication process.

1.1. History

In this part, i will describe about some background of the peer to peer network. The first software

dedicated to P2P network is napster (Fanning). Napster was the name given to two music-

focused online services. It was originally founded as a pioneering Peer to Peer (P2P) file sharing

internet service that emphasized sharing audio files, typically music, encoded in MP3 format. [1]

In peer to peer network it speeded broadband & Asymmetric digital subscriber line (ADSL)

increasingly accessible. Peer-to-peer networking has often been considered as the ―new-comer‖

of the computer communication family while the client/server file-share scheme has been the

―incumbent.‖ Right now the Peer to Peer network is growing successfully almost in every field

of life especially which is related to sharing contents or even used internet. Peer to peer network

system mostly looks like:

Figure 2: Peer to Peer System

Source: http://www.codeproject.com/KB/WCF/614028/pto1.png

3

In figure 2: Peer to Peer system it is clearly mentioned how one system is interrelated to each

other and how different people get in touched with each other. It is a clear diagram for peer to

peer model.

1.2. Advantages

In this part, i will describe a little bit about the many of advantages of Peer to Peer networks

Such as:

It is easy to install and so is the configuration of computers on this network,

All the resources and contents are shared by all the peers, unlike server-client

architecture where Server shares all the contents and resources.

P2P is more reliable as central dependency is eliminated. Failure of one peer doesn’t

affect the functioning of other peers. In case of Client –Server network, if server goes

down whole network gets affected.

There is no need for full-time System Administrator. Every user is the administrator of

his machine. User can control their shared resources.

The over-all cost of building and maintaining this type of network is comparatively very

less.

Extreme tolerance in the event of failure. [2]

The overall cost of building such types of networks are very less.

1.3. Weakness

In this network, the whole system is decentralized thus it is difficult to administer. That is

one person cannot determine the whole accessibility setting of whole network.

Security in this system is very less viruses, spywares, Trojans; etc malwares can easily

transmit over this P-2-P architecture.

Data recovery or backup is very difficult. Each computer should have its own back-up

system

Lot of movies, music and other copyrighted files are transferred using this type of file

transfer. P2P is the technology used in torrents.

4

Figure 3: Weak point of Client-Server

Source: http://photos1.blogger.com/blogger/7414/2124/1600/lwa11150.jpg

Peer to peer networks are good to connect small number (around 10) of computer and places

where high level of security is not required. In case of business network where sensitive data can

be present this type of architecture is not advisable or preferred. [2]

1.4. Mobile Peer to Peer

In this section I will discussed about the mobile peer to peer network. Now days the systems we

are using are mostly wired based system. Mobile ad hoc network is characterized as multihop

wireless communications between mobile devices. In mobile peer to peer network data

transferred through one mobile phone device to another. Mobile phone & network limits the

possibilities of mobile peer to peer such as:

Low efficiency

Low Bandwidth

Low power

Billing

5

Figure 4: Mobile Peer to Peer Network

Source: http://proj.ncku.edu.tw/research/articles/e/20071109/images/a0010_1.jpg

Figure 4 describe the peer to peer network for mobile networks.

2. Peer to Peer communication in Mobile Environment

If we can talk about peer to peer in fixed network there are several approaches exist. But I will

let you know only three different approaches, i.e. Napster model, Power server model and CPU

power sharing model. But it’s a fact that these approaches do not take advantage of the mobile

environment. There are still some approaches exist to the mobile peer to peer communication.

First, peer to peer network used in traffic-intensive for instance; (Gnutella, BitTorrent, former

napster), since they have traffic is between the peers and there is no central server limiting the

total traffic in the network. Secondly, there is Peer to Peer internet telephony for example; Skype

that is analogous to the first application. In Skype voice or video streaming correspond to the

files. Thirdly, Peer to Peer networks can be used also for less traffic information search and

sharing purposes for instance; Gnutella. [2]

6

Simultaneously, the capabilities of mobile devices are constantly evolving. Their usage and the

number of usage are increasing. So there is one question raised on it about adopting the Peer to

Peer model into the mobile environment, too. Despite the constant evolution of the mobile

devices, the mobile environment is still very limited when compared to the fixed Internet. Mobile

devices have limited networking capabilities, storage, electrical power and processing power. In

addition to this, the mobile environment architectures set limitations on mobile applications. [2]

Figure 5: Peer to Peer in mobile environment

Source: http://core0.staticworld.net/images/idge/imported/article/jvw/2001/10/jw-1019-jxta2-100157482-orig.gif

Figure 5 reveals the information of client/server network grows. The pressure on the central point, the

server increases. Peer to Peer network might consist of peer with different capabilities, from mobile

devices to mainframes. A mobile peer cannot be able to act as a server due to intrinsic limitations, even

though the network does not restrict it in any way.

7

2.1. Requirements of MPTP

Here are some requirements related to MPTP such as:

Technical Constraints

Access Network Parameters

Special Needs of Mobile Environment

User Requirements

In this report we will discuss every requirement one by one here is the brief information related

to every requirement.

Technical Requirement

o Memory Size

Memory size of mobile phone devices should be enough to store all of the

information

o CPU Performance

Performance of CPU plays a vital role by the technical constraints

o Screen & Keyboard size

Size of screen & keyboard is really important but now a days it is not a

problem because size of the screen is really big in different cell phone

devices

o Battery Capacity

Capacity of Battery is very important because how long the battery runs

that is better for MPTP. But now a days lithium battery used in cell phone

which increased the capacity of cell phone

Access Network Parameters

o Limited Bandwidth shared between multiple users in the same cell

Special Needs of Mobile Environment

o Support for various access networks

o Operator control

o Feasible Bandwidth pricing

8

User Requirements

o Quick Response times

o Rapid Downloads

o Group management features for sharing private contents

Lots of content is probably self-created, like picture/videos taken by

camera

2.2. Challenges of MPTP Environment

In this section we will go through the most important challenges of Mobile peer to peer

applications. We will cover the topics of general problems in wireless mobile communication,

Peer to peer searches and peer discovery in Mobile adhoc network (MANET), problems of 3G

and some factors affecting user behavior. While in MANET environment we discuss more about

technical problems, in 3G the focus includes also business models of network operators. The

main reason for different viewpoints is the fact that MANET is very new and more experimental

environment, which has more unsolved problems, whereas there already exists commercial 3G

networks. [2]

2.2.1. Characteristics of wireless mobile communications

As mentioned in section 2.1, the one of most challenging factors related to Mobile peer to peer

are the storage size of the device, power consumption, and electricity consumption & at the end

processing power of the mobile devices which is very important in mobile peer to peer devices.

Especially last three are very much independent from the underlying network environment.

Networking capabilities also depend on it. UMTS is an example of a 3G technology as well as

IEEE 802.11g is an example of a WLAN technology. IEEE 802.16a (WiMAX) is a wireless

metropolitan area network (MAN). [2]

2.2.2. Peer to Peer searches and Peer discovery in MANET

Peer to Peer networks have different architecture & topologies. While in every peer to peer the

main traffic occurs directly between the peers, some of the protocols require a central indexing

server to arbitrate information about availability & location of data or services. However, there

exist protocols not requiring any central server, called fully distributed P2P protocols. They are

more reliable and fault-tolerant, since they are not dependent on any single instance, but they still

9

have their own problems related to P2P searches and peer discovery. we will not explain in this

report because this report is more related to Mobile peer to peer so, now we will move further

and explains about the solution of Mobile Peer to Peer. In next section we will discuss about

JXTA.

2.3. Solution of Mobile Peer to Peer

There are many of solutions available related to Mobile peer to peer but I can explain only one

solution and that is called JXTA. JXTA (Juxtapose) is an open source peer to peer protocol

specification system made by sun microsystem in 2001. JXTA technology is a network

programming and computing platform that is designed to solve a number of problems in modern

distributed computing, especially in the area broadly referred to as peer-to-peer (P2P) computing

or P2P networking. JXTA provides a network programming platform specifically designed to be

the foundation for P2P systems. As a set of protocols, the technology stays away from APIs and

remains independent of programming languages. This means that heterogeneous devices with

completely different software stacks can interoperate through JXTA protocols. JXTA technology

is also independent of transport protocols. It can be implemented on top of TCP/IP, HTTP,

Bluetooth and many other protocols.

2.3.1. JXTA software Architecture

JXTA defines XML message formats, or protocols, for communication between peers. There are

three layers in JXTA:

Core Layer

Service Layer

Application Layer

In this report we will discuss shortly about core, service and application layer.

Core Layer

o Peer Groups: Used for create, delete, join, advertise, discover, communication,

security, sharing.

o Peer Pipes: Transfer of data, content and code in protocol independent way.

10

o Peer Monitoring: access control, priority setting, traffic metering, and bandwidth

balancing

Service Layer

o Service layer used for expanding core and facilitate application development.

o Mechanisms for indexing, searching and resource sharing

Application Layer

o Built using peer services as well as the core layer

o Emailing, auctioning and storage system

Figure 6: JXTA Software Architecture

Source: http://image.slidesharecdn.com/jxta-150618170638-lva1-app6892/95/jxta-11-638.jpg?cb=1434647231

11

2.3.2. JXTA Network Architecture

Figure 7: JXTA Network Architecture

Source: http://images.slideplayer.com/15/4806357/slides/slide_17.jpg

Figure 7 reveals network architecture of JXTA. In JXTA network architecture there are two

different layers one is related to JXTA virtual network & Physical Network.

2.3.3. JXTA Design Constraints

There is some design constraints related to JXTA:

Interoperability

o Software vendors tend to create specific code for their services e.g. file sharing,

instant messaging etc.

o Incomptible system

o Duplicate efforts

12

o JXTA attempts give peers a common language to talk to each other

Platform Independent

o Programming Languages, system platforms and network platforms44

Ubiquity

o Implements on every device with a digital heartbeat e.g. PDAs, phones, sensors,

consumer electronic appliances, network routers, desktop computers, data-center

servers, storage systems

o Avoid specific binding to platform

o Future proof e.g. Such technology should be extended to new platforms e.g.

Mobile phones

Security & Monitoring

o For commercial & enterprise deployment

2.3.4. JXTA Technology Protocols

There are two different types of protocols:

1. Core Specification Protocols

In core specification protocols there are two different protocols.

Peer Resolver Protocol (PRP)

Enables a peer to send and receive generic queries to search for peers, peer groups, pipes, and

other information. Typically, this protocol is implemented only by those peers that have access to

data repositories and offer advanced search capabilities. [4]

Endpoint Routing Protocols (ERP)

Allows a peer to ask a peer router for available routes for sending a message to a destination

peer. For example, when two communicating peers are not directly connected to each other, such

as when they are not using the same network transport protocol or when they are separated by

firewalls or NATs, peer routers respond to queries with available route information—that is, a

list of gateways along the route. Any peer can decide to become a peer router by implementing

the Peer Endpoint Protocol. [4]

13

2. Standard Service Protocol

In standard service protocol there are many protocols involved in it. We will try to discuss all of

them in this report.

Peer Information Protocol

Allows a peer to learn about the capabilities and status of other peers. For example, a ping

message can be sent to see if a peer is alive. A query can also be sent regarding a peer’s

properties where each property has a name and a value string. [4]

Peer Discovery Protocol

Enables a peer to find advertisements on other peers and can be used to find any of the peer, peer

group, or advertisements. This protocol is the default discovery protocol for all peer groups,

including the World Peer Group. It is conceivable that someone might want to develop a

premium discovery mechanism that might or might not choose to leverage this default protocol,

but the inclusion of this default protocol means that all JXTA peers can understand each other at

the very basic level. [4]

Peer Membership Protocol

Allows a peer to obtain group membership requirements, to apply for membership and receive a

membership credential along with a full group advertisement, to update an existing membership

or application credential, and to cancel a membership or an application credential. Authenticators

and security credentials are used to provide the desired level of protection. [4]

14

1. Summary & Outlook

In this paper we have discussed different challenges of mobile peer to peer applications,

presented one solution to them and speculated their future usage. We research on JXTA software

which is one of the best solutions related to Mobile Peer to Peer. A peer-to-peer network is a

decentralized network where all participating nodes act as a client and a server at the same time.

A mobile peer-to-peer network differs from fixed peer-to-peer network in some ways. The

differences provide possibilities and limitations. These limitations create some problems to

porting the services directly from the fixed peer to peer networks to mobile networks. Third

generation technologies provide possibilities to implement new services to mobile peer-to-peer

networks. The main problems in the mobile peer-to-peer network are the same as in fixed

Internet: Intellectual property rights and economic values are the main concern when the service

providers design the applications. Control chips in devices and hybrid peer-to-peer networks are

answers to some of these problems. If some peer-to-peer standards were created and they would

work also with a mobile ad-hoc network, more applications could be developed more easily and

some problems could be solve [3]

15

References

[1] Wikipedia, ―Napste: An overview‖ Available: https://en.wikipedia.org/wiki/Napster

[Accessed July 3, 2016]

[2] Liia Sarjakoski ―Challenges of Mobile Peer to Peer applications in 3G and MANET

Environments - Introduction‖ April, 2005 [Online]. Available:

http://www.tml.tkk.fi/Publications/C/18/sarjakoski.pdf [Accessed July 3, 2016]

[3] Minttu Mustonen ―Mobile Peer-to-Peer Applications - possibilities and challenges brought

by mobility‖ Available: http://www.tml.tkk.fi/Publications/C/18/mustonen.pdf [Accessed July 7,

2016]

[4] Li Gong ―JXTA: A Network Programming Environment‖ – JXTA Technology Protocols

Available:

http://ieeexplore.ieee.org/xpl/articleDetails.jsp?tp=&arnumber=935182&url=http%3A%2F%2Fi

eeexplore.ieee.org%2Fiel5%2F4236%2F20242%2F00935182 [Accessed July 8, 2016]

I used two research papers while writing this report:

[1] Jari Porras, Petri Hiirsalmi and Ari Valtaoja ―Peer-to-peer Communication Approach for a

Mobile Environment‖ - Available: http://folk.uio.no/paalee/referencing_publications/ref-vd-

porras-hicss04.pdf [Accessed July 1, 2016]

[2] Liia Sarjakoski ―Challenges of Mobile Peer-to-Peer Applications in 3G and MANET

Environments‖ – Available: http://www.tml.tkk.fi/Publications/C/18/sarjakoski.pdf [Accessed

July 3, 2016]

16

Appendix/Glossary

JXTA Juxtapose

MPTP Mobile Peer to Peer

Napster Music Focused online service provider

Gnutella possibly by analogy with the GNU Project

WiMAX wireless metropolitan area network