Distributed System
Distributed System
Difference between Centralized Database and Distributed Database Virtualization in Cloud Computing and Types
Virtualization is a technique of how to separate a service from the underlying
A Distributed System is a Network of Machines that can exchange 1. Centralized Database physical delivery of that service. It is the process of creating a virtual version
information with each other through Message-passing. It can be very A centralized database is basically a type of database that is stored, located of something like computer hardware. It was initially developed during the
useful as it helps in resource sharing. as well as maintained at a single location mainframe era. It involves using specialized software to create a virtual or
only. This type of database is modified software-created version of a computing resource rather than the actual
and managed from that location itself. version of the same resource. With the help of Virtualization, multiple
• Client/Server Systems: Client requests to the This location is thus mainly any database operating systems and applications can run on same machine and its same
server for resources or a task to do, the server system or a centralized computer hardware at the same time, increasing the utilization and flexibility of
allocates the resource or performs the task and system. The centralized location is hardware.
sends the result in the form of response to the accessed via an internet connection
request of the client. (LAN, WAN, etc). This centralized
• Peer to Peer Systems: As nodes are an important
database is mainly used by institutions or organizations.
Advantages –
part of a system. In this, each node performs their
• Since all data is stored at a single location only thus it is
own task on their local memory and share data
easier to access and coordinate data.
through the supporting medium, this node can
• The centralized database has very minimal data redundancy
work as a server or as a client for a system.
since all data is stored in a single place.
• Middleware: It works as a base for different Disadvantages –
interoperability applications running on different • The data traffic in the case of centralized database is more.
operating systems. Data can be transferred to • If any kind of system failure occurs at the centralized system
other between others by using this service. then the entire data will be destroyed.
•
What Does Distributed System Mean? goals and challenges of DS ? Name Spaces Computer Network Architecture
A distributed system is any network structure that consists of autonomous A name space is a collection of all valid names recognized by a particular Computer Network Architecture is defined as the physical and logical design
computers that are connected using a distribution middleware. Distributed serviceAllow simple but meaningful names to be usedPotentially infinite of the software, hardware, protocols, and media of the transmission of data.
systems facilitate sharing different resources and capabilities, to provide number of namesStructuredto allow similar subnames without clashesto Simply we can say that how computers are organized and how tasks are
users with a single and integrated coherent network. group related namesAllow re-structuring of name treesfor some types of allocated to the computer.
change, old programs should continue to workManagement of trust.
The opposite of a distributed system is a centralized system. If all of the The two types of network architectures are used:
components of a computing system reside in one machine, as was the case Computer Network Architecture
with early mainframes such as Von Neumann machines, it is not a • Peer-To-Peer network
distributed system. • Client/Server network
Access Control:
This mechanism is used to stop unattended access to data which you are
sending. It can be achieved by various techniques such as applying
passwords, using firewall, or just by adding PIN to data.
4. Event-Based Architecture:
Notarization: Event-Based Architecture is almost similar to Data centered architecture
This security mechanism involves use of trusted third party in just the difference is that in this architecture events are present instead of
communication. It acts as mediator between sender and receiver so that if data. Events are present at the center in the Event bus and delivered to the
any chance of conflict is reduced. This mediator keeps record of requests required component whenever needed. In this architecture, the entire
made by sender to receiver for later denied. communication is done through events. When an event occurs, the system,
as well as the receiver, get notified. Data, URLs etc. are transmitted
Data Integrity: through events. The components of this system are loosely coupled that’s
This security mechanism is used by appending value to data to which is why it is easy to add, remove and modify them. Heterogeneous
created by data itself. It is similar to sending packet of information known to components can communicate through the bus.
both sending and receiving parties and checked before and after data is
received.
===========================================================
Authentication exchange:
This security mechanism deals with identity to be known in communication.
This is achieved at the TCP/IP layer where two-way handshaking mechanism
is used to ensure data is sent or not
Bit stuffing:
This security mechanism is used to add some extra bits into data which is
being transmitted. It helps data to be checked at the receiving end and is
achieved by Even parity or Odd Parity.
Digital Signature:
This security mechanism is achieved by adding digital data that is not visible
to eyes. It is form of electronic signature which is added by sender which is
checked by receiver electronically. This mechanism is used to preserve data
which is not more confidential but sender’s identity is to be notified.
Explain Remote procedure call and its working process in detail with a What is data- centric consistency model? Explain its type in details. Cryptography and its Types and features!
suitable diagram. How RPC is different from RMI? Ans: Traditionally consistency has been discussed in the context of read Cryptography is technique of securing information and communications
Remote Procedure Call (RPC) is a powerful technique for constructing and write operations on shared data, available by means of shared through use of codes so that only those person for whom the information
distributed, client-server-based applications. It is based on extending the memory. A shared database, or a file system. Here, we use the broader is intended can understand it and process it. Thus preventing unauthorized
conventional local procedure calling so that the called procedure need not term data store. A data store may be physically distributed across multiple access to information. The prefix “crypt” means “hidden” and suffix graphy
exist in the same address space as the calling procedure. The two machines. means “writing”.
processes may be on the same system, or they may be on different Types: -
systems with a network connecting them. i. Consistency model: a contract between a (distributed) data In general there are three types Of cryptography:
Working of RPC. store and processes, in which the data store specifies precisely what the
results of read and write operations are in the presence of concurrency. Symmetric Key Cryptography:
It is an encryption system where the sender and receiver of message use a
ii. Continuous Consistency: single common key to encrypt and decrypt messages. Symmetric Key
Observation: We can actually talk a about a degree of consistency: Systems are faster and simpler but the problem is that sender and receiver
· Replicas may differ in their numerical value have to somehow exchange key in a secure manner. The most popular
· Replicas may differ in their relative staleness symmetric key cryptography system is Data Encryption System(DES).
· There may differences with respect to (number and order) of
performed update operations Hash Functions:
There is no usage of any key in this algorithm. A hash value with fixed
Conit: consistency unit) specifies the data unit over which consistency is to length is calculated as per the plain text which makes it impossible for
be measured. contents of plain text to be recovered. Many operating systems use hash
· e.g., stock record, weather report, etc. functions to encrypt passwords.
Conit example: numerical and ordering deviations
Asymmetric Key Cryptography:
iii. Strict Consistency Under this system a pair of keys is used to encrypt and decrypt
Any read on a data item ‘x’ returns a value corresponding to the result of information. A public key is used for encryption and a private key is used
the most recent write on ‘x’ (regardless of where the write occurred). With for decryption. Public key and Private Key are different. Even if the public
Strict Consistency, all writes are instantaneously visible to all processes and key is known by everyone the intended receiver can only decode it because
absolute global time order is maintained throughout the distributed he alone knows the private key.
system. This is the consistency model “Holy Grail” – not at all easy in the
real world, and all but impossible within a DS. Features Of Cryptography are as follows:
Confidentiality:
iv. Sequential Consistency Information can only be accessed by the person for whom it is intended
· A weaker consistency model, which represents a relaxation of the and no other person except him can access it.
rules.
It is also must easier (possible) to implement. Integrity:
The following steps take place during an RPC: Sequential Consistency: Information cannot be modified in storage or transition between sender
1. A client invokes a client stub procedure, passing The result of any execution is the same as if the (read and write) and intended receiver without any addition to information being detected.
parameters in the usual way. The client stub resides within operations by all processes on the data-store were executed in the same
the client’s own address space. sequential order and the operations of each individual process appear in Non-repudiation:
2. The client stub Marshalls(pack) the parameters into a this sequence in the order specified by its program. The creator/sender of information cannot deny his intention to send
message. Marshalling includes converting the information at later stage.
representation of the parameters into a standard format, v. Causal Consistency
and copying each parameter into the message. · Writes that are potentially causally related must be seen by all Authentication:
3. The client stub passes the message to the transport layer, processes in the same order. The identities of sender and receiver are confirmed. As well as
which sends it to the remote server machine. · Concurrent writes (i.e., writes that are NOT causally related) may be destination/origin of information is confirmed.
4. On the server, the transport layer passes the message to a seen in a different order by different processes.
server stub, which demarshalls(unpack) the parameters vi. FIFO Consistency ===========================================================
and calls the desired server routine using the regular Writes done by a single process are seen by all other processes in the order
procedure call mechanism. in which they were issued, but writes from different processes may be
5. When the server procedure completes, it returns to the seen in a different order by different processes.
server stub (e.g., via a normal procedure call return), which · Also called “PRAM Consistency” – Pipelined RAM.
Marshalls the return values into a message. The server · Easy to implement -There are no guarantees about the order in which
stub then hands the message to the transport layer. different processes see writes – except those two or more writes from a
6. The transport layer sends the result message back to the single process must be seen in order.
client transport layer, which hands the message back to
the client stub. vii. Weak Consistency
7. The client stub demarshalls the return parameters and · Not all applications need to see all writes, let alone seeing them in the
execution return to the caller. same order.
Three component of security? CIA triad? · Leads to Weak Consistency (which is primarily designed to work with
distributed critical sections).
When we discuss data and information, we must consider the CIA triad. · This model introduces the notion of a synchronization variable”,
The CIA triad refers to an information security model made up of the three which is used update all copies of the data-store.
main components: confidentiality, integrity and availability. Each Properties Weak Consistency:
component represents a fundamental objective of information security. 1. Accesses to synchronization variables associated with a data-store are
The three components of the CIA triad are discussed below: sequentially consistent.
2. No operation on a synchronization variable is allowed to be performed
Confidentiality: until all previous writes have been completed everywhere.
This component is often associated with secrecy and the use of encryption. 3. No read or write operation on data items are allowed to be performed
Confidentiality in this context means that the data is only available to until all previous operations to synchronization variables have been
authorized parties. When information has been kept confidential it means performed.
that it has not been compromised by other parties; confidential data are
not disclosed to people who do not require them or who should not have viii. Release Consistency
access to them. Ensuring confidentiality means that information is · When a process does an acquire, the data-store will ensure that all
organized in terms of who needs to have access, as well as the sensitivity the local copies of the protected data are brought up to date to be
of the data. A breach of confidentiality may take place through different consistent with the remote ones if needs be.
means, for instance hacking or social engineering. · When a release is done, protected data that have been changed are
propagated out to the local copies of the data-store.
Integrity:
Data integrity refers to the certainty that the data is not tampered with or ix. Entry consistency
degraded during or after submission. It is the certainty that the data has ● Acquire and release are still used, and the data-store meets the
not been subject to unauthorized modification, either intentional or following conditions:
unintentional. There are two points during the transmission process during ● An acquire access of a synchronization variable is not allowed to
which the integrity could be compromised: during the upload or perform with respect to a process until all updates to the guarded shared
transmission of data or during the storage of the document in the database data have been performed with respect to that process.
or collection. ● Before an exclusive mode access to a synchronization variable by a
process is allowed to perform with respect to that process, no other
Availability: This means that the information is available to authorized process may hold the synchronization variable, not even in nonexclusive
users when it is needed. For a system to demonstrate availability, it must mode.
have properly functioning computing systems, security controls and ● After an exclusive mode access to a synchronization variable has
communication channels. Systems defined as critical (power generation, been performed, any other process's next nonexclusive mode access to
medical equipment, safety systems) often have extreme requirements that synchronization variable may not be performed until it has performed
related to availability. These systems must be resilient against cyber with respect to that variable's owner.
threats, and have safeguards against power outages, hardware failures and
other events that might impact the system availability.