Sns College of Technology: Computer Networks
Sns College of Technology: Computer Networks
UNIT-I
Data communication is the exchange of data (in the form of 1s and 0s) between two
devices via some form of transmission medium (such as a wire cable).
2. What are the three criteria necessary for an effective and efficient network?
The most important criteria are performance, reliability and security. Performance of
the network depends on number of users, type of transmission medium, the capabilities of the
connected h/w and the efficiency of the s/w.
Security issues include protecting data from unauthorized access and viruses.
fundamental characteristics:
entities cannot just send bit streams to each other and expect to be understood. For
communication, the entities must agree on a protocol. A protocol is a set of rules that
7. For n devices in a network, what is the number of cable links required for a
Ring topology – n
An active hub contains a repeater that regenerates the received bit patterns before
sending them out. A passive hub provides a simple physical connection between the
attached devices.
relationship.
Primary-secondary relationship: One device controls traffic and the others must
10. Assume 6 devices are arranged in a mesh topology. How many cables are
The seven layers of the OSI model belonging to three subgroups. Physical, data
link and network layers are the network support layers; they deal with the physical
aspects of moving data from one device to another. Session, presentation and
application layers are the user support layers; they allow interoperability among
unrelated software systems. The transport layer ensures end-to-end reliable data
transmission.
12. What are header and trailers and how do they get added and removed?
Each layer in the sending machine adds its own information to the message it
receives from the layer just above it and passes the whole package to the layer just
below it. This information is added in the form of headers or trailers. Headers are
added to the message at the layers 6,5,4,3, and 2. A trailer is added at layer2. At the
receiving machine, the headers or trailers attached to the data unit at the
corresponding sending layers are removed, and actions appropriate to that layer are
taken.
13. The transport layer creates a communication between the source and
a) Ethernet
b) Token bus
c) Token ring
IEEE 802.3 supports a LAN standard originally developed by Xerox and later
a) 10 Base 5
b) 10 Base 2
c) 10 Base T
d) 1 Base 5
e) 100 Base T
a) Switched Ethernet
b) Fast Ethernet
c) Gigabit Ethernet
ANSI and ITU-7. It supports data rates of 100 Mbps and provides a high-speed
alternative to Ethernet and token ring access method used here is token passing.
19.Categories of Networks.
LAN
WAN
MAN
20.Token ring :
UNIT-II
a) Framing
b) Physical addressing
c) Flow control
d) Error control
e) Access control
a) Single-bit error.
b) Burst-bit error.
a) Single bit error: The term single bit error means that only one bit of a given data unit (such
as byte character/data unit or packet) is changed from 1 to 0 or from 0 to 1.
b) Burst error: Means that 2 or more bits in the data unit have changed from 1 to 0 from 0 to
4. What is redundancy?
It is the error detecting mechanism, which means a shorter group of bits or extra
d) Checksum.
The most common and least expensive mechanism for error detection is the vertical
redundancy check (VRC) often called a parity check. In this technique a redundant bit called
a parity bit, is appended to every data unit so, that the total number of 0’s in the unit
(including the parity bit) becomes even.
In longitudinal redundancy check (LRC), a block of bits is divided into rows and a redundant
row of bits is added to the whole block.
The third and most powerful of the redundancy checking techniques is the cyclic redundancy
checks (CRC) CRC is based on binary division. Here a sequence of redundant bits, called the
CRC remainder is appended to the end of data unit.
a) In the first step, the 4 bit divisor is subtracted from the first 4 bit of the dividend.
b) Each bit of the divisor is subtracted from the corresponding bit of the dividend without
disturbing the next higher bit.
A CRC checker functions exactly like a generator. After receiving the data appended with the
CRC it does the same modulo-2 division. If the remainder is all 0’s the CRC is dropped and
the data accepted. Otherwise, the received stream of bits is discarded and the dates are resent.
a) It should not be
The error detection method used by the higher layer protocol is called checksum.
b) All sections are added together using 2’s complement to get the sum.
b) All sections are added together using 1’s complement to get the sum.
So the simple strategy used by the hamming code to correct single bit errors must
Each receiving device has a block of memory called a buffer, reserved for
There are 2 methods have been developed to control flow of data across
communication links.
In this method, the sender sends one frame and waits for an
22. Mention the advantage and disadvantage of stop and wait flow control.
Advantage: simplicity
Disadvantage: inefficiency.
Error control in the data link layer is based on Automatic repeat request
a) Damaged frame
b) Lost frame
c) Lost acknowledgment.
method, if our frame is lost or damaged, all frames sent since the last frame
In selective reject ARQ only the specific damaged or lost frame is retransmitted.
If a frame is corrupted in transit, a NAK is returned and the frame is resent out of
sequence.
It is a bit-oriented data link protocol designed to support both half-duplex and full
a) Primary
b) Secondary
c) Combined
a) Unbalanced configuration
b) Symmetrical configuration
c) Balanced configuration
I frames – used to transport user data and control information relating to user data.
S frames – used only to transport control information, primarily data link layer
b) An address field
c) A control field
d) An information field
Bit stuffing is the process of adding one extra 0 whenever there are 5 consecutive
in the data so that the receiver doesn’t mistake the data for a flag.
Piggy backing can save bandwidth because the overhead from a data
frame and an ACK frame can be combined into just one frame
_ Mode setting
_ Unnumbered exchange
_ Disconnection.
_ Initialization mode.
_ Miscellaneous mode
Primary station: The primary station has the complete control of the link. The
Combined station: The combined station is one which acts either as a primary or a
UNIT III
NETWORK LAYER
1. What are the network support layers and the user support layers?
The network support layers are Physical layer, Data link layer and
2. With a neat diagram explain the relationship of IEEE Project to the OSI model?
The IEEE has subdivided the data link layer into two sub layers:
The IEEE project 802 model takes the structure of an HDLC frame and divides it
into 2 sets of functions. One set contains the end user portion of the HDLC frame - the
logical address, control information, and data. These functions are handled by the IEEE
MAC sub layer resolves the contention for the shared media. It contains
information from one place to another, as well as the physical address of the next station to
receive and route a packet.
The data unit in the LLC level is called Protocol Data Unit (PDU). It contains four
fields.
Address (DSAP)
Other layers
Network
Data link
Physical
Other layers
Network
Physical
• Control field
• Information field
6. What are headers and trailers and how do they get added and removed?
The control data added to the beginning of a data is called headers. The
control data added to the end of a data is called trailers. At the sending machine, when
the message passes through the layers each layer adds the headers or trailers. At the
receiving machine, each layer removes the data meant for it and passes the rest to the
next layer.
packet across multiple network links. The specific responsibilities of network layer
• Logical addressing.
• Routing.
A logical circuit made between the sending and receiving computers. The
connection is made after both computers do handshaking. After the connection, all
In datagram approach, each packet is treated independently from all others. Even
when one packet represents just a place of a multipacket transmission, the network treats it
although it existed alone. Packets in this technology are referred to as datagram.
10. What are the two types of implementation formats in virtual circuits?
circuit switching. In this method, a virtual circuit is created whenever it is needed and
In this method, the same virtual circuit is provided between two uses on a continuous
internet routers operate in the physical, data link and network layer of OSI model.
routing, in which every link is considered to be of equal length and given the value one.
• Adaptive routing
• Non-adaptive routing.
usually the number of hops that are allowed before a packet is considered lost and
18. Write the keys for understanding the distance vector routing.
19. Write the keys for understanding the link state routing.
20. How the packet cost referred in distance vector and link state routing?
In distance vector routing, cost refer to hop count while in case of link state
routing, cost is a weighted value based on a variety of factors such as security levels, traffic
or the state of the link.
A router gets its information about its neighbors by periodically sending them a
assumed to be alive and functioning. If it dose not, a change is assumed to have occurred and
the sending router then alerts the rest of the network in its next LSP.
• Repeaters
• Bridges
• Routers
• Gateway
IP address is the 3-bit number for representing a host or system in the network.
a network.
Token Bus is a physical bus that operates as a logical ring using tokens.
Here stations are logically organized into a ring. A token is passed among stations. If a
station wants to send data, it must wait and capture the token. Like Ethernet, station
makes it onto a link. This redundancy may create delays of indeterminable length if the
traffic is heavy. Token ring resolves this uncertainty by requiring that stations take turns
sending data. Each station may transmit only during its turn and may send only one frame
during each turn. The mechanism that coordinates this rotation is called token passing.
Masking is the process that extracts the address of the physical network
from an IP address.
communication protocols.
UNIT IV
TRANSPORT LAYER
The protocol in the transport layer takes care in the delivery of data from
device. They act as a link between the upper layer protocols and the services
Reliable delivery
Flow control
Multiplexing
3. What is the difference between network layer delivery and the transport
layer delivery?
delivery of packet
entire message.
4. What are the four aspects related to the reliable delivery of data?
Error control
Sequence control
Loss control
Duplication control
At the sending and receiving end of the transmission, TCP divides long
transmissions into smaller data units and packages each into a frame called a
segment.
the network layer datagram or data link layer frame to handle, the transport
protocol divides it into smaller usable blocks. The dividing process is called
segmentation.
The size of the data unit belonging to a single session are so small that
several can fit together into a single datagram or frame, the transport protocol
combines them into a single data unit. The combining process is called
concatenation.
Upward multiplexing
Downward multiplexing
Connection service
Connectionless services
10. The transport layer creates the connection between source and destination.
For security , the transport layer may create a connection between the two
end ports. A connection is a single logical path between the source and
• Connection establishment
Frequency-division multiplexing
Time-division multiplexing
Wave-division multiplexing
Congestion in a network occur if user send data into the network at a rate
The BECN bit warns the sender of congestion in network. The sender can
The FECN bit is used to warn the receiver of congestion in the network.
The sender and receiver are communicating with each other and are using some
of the connection. For each connection, the user can request a particular attribute
User Oriented
Network Oriented
Domain Name System can map a name to an address and conversely an address to
name.
25. Discuss the three main division of the domain name space.
Domain name space is divided into three different sections: generic domains,
Generic domain: Define registered hosts according to their generic behavior, uses
generic suffixes.
Country domain: Uses two characters to identify a country as the last suffix.
FTP establishes two connections between the hosts. One connection is used for
data transfer, the other for control information. The control connection uses very
simple rules of communication. The data connection needs more complex rules due to
The client has three components: the user interface, the client control process, and
the client data transfer process. The server has two components: the server control
process and the server data transfer process. The control connection is made between
processes.
The TCP/IP protocol supports electronic mail on the Internet is called Simple
Mail Transfer (SMTP). It is a system for sending messages to other computer users
based on e-mail addresses. SMTP provides mail exchange between users on the same
or different computers.
28. What is the difference between a user agent (UA) and a mail transfer agent
(MTA)?
The UA prepares the message, creates the envelope, and puts the message in the
SMTP. MIME transforms non-ASCII data at the sender site to NVT ASCII data and
deliverers it to the client SMTP to be sent through the Internet. The server SMTP at
the receiving side receives the NVT ASCII data and delivers it to MIME to be
Workstations interact with the SMTP host which receives the mail on behalf of
such as Post Office Protocol , version 3(POP3). Although POP3 is used to download
messages from the server, the SMTP client still needed on the desktop to forward
Status Line
Headers
A Blank Line
Body
(present only in
some messages)
Request Line
Headers
A Blank Line
Body
The documents in the WWW can be grouped into three broad categories: static,
HTML is a computer language for specifying the contents and format of a web
document. It allows additional text to include codes that define fonts, layouts,
Authentication: The receiver is sure of the sender’s identity and that an imposter has
Integrity: The data must arrive at the receiver exactly as it was sent.
Non-Reputation: The receiver must able to prove that a received message came from
a specific sender.
In secret key, the same key is used by both parties. The sender uses this key and
an encryption algorithm to encrypt data; the receiver uses the same key and the
In public key, there are two keys: a private key and a public key. The private key
37. What are the advantages & disadvantages of public key encryption?
Advantages:
a) Remove the restriction of a shared secret key between two entities. Here each
entity can create a pair of keys, keep the private one, and publicly distribute the
other one.
b) The no. of keys needed is reduced tremendously. For one million users to
Disadvantage:
If you use large numbers the method to be effective. Calculating the cipher text using
the long keys takes a lot of time. So it is not recommended for large amounts of text.
38. What are the advantages & disadvantages of secret key encryption?
Secret Key algorithms are efficient: it takes less time to encrypt a message. The
reason is that the key is usually smaller. So it is used to encrypt or decrypt long
messages.
Disadvantages:
a) Each pair of users must have a secret key. If N people in world want to use this
method, there needs to be N (N-1)/2 secret keys. For one million people to
Straight permutation: The no. of bits in the input and output are preserved.
Compressed permutation: The no. of bits is reduced (some of the bits are dropped).
Expanded permutation: The no. of bits is increased (some bits are repeated).