Questions Bank 2020
Questions Bank 2020
database?
A. Software cost
B. Software complexity
C. Slow Response
D. Modular growth
Answer: Option D
The same DBMS is at each node and a central DBMS coordinates database
B.
access.
The same DBMS is used at each location and data are distributed across all
B.
nodes.
A different DBMS is used at each location and data are not distributed across
C.
all nodes.
A different DBMS is used at each location and data are distributed across all
D.
nodes.
Answer: Option D
Some of the columns of a relation are at different sites is which of the following?
A. Data Replication
B. Horizontal Partitioning
C. Vertical Partitioning
The required data are located in at least one nonlocal site and the distributed
B.
DBMS routes requests as necessary.
The required data are at one local site and the distributed DBMS passes the
C.
request to only the local DBMS.
The required data are located in at least one nonlocal site and the distributed
D.
DBMS passes the request to only the local DBMS.
Answer: Option B
A different DBMS is used at each location and data are not distributed across
C.
all nodes.
A different DBMS is used at each location and data are distributed across all
D.
nodes.
Answer: Option B
When using many nodes with different operating systems and DBMSs and
B.
database designs.
10. Storing a separate copy of the database at multiple locations is which of the
following?
A. Data Replication
B. Horizontal Partitioning
C. Vertical Partitioning
All of the attributes are sent from one site to another and then only the
B.
required rows are returned.
Only the joining attributes are sent from one site to another and then only the
C.
required rows are returned.
All of the attributes are sent from one site to another and then only the
D.
required rows are returned.
Answer: Option C
B. If the database fails at one site, a copy can be located at another site.
15. Which of the following is not one of the stages in the evolution of distributed DBMS?
A. Unit of work
True or false
1. With failure transparency, all of the actions of a transaction are committed or none of
them are committed.
A. True
B. False
Answer: Option A
2. Each site (or node) in a distributed system is subject to the same types of failure as
in a centralized system.
A. True
B. False
Answer: Option A
B. False
Answer: Option A
4. Synchronization for pull replication is less disruptive and occurs only when needed
by each site, not when a central master site thinks it is best to update.
A. True
B. False
Answer: Option A
B. False
Answer: Option B
7. An increasingly popular option for data distribution as well as for fault tolerance of
any database is to store a separate copy of the database at each of two or more
sites.
A. True
B. False
Answer: Option A
B. False
Answer: Option B
9. A distributed unit of work allows various statements within a unit of work to refer to
multiple remote DBMS locations.
A. True
B. False
Answer: Option A
B. False
Answer: Option A
HomeAptitudeLogicalVerbalCurrent
AffairsGKEngineeringInterviewOnline TestsPuzzles
11. Data replication is favored where most process requests are read-only and where
the data are relatively static.
A. True
B. False
Answer: Option A
12. The cost to perform a snapshot refresh may depend on whether the snapshot is
simple or complex.
A. True
B. False
Answer: Option A
B. False
Answer: Option A
14. In a semijoin, only the joining attribute is sent from one site to another, and then only
the required rows are returned.
A. True
B. False
Answer: Option A
B. False
Answer: Option A
1. In ………., one or more users/programs attempt to access the same data at the
same time.
A. concurrency
B. transaction control
C. locking
D. two-phase locking
2. A mechanism which ensures that simultaneous execution of more than one
transaction does not lead to any database inconsistencies is called ………………
mechanism.
A. transaction control
B. transaction management
C. concurrency parallelism
D. concurrency control
3. The transaction wants only to read the data item of the mode is called as …….
A. Exclusive Mode
B. Shared Mode
C. Inclusive Mode
D. Unshared Mode
4. Commit and rollback are related to ……….
A. data integrity
B. data consistency
C. data sharing
D. data security
5. The transaction wants to edit the data item is called as …….
A. Exclusive Mode
B. Shared Mode
C. Inclusive Mode
D. Unshared Mode
6. For committing a transaction, the DBMS might discard all the records.
A. after image
B. before image
C. log
D. redo log
7. A sophisticated locking mechanism is known as 2-phase locking which includes
Growing phase and …….
A. Shrinking Phase
B. Release phase
C. Commit phase
D. Acquire Phase
8. A Transaction ends
A. only when it is Committed.
B. only when it is Rolled-back
C. when it is Committed or Rolled-back
D. only when it is initialized
9. In ………., each transaction there is a first phase during which new lock is acquired.
A. Shrinking Phase
B. Release phase
C. Commit phase
D. Growing Phase
10. ……… property will check whether all the operation of a transaction completed or
none.
A. Atomicity
B. Consistency
C. Isolation
D. Durability
11. The total ordering of operations across groups ensures ………..of transactions.
A. serializability
B. synchronizability
C. atomicity
D. durability
12. In which state, the transaction will wait for the final statement has been executed?
A. Active
B. Failed
C. Aborted
D. partially committed
13. When transaction Ti requests a data item currently held by Tj, Ti is allowed to wait
only if it has a timestamp smaller than that of Tj (that is, Ti is older than Tj). Otherwise,
Ti is rolled back (dies). This is
a) Wait-die
b) Wait-wound
c) Wound-wait
d) Wait
14. When transaction Ti requests a data item currently held by Tj, Ti is allowed to wait
only if it has a timestamp larger than that of Tj (that is, Ti is younger than Tj ).
Otherwise, Tj is rolled back (Tj is wounded by Ti). This is
a) Wait-die
b) Wait-wound
c) Wound-wait
d) Wait
15. The situation where the lock waits only for a specified amount of time for another lock
to be released is
a) Lock timeout
b) Wait-wound
c) Timeout
d) Wait
View Answer
Explanation: The timeout scheme is particularly easy to implement, and works well if
transactions are short and if longwaits are likely to be due to deadlocks.
Questions
1. What problem can occur in a distributed system due to the failure of link and
partitioning of the network? What are the ways by which recovery can take
place?
2. Explain the phases of query processing in distributed database
3. What are homogenous and heterogeneous database. Give the architecture of
heterogeneous database along with some query processing issues.
4. Compare Distributed Deadlock prevention to Distributed Deadlock Avoidance.
Explain one scheme of Distributed deadlock Detection and Recovery.
5. What are the various concurrency control techniques? Compare Lock based
Concurrency Control strategies in detail.
MCQ
1. __ transparency exists when the end user or programmer must specify the
database fragment names but does not need to specify where these fragments
are located.
A. Transaction
B. Location
C. Local mapping
D. Fragmentation
2. ____ transparency ensures that the system will continue to operate in the event
of a node failure.
A. ? Transaction
B. ? Distribution
C. Failure
D. ? Performance
3. The ____ rule requires that all copies of data fragments be identical.
A. shared fragment
B. mutual consistency
C. horizontal fragmentation
D. replication
4. ____ transparency exists when the end user or programmer must specify both
the fragment names and their locations.
A. Local mapping
B. Location
C. Performance
D. Transaction
5. A(n) ____ database stores each database fragment at a single site.
A. partially replicated
B. instance replicated
C. fully replicated
D. Unreplicated
6. A(n) ____ is a database stored on multiple computers on multiple locations that
are not connected by a data communications link
a. Distributed database
b. Decentralized database
c. Unlinked database
d. Data repository
7. Under the ____ scenario, multiple processes run on different computers sharing
a single data repository.
A. single-site processing, single-site data
B. multiple-site processing, single-site data
C. single-site processing, multiple-site data
D. multiple-site processing, multiple-site data
8. A distributed ____ allows a transaction to reference several different remote
sites.
A. request
B. site
C. data location
D. transaction
9. The ____ commit protocol guarantees that if a portion of a transaction operation
cannot be committed, all changes made at the other sites participating in the
transaction will be undone to maintain a consistent database state.
A. replicated
B. two-phase
C. remote
D. distributed
10. ____ fragmentation allows us to break a single object into two or more segments
or fragments.
A. Horizontal
B. Vertical
C. Data
D. Mixed
11. In ____ fragmentation a table may be divided into several horizontal subsets,
each one having a subset of the attributes.
A. data
B. mixed
C. vertical
D. horizontal
12. Which of the following factors influences the decision to use replication?
A. database content
B. database size
C. data style
D. number of users
13. ____ query optimization is scheduled and selected by the end user or
programmer.
A. Manual
B. Static
C. Automatic
D. Dynamic
14. Data ____ refers to the storage of data copies at multiple sites served by a
computer network.
A. replication
B. fragmentation
C. persistence
D. optimization
15. What feature is a DDBMS advantage?
A. reduced operating cost
B. complexity of management and control
C. increased storage requirements
D. increased training co
16. ____ query optimization takes place at execution time.
A. Automatic
B. Static
C. Manual
D. Dynamic
17. The ____ processor is the software component residing on each computer that
stores and retrieves data located at the site.
A. transaction
B. network
C. data
D. management
18. Which of the following environments uses the same DBMS at each node with a
central or master DBMS coordinating database access across nodes.
a. Centralized; maximum
b. Centralized; minimum
c. Homogenous; nonautonomous
d. Federated; nonautonomous
19. Which of the following business conditions that encourage the use of distributed
databases
a. Companies with less than 10 employees
b. Lack of data sharing needs
c. Data communication reliability
d. Companies that only store data on spreadsheets
20. What are the advantages of Replication of data in Distributed database?
Vertical Fragmentation
Horizontal Fragmentation
Hybrid Fragmentation
None of the above
22. Which of the following failures are unique to distributed database systems?
Failure of a site
Loss of messages
Network Partition
All the above
23. In a distributed database application, if we have very many number of read only
queries than update queries then ______________ allocation technique is
advantageous.
Hybrid Fragmentation
Horizontal Fragmentation
Replication
Vertical Fragmentation
24. Which of the following would be the advantage of Database Fragmentation?
Questions:
• What is the difference between A distributed database and Distributed File System
Ans.
A distributed database is a database that consists of two or more files located in
different sites either on the same network or on entirely different networks. ... A
centralized distributed database management system (DDBMS) integrates data
logically so it can be managed as if it were all stored in the same location.
Distributed File System (DFS) is a set of client and server services that allow an
organization using Microsoft Windows servers to organize manydistributed SMB file
shares into a distributed file system.
Figure 1 shows a distributed database configured on sites A, B, C, and D. All the sites
are connected. Assume that a request in the form of Transaction T is reaching Site A. For
this case represented in Figure 1, answer the following questions;
(a) How do you handle and restore(recover) the database if Site A is failed during
transaction T? Explain.
(b) How do you handle and restore(recover) the database if Site B is failed during
transaction T? Explain.
(c) Assume that the Site C is failed. When it recovers from failure, it reads <ready T>
control message for transaction T in its log file. How would site C restore the database
using the <ready T> control message?
(d) Assume that the Site C is failed. When C recovers, it checks the log file for deciding
the fate of the transactions that were running during failure. This step is very much
necessary as it can lead the database to a consistent state. When you check the log
file, what are the different cases or log entries which would force you to perform an
Undo(T) (undo a transaction) on your own without consulting the other sites?
Answer
(a) Transaction T is initiated at Site A. Hence, Site A is the Transaction Coordinator site
according to the information provided and the given figure. Now, the other sites which
are participating in Transaction T can execute the routine of 2PC protocol for handling
the Coordinator Failure. For explanation, continue with the link.
(b) According the information provided, Site B is one of the participating site in
Transaction T. Hence, the algorithm for handling Site Failure can be invoked and the
database could be set right. For explanation, continue with the link.
(c) The appropriate solution for this case is to invoke the Handling of Site Failure
routine. As Site C reads a <ready T> message, Site C, in any case cannot decide the
fate of Transaction T. Hence, it has to approach other sites including the Coordinator
site to know the decision on Transaction T.
• If the Site C has a record with <abort T>, it has to perform an Undo(T)
• If the Site C does not contain any control messages (no abort, commit, or ready),
it has to perform an Undo(T)
----
• Define the following terms: Deadlock prevention, Deadlock avoidance, and Deadlock
detection.
• Describe how the pre-acquisition can prevent deadlock from occurring in DDB.
Ans.
A transaction acquires all the locks before starting to execute and retains the locks for
the entire duration of transaction. If another transaction needs any of the already
acquired locks, it has to wait until all the locks it needs are available
• Describe how the lock manager can avoid the deadlock to occur in DDB transactions.
Ans.
• Transactions start executing and request data items that they need to lock. The
lock manager checks whether the lock is available. If it is available, the lock
manager allocates the data item and the transaction acquires the lock. However,
if the item is locked by some other transaction in incompatible mode, the lock
manager runs an algorithm to test whether keeping the transaction in waiting
state will cause a deadlock or not. Accordingly, the algorithm decides whether
the transaction can wait or one of the transactions should be aborted.
• Discuss how the different methods of replication will effect on system performance
• Define Concurrency control , and what is the purpose of using it.
•
•