Вы находитесь на странице: 1из 58

|  |

  

   
`    
  
˜ What a distributed database management
system (DDBMS) is and what its components
are
˜ How database implementation is affected by
different levels of data and process distribution
˜ How transactions are managed in a distributed
database environment
˜ How database design is affected by the
distributed database environment
¦  
|  |   

   
˜ Distributed database management
system (DDBMS)

Ô Governs storage and processing of


logically related data over
interconnected computer systems
in which both data and processing
functions are distributed among
several sites
¦  |  
|   
   
  
˜ entralized database required that
corporate data be stored in a
single central site

˜ Dynamic business environment


and centralized database¶s
shortcomings spawned a demand
for applications based on data
access from different sources at
multiple locations
   |   

  
||
  
˜ Data are located near ³greatest demand´ site
˜ Faster data access
˜ Faster data processing
˜ Growth facilitation
˜ Improved communications
˜ Reduced operating costs
˜ User-friendly interface
˜ Less danger of a single-point failure
˜ Processor independence
||
|    
˜ omplexity of management and control
˜ Security
˜ Lack of standards
˜ Increased storage requirements
˜ Greater difficulty in managing the data
environment
˜ Increased training cost
|    
    
|  |   
    
    |  

   
˜ ^pplication interface
˜ Validation
˜ Transformation
˜ Query optimization
˜ Mapping
˜ I/O interface
˜ Formatting
˜ Security
˜ Backup and recovery
˜ DB administration
˜ oncurrency control
˜ Transaction management
    
|  
  
   
˜ Must perform all the functions of a
centralized DBMS

˜ Must handle all necessary


functions imposed by the
distribution of data and processing

˜ Must perform these additional


functions ?  ?to the end
user
!|  
|   
  

||
   
˜ Must include (at least) the following components:
Ô Com ? 
o ?? o
Ô ?
o  
 of?
 
Ô Comm  ? om 
Ô Transaction processor (or, application processor,
or transaction manager)
å Software component found in each computer that
requests data
Ô Data processor or data manager
å Software component residing on each computer
that stores and retrieves data located at the site
å May be a centralized DBMS
|  |   
    
|    
"|   
|   
 #   
 # |   |
˜ ^ll processing is done on single PU or host
computer (mainframe, midrange, or P)
˜ ^ll data are stored on host computer¶s local disk
˜ Processing cannot be done on end user¶s side of
the system
˜ Typical of most mainframe and midrange
computer DBMSs
˜ DBMS is located on the host computer, which is
accessed by dumb terminals connected to it
˜ ^lso typical of the first generation of single-user
microcomputer databases
 #   
 # |  
   

 #   
 # |  
|
˜ Multiple processes run on different
computers sharing a single data
repository
˜ MPSD scenario requires a network
file server running conventional
applications that are accessed
through a L^
˜ Many multi-user accounting
applications, running under a
personal computer network, fit

 #   
 # | 

 #   

 # |  



|
˜ Fully distributed database management system
with support for multiple data processors and
transaction processors at multiple sites
˜ lassified as either homogeneous or
heterogeneous
˜ Homogeneous DDBMSs
Ô Integrateonly one type of centralized DBMS
over a network

 #   

 # |  



|  
˜ Heterogeneous DDBMSs
Ô Integratedifferent types of centralized DBMSs
over a network
˜ Fully heterogeneous DDBMS
Ô Support different DBMSs that may even support
different data models (relational, hierarchical, or
network) running under different computer
systems, such as mainframes and
microcomputers
a  
|  
|     
|  |   
¦   ! 
˜ ^llow end user to feel like database¶s only
user
˜ Features include:
Ô Distribution transparency
Ô Transaction transparency
Ô Failure transparency
Ô Performance transparency
Ô Heterogeneity transparency
|    ¦   
˜ ^llows management of a physically dispersed
database as though it were a centralized
database
˜ Three levels of distribution transparency are
recognized:
Ô Fragmentation transparency
Ô Location transparency
Ô Local mapping transparency
 
¦   ! 
!  "   
¦    ¦   
˜ ½nsures database transactions will
maintain distributed database¶s
integrity and consistency
|  $% 
|  ¦    
˜ Distributed transaction
Ô an update or request data from several
different remote sites on a network
˜ Remote request
Ô Letsa single SQL statement access data to be
processed by a single remote database
processor
˜ Remote transaction
Ô ^ccesses data at a single remote site
|  $% 
|  ¦    
  
˜ Distributed transaction

Ô ^llows a transaction to reference


several different (local or remote)
DP sites

˜ Distributed request

Ô Lets a single SQL statement


reference data located at several
different local or remote DP sites
$ $%
$ ¦    
|  ¦   
|  $%
 |  
$%
|    
 
˜ Multisite, multiple-process
operations are much more likely to
create data inconsistencies and
deadlocked transactions than are
single-site systems
¦   



¦#   

˜ Distributed databases make it possible for a
transaction to access data at several sites
˜ Final OMMIT must not be issued until all
sites have committed their parts of the
transaction
˜ Two-phase commit protocol requires each
individual DP¶s transaction log entry be
written before the database fragment is
actually updated
 
¦   
&     
˜ Objective of query optimization
routine is to minimize total cost
associated with the execution of a
request
˜ osts associated with a request
are a function of the:
Ô ^ccess time (I/O) cost
Ô ommunication cost
Ô PU time cost
 ¦   
&       
˜ Must provide distribution transparency as well as
 transparency
˜ Replica transparency:
Ô DDBMS¶s ability to hide the existence of multiple
copies of data from the user
˜ Query optimization techniques:
Ô Manual or automatic
Ô Static or dynamic
Ô Statistically based or rule-based algorithms
|  |   
| 
˜ Data fragmentation:

Ô How to partition the database into fragments

˜ Data replication:

Ô Which fragments to replicate

˜ Data allocation:

Ô Where to locate those fragments and replicas


|  !     
˜ Breaks single object into two or more
segments or fragments

˜ ½ach fragment can be stored at any site over


a computer network

˜ Information about data fragmentation is


stored in the distributed data catalog (DD),
from which it is accessed by the TP to
process user requests
|  !     
  
˜ Horizontal fragmentation:
Ô Division of a relation into subsets (fragments)
of tuples (rows)
˜ Vertical fragmentation:
Ô Division of a relation into attribute (column)
subsets
˜ Mixed fragmentation:
Ô ombination of horizontal and vertical
strategies
 ¦
$
¦ 
a   !     
¦
$¦ 
 
¦ !   ¦
"   
[  !  
¦   

'!     

¦
$¦ 
|  $    
˜ Storage of data copies at multiple sites served
by a computer network

˜ Fragment copies can be stored at several sites


to serve specific information requirements

Ô an enhance data availability and response time

Ô an help to reduce communication and total


query costs
¦   

'!     

|  $   
$      
˜ Fully replicated database:
Ô Storesmultiple copies of database
fragment at multiple sites
Ô an be impractical due to amount of overhead
˜ Partially replicated database:
Ô Stores multiple copies of omdatabase
fragments at multiple sites
Ô Most DDBMSs are able to handle the partially
replicated database well
˜ Unreplicated database:
Ô Stores each database fragment at a single
site
Ô o duplicate database fragments
|     
˜ Deciding where to locate data
˜ ^llocation strategies:
Ô entralized data allocation
å ½ntire database is stored at one site
Ô Partitioned data allocation
å Database is divided into several disjointed parts
(fragments) and stored at several sites
Ô Replicated data allocation
å opies of one or more database fragments are
stored at several sites
˜ Data distribution over a computer network is
achieved through data partition, data
replication, or a combination of both
  ()||

˜ Way in which computers interact to form a
system

˜ Features a  of resources, or a client, and


a  ov  of resources, or a server

˜ an be used to implement a DBMS in which


the client is the TP and the server is the DP
  (  
˜ Less expensive than alternate minicomputer or
mainframe solutions
˜ ^llow end user to use microcomputer¶s GUI,
thereby improving functionality and simplicity
˜ More people with P skills than with mainframe
skills in the job market
˜ P is well established in the workplace
˜ umerous data analysis and query tools exist to
facilitate interaction with DBMSs available in the
P market
˜ onsiderable cost advantage to offloading
applications development from the mainframe to
powerful Ps
  (|    
˜ reates a more complex environment, in which
different platforms (L^ s, operating systems,
and so on) are often difficult to manage
˜ ^n increase in the number of users and
processing sites often paves the way for security
problems
˜ Possible to spread data access to a much wider
circle of userså increases demand for people with
broad knowledge of computers and softwareå
increases burden of training and cost of
maintaining the environment
)*)| +¦
   

|  |   
Local site independence
2 entral site independence
3 Failure independence
4 Location transparency
5 Fragmentation transparency
6 Replication transparency
7 Distributed query processing
8 Distributed transaction processing
9 Hardware independence
 Operating system independence
 etwork independence
2 Database independence
 
˜ Distributed database stores logically related
data in two or more physically independent
sites connected via a computer network
˜ Database is divided into fragments
˜ Distributed databases require distributed
processing
˜ Main components of a DDBMS are the
transaction processor and the data processor
   
˜ urrent database systems can be classified by
extent to which they support processing and
data distribution
˜ DDBMS characteristics are best described as a
set of transparencies
˜ ^ transaction is formed by one or more
database requests
˜ ^ database can be replicated over several
different sites on a computer network
˜ lient/server architecture refers to the way in
which two computers interact over a computer
network to form a system

Вам также может понравиться