Uploaded by sarah al.r

L1-Introduction-(1)

advertisement
Introduction of Distributed
Systems
CSC 361
Qassim University
Computer Science Department
By
Reham Althunyan
George Coulouris, Jean Dooimore, Tim Kindberg, Distributed Systems:
Concepts and Design (Fifth edition), Addison-Wesley publishers Limited, 2012
Chapter 1: Characterization of Distributed Systems
◼
◼
◼
◼
◼
Introduction
Examples of distributed systems
Resource sharing and the web
Challenges
Summary
Distributed System: Definition
General definition:
◼
A distributed system is one in which hardware or
software components located at networked
computers communicate and coordinate their
actions only by passing messages.
‫ امللفات تكون مخزنه على االنترنت‬..‫ الدروب بوكس‬، ‫اكبر مثال عليه االنترنت‬
‫تعريف واسع وعام جدا تدخل فيه اشياء كثيره جدا‬
Distributed System: Definition
◼
A distributed system is a piece of software that ensures
that:
◼
◼
a collection of independent computers appears to its users as a
single coherent system
Two aspects
◼
Text
(1) independent computers and (2) single system =>
middleware.
Characters of Distributed System
‫مهم ويجي باالختبارات‬
◼
◼
◼
Concurrency of components
• Concurrent programs execution
• Sharing resources
No global clock
• programs cooperate by coordinating their actions
and exchanging messages.
• No single global notion of the correct time.
Independent failures of components.
• The failure of a computer or program somewhere
is not known to others.
Motivation of DS : Share resources
◼
◼
◼
It characterizes the range of the things that can usefully
be shared in a networked computer system.
It extends from hardware components such as disks and
printers to software-defined entities such as files,
databases and data objects.
It includes the stream of video frames that emerge from
a digital video camera and the audio connection from a
mobile phone.
Examples of distributed systems
◼
◼
◼
◼
The Internet
intranet
Mobile and ubiquitous computing
Distributed Computing as a Utility
Internet
◼
◼
◼
It is a vast interconnected collection of computer
networks of many different types.
It is a very large distributed system that allows users,
whenever they are, to make use of services such as web,
email and file transfer.
Internet protocols is a major technical achievement,
enabling a program running anywhere to address
messages to programs anywhere else.
Internet
intranet
◼
◼
◼
An intranet is a portion of the Internet that is separately
administered and has a boundary that can be configured
to enforce local security policies.
Composed of several Local Area Networks (LANs) linked
by backbone connections.
It is connected to the Internet via a router to make use
of services such as web, email or FTP.
intranet
intranet
◼
◼
A firewall is to protect an intranet by preventing
unauthorized messages leaving or entering the
network.
Issues to consider when designing an intranet :
•
•
•
File services : to enable users to share data.
Firewall : tend to impede legitimate access.
The cost of software installation and support.
Mobile and ubiquitous computing
◼
◼
Laptop computers
Handheld devices
•
◼
Wearable devices
•
◼
Personal digital Assistants (PDAs), mobile and smart phones,
pagers, video cameras and digital cameras.
Smart watches.
Embedded devices
•
Washing machines, hi-fi systems, cars and refrigerators.
Portable and handheld devices in a distributed
systems
Mobile and ubiquitous computing
◼
Mobile computing
•
•
◼
Is the performance of computing tasks while the user
is on the move.
Location-aware computing: utilize resources such as
printers that are conveniently nearby.
Ubiquitous computing
•
The harnessing of many small, cheap computational
devices that are present in users’ physical environment
(home, office or elsewhere).
Issues to Consider on Mobile Computing
◼
◼
◼
◼
Support for discovery of resources in a host environment.
Eliminating the need for users to reconfigure their mobile
devices as they move around.
Helping users to cope with limited connectivity as they
travel.
Providing privacy and other security guarantees to users
and the environment they visit.
Distributed Computing as a Utility :Cloud
Computing
◼
Physical Resources
•
◼
Storage and processing can be made available to networked
computers , removing the needs to own such resources.
Software Service
•
Can be made available across the global Internet. Many
companies now offer a comprehensive range of services for
effective rental.
Distributed Computing as a Utility :Cloud
Computing
◼
Cloud Computing
•
•
•
◼
The vision of computing as utility.
A set of Internet-based applications , storage and computing
services sufficient to support most users’ need.
Implemented on cluster computers to provide necessary
scale and performance required by such services.
Cluster Computers
•
•
A set of interconnected computers that cooperate closely to
provide a single , integrated high-performance capability .
The overall goal of cluster computers to provide a range of
cloud services, including high-performance computing
capabilities, mass storage, rich application services.
Distributed Computing as a Utility :Cloud
Computing
Resource sharing and the web
‫بكل اختبار يجيييي‬
◼
◼
The primary motivation of distributed systems is
resource sharing.
Types of Resources
•
Hardware (printers, scanners or cameras)
Data (files, databases or web pages)
•
More specific functionality (search engines)
•
Resource sharing and the web
Definitions :
◼
Service
A distinct part of a computer system that manages a collection of
related resources and presents their functionality to users and
applications.
•
◼
Server
A running program (process) on a networked computer that
accepts requests from programs running on other computers to
perform a service and responds appropriately.
•
◼
Client
•
Is the requesting process from the server.
Resource sharing and the web
Definitions :
◼
Remote invocation
•
◼
◼
A complete interaction between a client and a server, from
the point when the client sends its request to when it
receives the server’s response.
Clients are active and servers are passive; servers
run continuously, whereas clients last only as the
applications of which they form a part.
Web browser is an example of a client that
communicates with a web server, to request a web
page.
The World Wide Web
▪
Is an evolving system for publishing and accessing
resources and services across the Internet.
▪
Purpose of WWW
▪
▪
Exchanging documents between physicists of European center for
nuclear research (CERN), 1989.
Provides hypertext structure among the documents that it stores to
link to other documents and resources in the web.
The World Wide Web
▪
The Web is an open system that can be extended and
implemented in new ways without disturbing its
existing functionality:
1.
2.
Its operation is based on communication standards and document
standards that are freely published and widely implemented.
With respect to the types of ‘resource’ that can be published and
shared on it.
The Web components:
The HyperText Markup Language (HTML)
▪
▪
A language for specifying the contents and layout of pages as they are
displayed by web browsers
Uniform Resource Locators (URLs)
▪
▪
Identify documents and other resources stored as part of the Web.
A client-server system architecture using Hyper Text
Transfer Protocol (HTTP)
▪
▪
By which browsers and other clients fetch documents and other
resources from web servers.
The Web components:
HyperText Markup Language (HTML)
⚫
⚫
⚫
HTML is used to specify the text and images that make up
the contents of a web page, and to specify how they are laid
out and formatted for presentation to the user.
HTML is stored in a file that web server can access.
A browser retrieves the contents of this file from a web server.
-The browser reads the contents returned by the server and renders it
into formatted text and images on the web page.
-The server can infer the content type from the filename extension
‘.html’.
HyperText Markup Language (HTML)
<IMG SRC = http://www.cdk3.net/WebExample/Images/earth.jpg>
<P>
Welcome to Earth! Visitors may also be interested in taking a look at the
<A HREF = “http://www.cdk3.net/WebExample/moon.html>Moon</A>.
<P>
(etcetera)
▪ A browser retrieves the contents of this file (earth.html) from a web
server.
▪ The browser reads the contents returned by the server
and renders it into formatted text and images on the web page.
▪ The server can infer the content type from the filename
extension ‘.html’.
Uniform Resource Locator (URL)
To identify a resource in such away as to enable the browser to locate the
resource.
Every URL has two top-level components :
▪
▪
▪
▪
▪
Scheme: scheme-specific-location
Scheme declares which type of URL this is.
◼mailto:joe@anISP.net : a user email address
ftp://ftp.downloadIt.com/software/a9Prog.exe : a file that is to be retrieved using
File Transfer Protocol (FTP)
nntp : usenet news group, telnet : to log in to a computer
HTTP URLs are the most widely used protocol.
▪
▪
▪
▪
Identify which web server maintains the resource.
Which of the resources at the server is required.
http://servername [:port][PathNameOnServer][?arguments]
HyperText Transfer Protocol (HTTP)
Defines the ways in which browsers and any other types of client
interact with web servers.
HTTP features :
▪
▪
▪
▪
▪
▪
Request-reply interactions
Content types. (GIF,JPEG, Text/html) the strings that denote the type of
content are called MIME
One resource per request. (HTTP version 1.0)
▪
9 images = 10 requests.
Simple access control : e.g. Password
Advanced Features – Services and Dynamic pages.
Dynamic content
▪
▪
Common Gateway Interface (CGI): a program that web servers run to generate
content for their clients.
Downloaded code
▪
▪
▪
JavaScript : immediate feedback
Applet : Chat applications
Discussion of the Web
▪
Web is a Hypertext Model that is lacking in some respects :
1. A resource is deleted or moved, but links to it may still remain
(dangling).
2. Resource Description Framework is to standardize the format of
metadata about web resources to find data easily.
3. Extensible Markup Language (XML) : A way of representing data in
standard, structured, application- specific forms rather than HTML.
4. Scalability: popular web servers may experience many ‘hits’ per second,
which results in slow response.
Challenges:
▪
▪
▪
▪
▪
▪
▪
Heterogeneity
Openness
Security
Scalability
Failure handling
Concurrency
Transparency
Challenges : Heterogeneity
Networks
▪
▪
IP over Ethernet, token ring
Computer hardware
▪
▪
Different representation for Data types (byte ordering of Integers)
Operating systems
▪
▪
Exchanging messages in Unix are different from Windows
Programming languages
▪
▪
Different representations for characters and data structures such as arrays and
records.
Implementations by different developers
▪
▪
No common standards in writing applications.
Challenges : Heterogeneity
◼
Middleware
◼
◼
◼
Applies to a software layer that provides a programming abstraction as
well as masking the heterogeneity of the underlying networks, hardware,
operating systems and programming languages.
It provides a uniform computational model for use by the programmers
of servers and distributed application to solve the problem of
heterogeneity.
Mobile code
◼
is used to refer to code that can be sent from one computer to another
and run at the destination (Java applet, Java Virtual Machine)
Challenges : Openness
Openness of a computer system
▪
▪
Is the characteristic that determines whether the system can be extended and reimplemented in various ways.
Openness of distributed systems
▪
▪
Is determined primarily by the degree to which new resource- sharing services can
be added and be made available for use by a variety of client programs.
How to deal with openness?
▪
▪
Key interfaces are published, e.g. Request for Comments (RFC)
Challenges : Security
▪ Confidentiality
▪ protection against disclosure to unauthorized individuals,
▪
ACL in Unix File System
▪ Integrity
▪ protection against alteration or corruption,
▪
Checksum, encryption
▪ Availability
▪ protection against interference with the means to access the resources,
▪ Denial of service, security of mobile code
Challenges : Scalability
▪
A system is described as scalable if will remain effective when there is
a significant increase in the number of resources and the number of
users
▪
The Internet provides an illustration of scalable system
Challenges : Scalability
▪ Design challenges
▪Controlling the cost of physical resources, system with (n) users requires
at most O(n) physical resources.
▪Controlling the performance loss, DNS no worse than O(logn)
▪Prevent software resources running out, e.g., IP address
▪Avoid performance bottlenecks, e.g., partitioning name table of DNS, cache and
replication
Challenges : Failure handling
Failure in distributed systems are partial, some components
fail while others continue to function.
▪
Detecting failure
▪
▪
▪
Checksum for corrupted data
Sometimes impossible to detect, e.g. a remote crashed server in the Internet
Masking failure
▪
▪
Retransmit message when they fail to arrive.
Tolerating failure
▪
▪
A web browser cannot contact a web server
Recovery from failure
▪
▪
State of permanent data can be recovered or Rolled back
Redundancy
▪
▪
Routes in the Internet, replicated name table of DNS
Challenges : Concurrency
• Correctness
– ensure the operations on shared resource correct in a concurrent
environment
e.g. records bids for an auction
• Performance
– Ensure the high performance of concurrent operations
Challenges : Transparency
▪ The concealment from the user and the application
programmer of the separation of components in a distributed
system.
▪ Access transparency
▪ Enable local and remote resources to be accessed using identical operations, e.g. GUI
▪ Location transparency
▪ resources to be accessed without knowledge of their location, e.g. URL
▪ Concurrency transparency
▪ several processed operate concurrently using shared resources without interference
between them.
Challenges : Transparency
▪ Replication transparency
▪ multiple instances of resources to be used to increase reliability and performance
without knowledge of the replicas by users or application programmers,
▪ Failure transparency
▪ users and applications to complete their tasks despite the failure of hardware and
software components, e.g., email
▪ Mobility transparency
▪ movement of resources and clients within a system without affecting the
operation of users and programs, e.g., mobile phone
▪ Performance transparency
▪ allows the system to be reconfigured to improve performance as loads vary.
▪ Scaling transparency
▪ allows the system and applications to expand in scale without change to the
system structure or the application algorithms
Summary
• Distributed systems are pervasive
• Resource sharing is the primary motivation
for constructing distributed systems
• Characterization of Distributed System
– Concurrency
– No global clock
– Independent failures
Summary
• Challenges to construct distributed system
–
–
–
–
–
–
–
Heterogeneity
Openness
Security
Scalability
Failure handling
Concurrency
Transparency
Download