You are on page 1of 164

Faculty : Diploma Engineering Branch : Computer

Subject Code : 361103


Subject Name : Computer Networks
Authors : Hemang R Chath, Lecturer CE, C.P.I., Rajkot Hussain Makda, Lecturer CE, C.P.I., Rajkot

CHAPTER 1 HARDWARE STRUCTURE OF NETWORKS


1.1 Advantages of computer networks 1.2 Applications of computer networks: Business applications, home applications 1.3 Point-to-point networks and broadcast networks 1.4 Network topologies: - Star - Ring - Bus - Mesh - Tree

1.5 Network categories: - LAN - WAN - MAN

1.1 Advantages of computer networks


Text Book Name : Forouzen, Reference : www.wiki.answer.com Efficient communication Faster data sharing High reliability Keeping information reliable and up to date Efficient management of resources Save cost Remote access and login Flexible Provides broader view

1.2 Application of computer networks


Text Book Name : Forouzen, Reference : www.en.wikipedia.org Financial Services

Marketing and Sales


Electronic Messaging Manufacturing

Directory Services
Information Services Cellular Telephone Cable Television Teleconferencing Electronic Data Interchange

1.3 Point-to-point networks and broadcast networks


Text Book Name : Forouzen : Page No : 8, Ref. Book Name : A. S. Tanenbaum

Point-to-point Networks
Two and only two devices are connected by a dedicated link is called point-to-point communication or networks as shown in figure. Dedicated means that link carries traffic between connected devices only.

Figure Source : www.wtreemsteel.blogsopt.com


In this configuration, entire capacity of the channel is reserved for transmission between two devices.

Broadcast Networks
A broadcast network is an organization, such as a corporation or other voluntary association, that provides live television or recorded content, such as movies, newscasts, sports, Public affairs programming, and other television programs for broadcast over a group of radio stations or television stations.
Most networks are primarily either a television network or a radio network, although some organizations run both types of networks.

Streaming media, Internet radio Web casting is sometimes considered a form of broadcasting despite the lack of broadcast stations, in which case its practitioners may also be called "broadcasters" or even "broadcast networks".

Figure shows the example of broadcast networks.

Figure Source : www. networkingspice.blogspot.com

1.4 Network topologies


Text Book Name : Forouzen : Page No : 9 to 13, Ref. Book Name : A. S. Tanenbaum Topology which refers to the way interconnection path between many users or nodes are arranged OR Topology described the actual layout to network transmission media

Types of Network Topologies Are :


- Bus Topology
- Star Topology - Ring Topology

- Mesh Topology
- Tree Topology

Bus topology
It is also known as linear bus topology.

It consist of several computers attached to a long common cable act as backbone, to link all the devices in the network shown in figure.
In bus topology, data on the network is send to all the computers on the network, the data travels from one end of the cable to another end.

Only one computer at a time can send message.


The failure of one computer does not affect the performance of the network.

Bus topology Figure Source : www.tripod.com

Advantages of Bus Topology :


Bus is simple Reliable in very small network Easy to use and easy to understand Bus requires the least amount of cable to connect the computers together It is easy to extend the bus

Disadvantages of Bus Topology :


Bus topology cannot work efficiently under heavy network traffic

Too many extensions on a bus can weaken the electric signal


Entire network shuts down if there is a break in the main cable Terminators are required at both ends of the backbone cable

Star Topology
In star topology each devices has a dedicated point to point link only to a central controller usually called HUB shown in figure.

Star topology Figure Source : www.fcit.usf.edu

The devices are not directly linked to each other. A star topology does not allow direct traffic between devices. The controller acts as an exchange, if any device want to send a data to another it sends the data to the controller, which then relay the data to the other connected device. If the central controller fails the entire network is disable.

However, if one computer or the cable that connects it to the HUB fails, the rest of the network continues to function normally.
Since, each computer is connected to central HUB, this topology requires more cable.

Advantages of Star Topology :


It is easy to modify and add new computers to a star topology network without disturbing the rest of the network There is a central point, controller or HUB in star network; it is easier to diagnose network problems Single computers fails does not bring down the whole network

Disadvantages of Star Topology :


If the central HUB fails the entire network fails to operate More cable is required compared to BUS topology More expensive than linear topologies

Ring Topology
In ring topology computers are connected on single circle of cable shown in figure.

Ring topology Figure Source : www.louiewong.com


There are no terminated ends. A signal is passed along the ring in one direction from device to device until it reaches the destination.

Each device in ring incorporates repeater. When a device receives a signal intended for another device, its repeater regenerate the bits and passes them along. Failure of one computer in ring affects the entire network.

The network uses token passing method for transferring data.


A short message called a token is passed around the ring until a computer needs to send to another computer. The sending computer modifies the token, adds electronic address and data, and sends it around the ring. Each computer in sequence receives the token, and passes it to the next computer until either the electronic address matches the address of computer or the token returns to its origin. The receiving computer returns a message to the originator indicating that message has been received. The sending computer than creates another token and places it on the network, allows another station or device to capture the token and begin transmitting.

Advantages of Ring Topology :


The network efficiency can approach 100% under conditions to heavy load The networks allows equal across to all computers

Disadvantages of Ring Topology :


Failure of one computer in ring can affect the whole network
Adding and removing the computer disturbs the network It is difficult to troubleshoot

Mesh Topology
In mesh topology every device has a dedicated point-to-point link to every other device shown in figure.

Mesh topology

Figure Source : www.brebru.com


The term dedicated means that the link carries traffic only between the two devices it connect.

Advantages of Mesh Topology :


The use of dedicated links guarantee that each connection can carry its own data load thus illumination the traffic problem that can occur when links must be shared by multiple devices. It provides privacy or security means while every message travels along a dedicated line, only the intended recipients see its, prevent other users from gaining access to message. Point to point links makes fault identification easy. It is robust, means if one links becomes unusable it does not affect the entire system.

Disadvantages of Mesh Topology :


More cables and more of I / O ports are required

Installation and reconfiguration are difficult because every device must be connected to every other device.
Hardware required to connect each link can be expensive. It is usually implemented in limited fashion.

Tree Topology
A tree topology is variation of star; nodes in a tree are linked to central hub that controls traffic to the network shown in figure.

Tree topology Figure Source : www.fcit.usf.edu

However, not every device plugs directly into the central hub. The majority of devices cannot to secondary hub that in turn connected to central hub. The central hub in the tree is an active hub. The active hub contains a repeater, which is a hardware device that regenerates the received bit patterns before sending them out. The secondary hub may be active or passive. A passive hub provides simple physical connection between the attached devices.

Advantages of Tree Topology :


More devices to be attached to a single central hub It increase the distance of a signal can travel between devices It allows the network to isolate and prioritize the communication from different computers.., ex.., Cable TV.

Disadvantages of Tree Topology :


Overall length of each segment is limited by the type of cabling used If the backbone lines breaks, the entire segment goes down. More difficult to configure and wire than other topologies

1.5 Network categories


Text Book Name : Forouzen : Page No : 13 to 15, Ref. Book Name : A. S. Tanenbaum

Network classify according to their geographical size. Network referring to three primary categories.

1. LAN (Local Area Network)

2. MAN (Metropolitan Area Network)

3. WAN (Wide Area Network)

LAN (Local Area Network) :


LAN is a group of computer and network communication devices interconnected within the geographically limited area. Such as: - Office - Building - Computer Lab or - Campus. LAN tends to use only one types of transmission medium was cabling. Figure shows the single building LAN.

Single building LAN Figure Source : www.databaseadmin.net

Figure shows the Multiple building LAN.

Multiple building LAN Figure Source : www.databaseadmin.net

Characteristics of LAN :
1. It allows users to share storage devices like Printer, Application data and other network resources.

2. It transfers data at high speed (more than 1 mbps).

3. It exists in limited geographically area (up to few kilometers).

4. Multiple accesses (many can use it at the same time).

5. Its technology is generally less expensive.

6. It having a lower error rate.

Advantages of LAN :
1. LAN are the best means provide a cost effective multi-user computer environment.

2. LAN can fit any site requirement.

3. Any number of users can be accommodated.

4. Allows sharing of mass central storage and printers.

5. It is flexible and growth oriented.

6. It provides data integrity. 7. Transfers data at high speed.

MAN (Metropolitan Area Network) :


A MAN covers a much larger area and might cover an entire city but uses the LAN technology.

It may be single network which as able television network or it may be a means of connecting a number of LANs together into a larger network. So that resources may be shared LAN-to-LAN as well as device-to-device.
For example, A company can use a MAN to connect the LANs in all of its offices throughout a city. A MAN can support both data and voice.

MAN Figure Source : rezpectorpecintait.blogspot.com

WAN (Wide Area Network) :


When a network is spread over wide areas, such as Cities, States, Countries or Continent it is called a WAN. Communication on a WAN takes place via telephone lines, satellite or microwave transmission rather than physical cable. Most WANs are combination of LANs and other types of communication.

WAN Figure Source : www.jegsworks.com

Characteristics of WAN :
1. They exists in unlimited geographical area. 2. They are more susceptible to errors due to the distance the data can travel. 3. They interconnect multiple LAN. 4. They are more sophisticated and complex than LAN. 5. Their technology is expensive.

Types of WAN :
Public Network :
Public network are those networks, which are installed and run by the telecommunication authorities and are available to any organization Or individual who subscribes.

Private Network :
The basic technology used in all forms or private WAN is to use private or more usually leased circuits to link the location to be served by the network.

CHAPTER 2 REFERENCE MODELS


2.1 Definition of Protocol 2.2 The OSI Reference Model 2.3 The TCP/IP Reference Model 2.4 Comparison of the OSI and TCP/IP Reference Models

2.1 Definition of Protocol


Text Book Name : Forouzen : Page No : 19, Ref. Book Name : A. S. Tanenbaum

A protocol is a set of rules that manages all aspects of data communication.


It represents an agreement between the communication devices. Without a protocol, two devices may be connected but not communicating.

A protocol defines what is communicated, how it is communicated and when it is communicated


The key elements of protocol are:

Syntax :
Syntax refers to the format of the data or structure of data syntax tells us the order in which data are presented

Semantics :
Semantics refers to the meaning of each section of bits, how particular pattern to be represented is and what action is to be taken based on that presentation.

Timing :
Timing refers to two characteristics:

1. When data should be sent 2. How fast they can be sent

Following are the few examples of protocols :


SMTP - Simple Mail Transfer Protocol POP - Post Office Protocol

TCP - Transmission Control Protocol


UDP - User Datagram Protocol IP
- Internet Protocol

2.2 The OSI Reference Model


Text Book Name : Forouzen : Page No : 29 to 41, Ref. Book Name : A. S. Tanenbaum Open System Interconnection (OSI) model was first introduced in 1970 and developed by the ISO (International Standards Organization). The model is called ISO OSI reference model because it deals with connecting open systems that is the systems that are open for communication with other system. An open system is a model that allows any two different systems to communicate regardless of their underlying architecture.

Its purpose was developing universally excepted networking protocols.


OSI model is not a protocol, it is a model fro understanding and designing a network architecture that is flexible, robust and interoperable. The OSI reference model has seven separate layers but related with each other, each of which defines the process of moving information across the network. Each layer represents categories of related task. Layer 1,2 and 3 that is physical, data link and network layers are the network support layer. Layer 5,6 and 7 that is session, presentation and application layers are the user support layer. Transport layer links the network support layers and the user support layers.

At the physical layer, communication is direct: In figure Host A sends a stream of bits to Host B.

The OSI Reference Model Figure Source : www.homepages.uel.ac.uk

PHYSICAL LAYER
The physical layer is responsible for transmitting bits over a physical medium form one node to another node. Physical layer deals with the mechanical and electrical specifications of the interface and transmission medium. The physical layer also concerned with the following: 1. Physical characteristics of interfaces and medium 2. Representation of bits 3. Data rate (Transmission rate) 4. Synchronization of bits 5. Line Configuration 6. Physical Topology 7. Transmission Mode

DATA LINK LAYER


The data link layer is responsible for moving frames from one node to the next. Other responsibilities of the data link layer include the following: 1. Framing 2. Physical addressing 3. Flow Control 4. Error Control 5. Access Control

The Data Link Layer divided into two sub layers

Logical Link Control Layer (LLC) :


Logical Link Control Layer responsible for flow control, error detection & requesting function for connection oriented communication but which also supports connection less communication

Media Access Control Layer (MMC) :


Logical Link Control Layer responsible for flow control, error detection & requesting function for connection oriented communication but which also supports connection less communication

NETWORK LAYER
The Network Layer is responsible for the source to destination delivery of a packet possibly across multiple networks. If two systems are connected to the same network, there is usually no need for a network layer. However, if two systems are attached to different networks with connecting devices between the networks, there is often a need for the network layer to accomplish source-todestination delivery.

Other responsibilities of the Network Layer include the following:


1. Logical Addressing 2. Routing Packets

3. It also supplies connection less and connection oriented services to the transport layer

TRANSPORT LAYER
The Transport Layer is responsible for process-to-process delivery of the entire message. A process is an application program running on a host. Other responsibilities of the Transport Layer include the following:

1. Service-Point Addressing (Port Addressing) 2. Segmentation and Reassembly 3. Connection Control 4. Flow Control 5. Error Control

SESSION LAYER
Session Layer defines how connection can be established, maintained and terminated. Session Layer also responsible for the following: 1. Dialog Control 2. Synchronization points

PRESENTATION LAYER
The presentation layer is concerned with the syntax and semantics of the information exchanged between two systems. Specific responsibilities of the presentation layer include the following: 1. Translation 2. Encryption and Decryption

3.

Data compression

APPLICATION LAYER
The application layer is responsible for providing services to the user.
It provides user interfaces and support services such as e-mail, file transfer, database management and other type of distributed information services. Protocol at these level includes:

HTTP: Hyper text transfer protocol FTP: File transfer protocol

SMTP: Simple mail transfer protocol


NVT: Network virtual terminal

2.3 The TCP/IP Model


Text Book Name : Forouzen : Page No : 42 to 45, Ref. Book Name : A. S. Tanenbaum The TCP/IP model uses four layers that logically span the equivalent of the top six layers of the OSI reference model; this is shown in Figure. The following are the TCP/IP model layers, starting from the bottom.

The TCP/IP Reference Model Figure Source : www.tcpipguide.com

Figure shows the TCP/IP protocol suite.

APPLICATION LAYER TRANSPORT LAYER IP LAYER DATALINK LAYER PHYSICAL LAYER

SMTP

FTP

TFTP

SNMP

TELNET

TCP

UDP

ICMP

IGMP

IP

ARP

RARP

Protocols defined by the underlying protocols

Protocols defined by the underlying protocols

TCP/IP protocol suite


Figure Source : Data Communication & Networking, -Forouzan (Page no - 43)

Physical and Data Link Layer :


The function of the physical and data link layer are almost same as in OSI model.

Network or IP Layer :
At the network layer, TCP / IP supports the Internetworking Protocol. IP, in turn, uses four supporting protocols: ARP, RARP,ICMP and IGMP.

Internetworking Protocol (IP) :


The Internetworking Protocol (IP) is the transmission mechanism used by the TCP / IP protocols. It is an unreliable and connectionless protocol a best-effect delivery service. The term best effort means that IP provides no error checking or tracking. IP transport data in packets called datagrams, each of which is transported separately. Datagrams can travel along different routes and can arrive out of sequence or be duplicated. IP does not keep track of the routes and has no facility for reordering datagrams once they arrive at their destination.

Address Resolution Protocol (ARP) :


The Address Resolution Protocol (ARP) is used to associate a logical address with a physical address. ARP is used to find the physical address of the node when its Internet address is known.

Reverse Address Resolution Protocol (ARP) :


The Reverse Address Resolution Protocol (RARP) allows a host to discover its Internet address when it knows only its physical address. It is used when a computer is connected to a network for the first time or when a diskless computer is booted.

Internet Control Message Protocol (ICMP) :


The Internet Control Message Protocol (ICMP) is a mechanism used by hosts and gateways to send notification of datagram problems back to the sender. ICMP sends query and error reporting messages.

Internet Group Message Protocol (IGMP) :


The Internet Group Message Protocol (IGMP) is used to facilitate the simultaneous transmission of a message to a group of recipients. Some processes sometimes need to send the same message to a large number of receivers at same time. This is called Multicasting. So for multicasting purpose IGMP protocol is used.

Transport Layer :
Traditionally the transport layer was represented in TCP / IP by two protocols: TCP and UDP IP is a host-to-host protocol, meaning that it can deliver a packet from one physical device to another.

UDP and TCP are transport level protocols responsible for delivery of a message from a process (running program) to another process.
A new transport layer protocol, SCTP (Stream Control Transmission Protocol), has been devised to meet the needs of some newer applications.

User Datagram Protocol (UDP) :


The User Datagram Protocol (UDP) is the simpler of the two standard TCP / IP transport protocols. It is process-to-process protocol that adds only port addresses, checksum error control, and length information to the data from the upper layer. UDP is connectionless and unreliable protocol. The packet produces by UDP is called User Datagram.

Transmission Control Protocol (TCP) :


The Transmission Control Protocol (TCP) provides full transport-layer services to applications. TCP is a reliable stream transport protocol. The term Stream, in this context, means connection-oriented. A connection must be established between both ends of a transmission before either can transmit data. At the sending end of each transmission, TCP divides a stream of data into smaller units called segments. Each segment includes a sequence number for reordering after receipt, together with an acknowledgment number for the segments received.

Segments are carried across the internet inside of IP datagrams.


At the receiving end, TCP collects each datagram as it comes in and reorders the transmission based on sequence numbers.

Stream Control Transmission Protocol (SCTP) :


The Stream Control Transmission Protocol (SCTP) provides support for newer applications such as voice over the Internet. It is a transport layer protocol that combines the best features of UDP and TCP.

Application Layer :
The application layer in TCP / IP is equivalent to the combined session, presentation, and application layers in the OSI model. Many protocols are defined at this layer, SMTP, FTP, HTTP, DNS, SNMP and SNMP, etc.

Simple Mail Transfer Protocol (SMTP) :


Simple Mail Transfer Protocol (SMTP) is used to sending and e-mail messages between servers. Most e-mail systems that send mail over the internet use SMTP to send messages from one server to another.

File Transfer Protocol (FTP) :


File Transfer Protocol is the standard mechanism provided by the TCP / IP for copying file from one computer to another computer.

To copy the file some problems must occurs like two systems may use different file structure, two systems may have different way to represent text and data, two systems may have different directory structures. All this problems have been solved by FTP.
FTP is most commonly used to download a file from a server using the Internet or to upload a file to a server (e.g. uploading a Web page file to a server).

Trivial File Transfer Protocol (TFTP) :


Trivial File Transfer Protocol (TFTP) is used to copy a file without the need for all the functions of the FTP protocol. For example, when a diskless computer is booted we need to download files from servers. So at that time we do not need all the sophistication problems solution provided by FTP. We just require protocol to copy file from one computer to another. Reading file in TFTP means copying file from the server site to the client site. Writing file in TFTP means copying file from the client site to the server site. TFTP is less powerful than FTP.

Simple Network Management Protocol (SNMP) :


Simple Network Management Protocol (SNMP) provides a set of fundamental operations for monitoring and maintaining devices in the internet.

Terminal Network (TELNET) :


TELNET is a general purpose client server applications program used for remote login.

2.4 Comparison of the osi and tcp/ip Reference Model


Text Book Name : Forouzen : Page No : 29 to 45, Ref. Book Name : A. S. Tanenbaum

OSI Reference Model

TCP / IP Reference Model

1 OSI model developed after TCP / IP Model

1 TCP / IP model developed before OSI model

2 OSI model has seven layers

2 TCP / IP model has five layers

3 OSI model is protocol independent standard

3 TCP / IP model is protocol dependent standard

4 OSI model clearly differentiate between Services, Interfaces and Protocol

4 TCP / IP model did not clearly differentiate between Services, Interfaces and Protocol

OSI Reference Model

TCP / IP Reference Model

OSI model supports both connectionless and

5 TCP / IP model supports connectionless

connection oriented communication in the


Network layer but only connection oriented communication in the transport layer 6 7 OSI model does not supports Internetworking All the packets are reliably delivered

communication in the network layer but both


connectionless and connection-oriented communication in the transport layer 6 TCP / IP model supports Internetworking 7 TCP reliably delivers the packets, IP does not reliably deliver packets

Less Credible (Reliable)

8 More Credible (Reliable)

CHAPTER 3 LAN TECHNOLOGIES


3.1 Transmission Media: - Guided media

- Unguided media
3.2 Network devices: - Network Adapters - Hubs - Switches - Routers - Gateways

CHAPTER 3 LAN TECHNOLOGIES


3.3 Servers: - File Server - Print Server - Mail Server

- Proxy Server
- Web Server

3.1 Transmission Media


Text Book Name : Forouzen : Page No : 191 to 208, Ref. Book Name : A. S. Tanenbaum Transmission Media is the way through which the data information or messages can flow between the workstations. Transmission Media is actually located at the bottom of the Physical Layer. Transmission Media broadly classified into two categories:

Transmission Media

Guided Media

Unguided Media

Twisted Pair Cable

Coaxial Cable

Fiber Optic Cable

Radio Wave

Micro Wave

Infrared

Figure Source : Data Communication & Networking, -Forouzan (Page no - 192)

GUIDED MEDIA
Guided media, which are those that provide a path from one device to another, include twisted-pair cable, coaxial cable, and fiber-optic cable. Twisted-pair cable and Coaxial cable use metallic (copper) conductors that accept and transport signals in the form of electric current. Optical-fiber is a cable accepts and transport signals in the form of light.

Twisted-Pair Cable
A twisted pair consists of two conductors (normally copper), each with its own plastic insulation, twisted together, as shown in Figure-1.

Twisted-Pair Cable

Figure Source : www.infocellar.com

One of the wires is used to carry signals to the receiver, and the other is used only as a ground reference. The signal sent by the sender on one of the wires, interference (noise) and crosstalk may affect both wires and create unwanted signals. If the two wires are parallel, the effect of these unwanted signals is not the same in both wires because they are at different locations relative to the noise or crosstalk sources (e.g. one is closer and the other is farther).

Unshielded Versus Shielded Twisted-Pair Cable


The most common twisted-pair cable used in communications is referred to as unshielded twisted-pair (UTP). IBM has also produced a version of twisted-pair cable for its use called shielded twisted-pair (STP). STP cable has a metal foil or braided-mesh covering that encases each pair of insulated conductors. Although metal casing improves the quality of cable by preventing the penetration of noise or crosstalk, it is bulkier and more expensive. Figure-2 shows the difference between UTP and STP.

STP & UTP Cable

Figure Source : www.lanshack.com

Connectors of Twisted-Pair Cable


The most common UPT connector is RJ-45 (RJ stands for registered jack). The RJ-45 is a keyed connector, meaning the connector can be inserted in only one way.

Application of Twisted-Pair Cable


Twisted-pair cables are used in telephone lines to provide voice and data channels, commonly consists of unshielded twisted-pair cables. Local area networks, such as 10Base-T and 100Base-T, also use twisted-pair cables.

Coaxial Cable
Coaxial cable (or coax) carries signals of higher frequency ranges than those in twisted-pair cable, because the two media are constructed quite differently. Instead of having two wires, coax has a central core conductor of solid or standard wire (usually copper) enclosed in an insulating sheath, which is, in turn, encased in an outer conductor or metal foil, braid or a combination of the two. The outer metallic wrapping servers both as a shield against noise and as the second conductor, which completes the circuit. This outer conductor is also enclosed in an insulating sheath, and the whole cable is protected by a plastic cover (see figure-3).

STP & UTP Cable

Figure Source : www.phy.davidson.edu

Types of Coaxial Cable


Coaxial cables are categorized by their radio government (RG) ratings. Each RG number denotes a unique set of physical specifications, including the wire gauge of the inner conductor, the thickness and type of the inner insulator, the construction of the shield, and the size and type of the outer casing. Each cable defined by an RG rating is adapted for a specialized function, as shown in table.

Category
RG-59 RG-58 RG-11

Impedance
75 50 50

Use
Cable TV Thin Ethernet Thick Ethernet

Figure Source : Data Communication & Networking, -Forouzan (Page no 196)

Coaxial Cable Connectors


To connect coaxial cable to devices, we need coaxial connectors. The most common type of connector used today is the BNC (Bayone-Neill-Concelman), connector. There are three popular types of BNC connectors: - BNC Connector - BNC T Connector - BNC Terminator The BNC connector is used to connect the end of the cable to a device, such as a TV set. The BNC T connector is used to Ethernet Networks to branch out to a connection to a computer or other device. The BNC terminator is used at end of the cable to prevent the reflection of the signal.

Application of Coaxial Cable


Coaxial cable was widely used in analog telephone networks where a single coaxial network could carry 10,000 voice signals. Later it was used in digital telephone networks where a single coaxial cable could carry digital data up to 600 Mbps. Now a day, coaxial cable in telephone networks has largely been replaced with fiber-optic cable. Cable TV networks also use coaxial cables. Later cable TV providers replaced most of the media with fiber-optic cable. Another common application of coaxial cable is in traditional Ethernet LANs. Because of its high bandwidth, and high data rate.

Fiber-Optic Cable
A fiber-optic cable is made of glass or plastic and transmits signals in the form of light. To understand optical fiber, we first need to explore several aspects of the nature of light. Light travels in a straight line as long as it is moving through a single uniform object. If a ray of light traveling through one object suddenly enters another object, the ray changes direction.

Propagation Modes
Current technology of fiber-optical cable supports two modes (multimode and single mode) for propagation light along optical channels, each requiring fiber with different physical characteristics. Multimode can be implemented in two forms: step-index or graded-index. In multimode step-index fiber, the density of the core remains constant from the center to the edges. A beam of light moves through this constant density in a straight line until it reaches the interface of the core and the cladding. In multimode graded-index fiber, decreases the distortion of the signal through the cable. In graded-index fiber, density is highest at the center of the core and decreases gradually to its lowest at the edge. Single mode uses step-index fiber and a highly focused source of light that limits beams to a small range of angles, all close to the horizontal.

Fiber-Optic Cable Composition


The Figure-4 shows the composition of a typical fiber-optic cable. At the center there is a glass or plastic core through which light propagates. A core is surrounded by glass cladding with Kevlar strands to strengthen the cable. Kevlar is a strong material used in the fabrication of bulletproof vests. The Outer jacket is made of either PVC or Teflon to protect the cladding.

Fiber-Optic Cable Figure Source : www.linktionary.com

Fiber-Optic Cable Connectors


There are three types of connectors for fiber-optic cables:

- SC (Subscriber Channel) Connector


- ST (Straight-tip) Connector - MT-RJ Connector

The Subscriber Channel (SC) Connector is used for cable TV. It uses a push/pull locking system. The Straight-tip (ST) connector is used for connection cable to networking devices. The ST connector is more reliable than SC connector. MT-RJ is a connector that is the same size as RJ-45.

Application of Fiber-Optic Cable


Fiber-Optic cable is often found in backbone networks because its wide bandwidth is costeffective. Some cable TV companies use a combination of optical fiber and coaxial cable, thus creating a hybrid network. Local-area networks such as 100Base-FX network (Fast Ethernet) and 1000Base-X also use fiber-optic cable.

Advantages of Fiber-Optic Cable


- Higher bandwidth - Less signal attenuation - Immunity to electromagnetic interference - Resistance to corrosive materials - Light weight

Disadvantages of Fiber-Optic Cable


- Installation and maintenance - Unidirectional light propagation

- cost

UNGUIDED MEDIA
Unguided media transport electromagnetic waves without using a physical conductor. This type of communication is often referred to as wireless communication. Figure shows the electromagnetic spectrum, ranging from 3 KHz to 900 THz, used for wireless communication.

Radio Wave

Micro Wave

Infrared

Light Wave

3 KHz

1 GHz

300 GHz

400 THz

900 THz

Electro Magnetic Spectrum


Figure Source : Data Communication & Networking, -Forouzen (Page no 203)

Unguided signals can travel from the source to destination in many ways:

- Ground Propagation

- Sky Propagation

- Line-of-sight Propagation

In Ground Propagation, low-frequency radio signals travels in all the direction through the lowest portion of the atmosphere.
In sky propagation, higher-frequency radio signals radiate upward into the ionosphere where they are reflected back to the earth.

In line-of-sight propagation, very high-frequency signals are transmitted in straight lines directly from antenna to antenna. Antennas must be aligned, facing each other.

Radio Waves
Electromagnetic waves ranging in frequencies between 3 KHz and 1GHz are normally called radio waves.

Radio waves are omni-directional, means when an antenna transmits radio waves, they are propagated in all directions.
In radio wave sending and receiving antennas do not have to be aligned. A sending antenna sends waves that can be received by any receiving antenna.

Radio waves are those waves that propagate in the sky mode, can travel long distances.

Advantages of Radio Waves


The low and medium frequencies radio waves are easily penetrate walls, so they are widely used for communication, both indoors and outdoors.
Radio waves use omni-directional antennas that send signals in all directions.

Disadvantages of Radio Waves


The omni-directional property has a disadvantage, too. The radio waves transmitted by one antenna are susceptible to interference by another antenna that may send signals using same frequency or band. Radio waves can penetrate walls. So, we can not isolate a communication to just inside or outside a building. The radio wave band is narrow, just under 1 GHz, compared to the microwave band. When this band is divided into sub-bands, the sub-bands are also narrow, leading to a low data rate for digital communications.

Application of Radio Waves


The omni-directional property of radio waves makes them useful for multicasting, in which there is one sender but many receivers. - AM and FM radio - Television Broadcasts

- Cordless phones
- GPS receivers

Microwaves
Electromagnetic waves having frequencies between 1 and 300 GHz are called microwaves. Microwaves are unidirectional. When antenna transmits microwaves, they can be narrowly focused. This means that the sending and receiving antennas need to be aligned. Microwaves are used line-of-sight propagation.

Advantages of Microwaves
Microwaves are unidirectional, sending and receiving antennas need to be aligned, so they are not interfering with another pair of aligned antennas. The microwave band is relatively wide, therefore sub-bands are also wider, and a high data rate for digital communication is possible. Microwaves are relatively inexpensive and simple to install.

Disadvantages of Microwaves
Very high frequency microwaves cannot penetrate walls, if receivers are inside buildings. The microwave propagation is line-of-sight, if the towers are far apart need to be very tall. The curvature of the earth does not allow two short towers to communicate by using microwaves. Repeaters are often needed for long distance communication.

Applications of Microwaves
The unidirectional properties of microwaves make them useful for unicasting, in which there is one sender and one receiver.

- Cellular phones
- Satellite networks - Wireless LANs

The section of the electromagnetic spectrum defined as radio waves and microwaves is divided into eight ranges, called bands, each regulated by government authorities.
These bands are rated from very low frequency (VLF) to extremely high frequency (EHF). Below table lists these bands, their ranges, propagation methods, and some application.

Band
VLF (very low frequency

Range
3-30 kHz

Propagation
Ground

Application
Long range radio navigation

LF (low frequency)
MF (medium frequency) HF (high frequency) VHF (very high frequency) UHF (ultra high frequency) SHF (super high frequency) EHF (extremely high frequency)

30-300 kHz
300-3 MHz 3-30 MHz 30-300 MHz 300-3 GHz 3-30 GHz 30-300 GHz

Ground
Sky Sky Sky and Line-of-sight Line-of-sight Line-of-sight Line-of-sight

Radio beacons and navigational locators


AM radio Ship/Aircraft communication VHF TV, FM radio UHF TV, cellular phones, satellite Satellite communication Radar, Satellite

Figure Source : Data Communication & Networking, -Forouzen (Page no 204)

Infrared
Electromagnetic waves having frequencies from 300 GHz to 400 THz are called infrared waves. Infrared waves can be used for short-range communication.

Advantages of Infrared
Infrared waves are relatively directional and easy to build.

Infrared waves having a high frequency, this advantageous characteristic prevents interference between one system to another; a short range communication system in one room cannot be affected by another system in the next room.
It is useful to communicate with wireless keyboard and mouse in the PCs.

Disadvantages of Infrared
High frequency infrared waves cannot penetrate walls.
Infrared waves are useless for long range communication. Infrared waves do not pass through solid objects. We cannot use infrared waves outside a building because the suns rays contain infrared waves that can interfere with the communication.

Applications of Infrared
The remote controls used on television, VCRs are based on Infrared.
Infrared waves are used in short-range communication e.g., wireless keyboard and mouse. Infrared waves are used for thermal efficiency analysis, remote temperature sensing and weather forecasting.

3.2 Network devices


Text Book Name : Forouzen : Page No : 445 to 450, Ref. Book Name : A. S. Tanenbaum

Network Adapters (Network Interface Card NIC) :


Network interface cards are add on the motherboard as hardware card. This is the additional hardware card require to install physically in to he slot on the motherboard. This type of card consists of different types of network ports, to communicate with other machine (node) and server. NIC is a small printed circuit board that is installed in a mother board of CPU. This card provides the connectivity between computer internal system resources and the external resources connected to the network. Each NIC has a unique address (Physical address) that differentiates from any other NIC. NIC consists of different types of network ports to communicate with other device or server. Backside of NIC card, it contains physical interface for a specific connector type. Each connector type is designed for a specific transmission media.

Type of NIC (Network Interface Card) :


Basically there are two types of NIC :

1. ARCNET Card (Attached Resource Computer Network Card) 2. ETHERNET Card

ARCNET Card (Attached Resource Computer Network Card) :


This card consists of eight Dual Inline Package (DIP) Switches.
These switches are used for defining address of nodes. If all switches are off then address is OOH and if the all are on then the address is FFH.

It supports MCA (Micro Channel Architectural) Bus.


The cable used with ARCNET Card is Co-axial usually it is RG-62. This type of NIC supports BUS topology and star topology but usually implemented on star topology.

Figure shows the ARCNET card

ARCNET Card Figure Source : www.hira.co.in


If the stations are wired in the Bus topology the maximum trunk length of the bus segment is 1000 ft.
ARCNET card uses a token ring bus access method but it is not IEEE standard.

It has 8 bit or a boot ROM. Transmission rate is 2.5 mbps. It also has a BNC connector and a jumper on a card. The name of the driver for this card is TURBO RXNET (TRXNET). If the stations are wired in the Bus topology the maximum trunk length of the bus segment is 1000 ft.

ARCNET card uses a token ring bus access method but it is not IEEE standard.

ETHERNET Card :
This card consist of PCI (Peripheral Component Interconnect) bus. The slots available are 8, 16, 32 bit. Node address is between 0 to 1023. DIP (Dual Inline Package) switches are not available. The cable use is RG-58.

Figure shows the Ethernet card.

NIC Card Figure Source : www.assistacomp.com


This type of NIC supports Bus topology and Star topology but unlike ARCNET card is usually support Bus topology.

Thick and thin Ethernet are available. Data transfer rate is 10 mbps.

Thick Ethernet uses AUI (Attachment Unit Interface) connector 25-pin female connector.
Ethernet uses BNC connector. There are no switches for port address settings. The default factor setting port address is fused on the card.

Hubs
Hub is used to create connections between stations in a physical star topology. Hub is a central network device that connects network nodes as shown in figure.

Hub Figure Source : www.thebryantadvantage.com

Basically there is two types of hub 1. Active Hub and 2. Passive Hub

1. Active Hub
Active hubs are regenerate and retransmit the signals the same way repeater does. Hub usually have eight to twelve ports for computers to connect to, they are often called multiport repeaters. Active hubs need electric power to run

2. Passive Hub
A passive hub is just a connector. It connects the wires coming from different branches. In a star topology Ethernet LAN, a passive hub is just a point where the signals coming from different stations collide; the hub is a collision point.

Passive hubs do not require electricity to run.

Hubs can also be used to create multiple levels of hierarchy, as shown in figure. A hub-based network can be expanded by connecting more than one hub.

Hierarchy of Hub Figure Source : www. gndec.ac.in

Switches
Switches provides bridging functionality with greater efficiency. It acts as multiport bridge to connect devices or segments in a LAN as shown figure.

Switch Figure Source : www. searchexchange.techtarget.com

Switch has a buffer for each link to which it is connected. Switch operates in Data Link Layer of the OSI model. When it receives a frame, it stores the frame in the buffer of receiving link & checks address to find outgoing link. If the outgoing link is free the switch sends the frame to that particular link. There is a two different strategies of switch:

1. Store and forward switch 2. Cut-through switch

1. Store and Forward Switch :


This switch stores the frame in the input buffer until the whole packet has arrived.

2. Cut through Switch :


It forwards the frame to the output buffer as soon as the destination address is Received.

Routers
A router is a three-layer device that routes packets based on their logical addresses (host-to-host addressing). A simplest function of routers is to receive packets from one connected network and pass them to a second connected network as shown in figure.

Router Figure Source : www.alliedtelesyn.com

A router normally connects LANs and WANs in the Internet and has a routing table that is used for making decisions about the route. The routing tables are normally dynamic and are updated using routing protocols. Router is capable of determining which of its connected networks is the best next relay point for the packet. Once a router has identified the best route for a packet to travel, it passes packet along the appropriate network to another router.

Routing Concepts :
Least-cost Routing :
Which path does it select? This decision is based on efficiency of the network. Means which of the available path is the cheapest or shortest?
In routing, shortest means the combination of cheapest, fastest, more secure, most reliable and so no.

Non-adaptive Routing :
In non-adaptive routing in which once a pathway to a destination has been selected, the router sends all packets for that destination along that one route.

Adaptive Routing :
In adaptive routing, a router may select a new route for each packet, In response to changes in condition and topology of the networks. Routers send the packets depending on which route is most efficient at that moment.

Example :
Packet transmission from network A to D.

Adaptive : Once the path A-B-D selected, so all the packets (whole message) are send
through this route (A-B-D).

Non-adaptive : Router send the first packet through the network B (means A-B-D)
Second Packet A-C-D, 3rd Packet A-E-D select best path on that moment. According to the information inside the routing table the router select the best path.

Routing table lists the following information.


Network addresses of each device, how to connect to other nodes (device), possible paths between routers, the cost of sending data over those paths.

Basically there are two types of routers :

1. Static Router 2. Dynamic Router

1. Static Router
Routing table informations are entered manually, means the administrator enters the router for each destination into the table. It can not update automatically when there is a change (Shutdown of routers or breaking of link Or some fault in connection) in the Internet. It is more secure, it is always use the same route.

2. Dynamic Router
Routing table is created automatically. Table updated using one of the dynamic routing protocols whenever there is a change in the Internet.

Gateway
Gateway is used to connect two different network systems as shown in figure. Gateway operate in all seven layers of OSI model. Gateway also called as protocol converter.

Gateway
Figure Source : www. archive.networknewz.com

Any device that translates one data format to another is called a gateway.
Some examples of gateways include a router that translates data from one network protocol to another, a bridge that converts between two networking systems, and a software application that converts between two dissimilar formats. The key point about a gateway is that only the data format is translated, not the data itself. In many cases, the gateway functionality is incorporated into another device. Gateway must adjust data rate, size and format. It converts the protocol from one network to another.

3.3 Servers
Text Book Name : Forouzen, Reference : www.en.wikipedia.org Server is a computer or a device which provides service to the other computers or workstations, attached to a network. There are many types of servers like:

- File Server - Print Server - Mail Server - Proxy Server - Web Server

File Server
File server is a computer attached to a network that has the primary purpose of providing a location for the shared storage of computer files (such as documents, sound files (audio files), movies (video files), photographs, databases, etc).
Those files can be accessed by the workstations that are attached to the computer network.

File server is a computer and storage device dedicated to storing files.


Any user on the network can store files on the server as shown in figure.

File Server
Figure Source : www.articleweekend.net

The term server highlights the role of the machine in client-server scheme, where the clients are the workstations using the server as storage. In a file server FTP (File Transfer Protocol) is used to transfer a file from one computer to another computer and retrieve the files from file server. A file server is usually not performing any calculations and does not run any programs on behalf of the clients. It is designed primarily to enable the rapid storage and retrieval of data where the heavy computation is provided by the workstations.

Application of File Server


File servers are commonly found in schools and offices and rarely seen in local internet service providers using LAN to connect their client computers.

Print Server
A print server is a computer that manages one or more printers. A print server or printer server is a computer or device that is connected to one or more printers add to client computers over a network, and can accept print jobs from the computers and send the print jobs to the appropriate printers. Print servers allow printers to be shared by other users on the network as shown in figure.

Print Server Figure Source : www.techpubs.sgi.com

Mail Server
Mail server is computer or storage area where E-mail is stored for local users. All the function of the mail server is performing by the MTA (Main Transfer Agent) used to transfers electronic mail messages from one computer to another. MTA works in the background, while the user usually interacts directly with a mail user agent. Transmission of mail from sender to receiver consists 3 stages:

First Stage
Email goes from the user to the local server through SMTP, mail is stored in the local server until it can be sent.

Second Stage
Email goes local server to mail access server. E-mail is received by this mail server and stored in the mailbox of the user for later retrieval.

Third Stage
In third stage e-mail goes to mailbox to remote server or mail access client.

SMTP (Simple Mail Transfer Protocol) is a standard protocol to sending e-mail messages between one system to another system or between servers.

POP3 (Post Office Protocol Version 3) protocol is used to retrieve e-mail from a mail server, although some can use the newer IMAP (Internet Mail Access Protocol) to receive an e-mail.
Mail servers move and store mail over corporate network and across the Internet.

Proxy Server
A proxy server is a server (a computer system or an application program) that acts as an intermediate for requests of its clients by forwarding requests to other servers as shown in figure. A server that sits between a client application such as a web browser and a real server.

Proxy Server Figure Source : www.gohacking.com

A client connects to the proxy server, requesting some service, such as a file, connection, web page, or other resource, available from a different server. The proxy server evaluates the request according to its filtering rules. For example, it may filter traffic by IP address or protocol. If the request is validated by the filter, the proxy provides the resource by connecting to the relevant server and requesting the service on behalf of the client. A proxy server may optionally alter the client's request or the server's response, and sometimes it may serve the request without contacting the specified server. In this case, it 'caches' responses from the remote server, and returns subsequent requests for the same content directly. A proxy server that passes requests and replies unmodified is usually called a gateway or sometimes tunneling proxy. A proxy server can be placed in the user's local computer or at various points between the user and the destination servers on the Internet.

Web Server
Web server is a computer that delivers web pages on the request to clients. Every web server has an IP address and possibly a domain name. Web servers serves static content to a web browser by loading a file from a disk and serving it across the network to a users web browser. The most common use of web servers is to host websites. The most common request is the Hypertext Transfer Protocol (HTTP), but there are also other requests like the Internet Message Access Protocol (IMAP) or the File Transfer Protocol (FTP). Web server is a computer program that is responsible for accepting HTTP, requests from web clients, which are known as web browsers, and serving them HTTP responses along with optional data contents, which usually are web pages such as HTML documents and images, etc.

CHAPTER 4 TCP/IP AND INTERNET


4.1 Internet architecture: Internet addresses, gateway addressing, network and broadcast addressing, dotted decimal notation, loopback addressing 4.2 Datagrams: IP datagram format, UDP frame format 4.3 IPv6

4.4 TCP: Introduction, frame format, connection establishment and termination

4.1 Internet architecture


Text Book Name : Forouzen : Page No : 549, Ref. Book Name : A. S. Tanenbaum

Internet Addresses
An Internet address uniquely identifies a node on the Internet. Internet address may also refer to the name or IP of a Web site (URL). The term Internet address can also represent someone's e-mail address.

Gateway Addresses
A gateway address is the next hop to which a packet goes to whenever the destination subnet is not present in the routing table for that specific packet. It can be manually configured in the connection's tcp/ip properties or automatically assigned by the DHCP (Dynamic Host Control Protocol) server.

Network Address
A network address serves as a unique identifier for a computer on a network. When set up correctly, computers can determine the addresses of other computers on the network and use these addresses to send messages to each other.

Broadcast Addressing
A broadcast address is a logical address at which all devices connected to a multipleaccess communications network are enabled to receive datagrams. A message sent to a broadcast address is typically received by all network-attached hosts, rather than by a specific host.

Doted-decimal Notation
Doted-decimal notation is a presentation format for numerical data. It consists of a string of decimal numbers, each pair separated by a full stop (dot).
A common use of dot-decimal notation is in information technology where it is a method of writing numbers in octet-grouped base-10 (decimal) numbers separated by dots (full stops).

An IP address (version 4) in both dot-decimal notation and binary code Figure Source : heavynetwork.blogspot.com

Loopback Addressing
Loopback address is a special IP number (127.0.0.1) that is designated for the software loopback interface of a machine. The loopback interface has no hardware associated with it, and it is not physically connected to a network. The loopback interface allows IT professionals to test IP software without worrying about broken or corrupted drivers or hardware.

4.2 Datagrams: IP datagram format, UDP frame format


Text Book Name : Forouzen : Page No : 583 to 588, Ref. Book Name : A. S. Tanenbaum Internet Protocol version 4 (IPv4) is the fourth revision in the development of the Internet Protocol (IP) and it is the first version of the protocol to be widely deployed. The figure shows the IPV4 datagram format.

IPV4 Header Format Figure Source : www.mars.netanya.ac.il

Version
Which version of the protocol the datagram belongs to. The current version number is 4. Next version: 6

IHL :
The number of 32-bit words in the header Because this is 4 bits, the max header length is 15 words (i.e. 60 bytes)

The header is at least 20 bytes, but options may make it bigger

Type of Service
Contains a 3-bit precedence field (that is ignored today), 4 service bits, and 1 unused bit.

The four service bits can be:


1000 - minimize delay 0100 - maximize throughput 0010 - maximize reliability 0001 - minimize monetary cost This is a "hint" of what characteristics of the physical layer to use The Type of Service is not supported in most. implementations. However, some implementations have extra fields in the routing table to indicate delay, throughput, reliability, and monetary cost.

Total Length
Total length of the datagram in bytes. We know where the data starts by the header length We know the size of the data by computing "total length - header length"

Identification
Uniquely identifies the datagram. Usually incremented by 1 each time a datagram is sent. All fragments of a datagram contain the same identification value. This allows the destination host to determine which fragment belongs to which datagram.

Flags and Fragmentation offset


Used for fragmentation DF means do not fragment. It is a request to routers not to fragment the datagram since the destination is incapable of putting the pieces back together.

MF means more fragments to follow. All fragments except the last one have this bit set. It is needed to know if all fragments of a datagram have arrived.

Fragment offset
Number of fragment.

Time to Live
Upper limit of routers.
Usually set to 32 or 64. Decremented by each router that processes the datagram.

Router discards the datagram when TTL reaches 0.

Protocol
Tells IP where to send the datagram up to. 6 means TCP 17 means UDP

Header Checksum
Only checks the header part of the datagram, not all the data.

Source IP address
This 32-bit provide source ip address.

Destination IP address
This 32-bit provide destination ip address.

Options
Optional data.

Some examples include having the router put in a IP address of router and a time stamp so the final destination knows how long it took to get to each hop.

UDP Frame Format


UDP uses a simple transmission model without implicit hand-shaking dialogues for providing reliability, ordering, or data integrity. Thus, UDP provides an unreliable service and datagrams may arrive out of order, appear duplicated, or go missing without notice. UDP assumes that error checking and correction is either not necessary or performed in the application, avoiding the overhead of such processing at the network interface level. The UDP header consists of 4 fields, each of which is 2 bytes (16 bits). The use of two of those is optional in IPv4 (pink background in table). In IPv6 only the source port is optional

UDP frame Format


Figure Source : www.en.wikipedia.org

Source port address


This field identifies the sender's port when meaningful and should be assumed to be the port to reply to if needed. If not used, then it should be zero. If the source host is the client, the port number is likely to be an ephemeral port number. If the source host is the server, the port number is likely to be a well-known port number.

Destination port address


This field identifies the receiver's port and is required. Similar to source port number, if the client is the destination host then the port number will likely be an ephemeral port number and if the destination host is the server then the port number will likely be a well-known port number.

Length
A field that specifies the length in bytes of the entire datagram: header and data. The minimum length is 8 bytes since that's the length of the header. The field size sets a theoretical limit of 65,535 bytes (8 byte header + 65,527 bytes of data) for a UDP datagram. The practical limit for the data length which is imposed by the underlying IPv4 protocol is 65,507 bytes (65,535 8 byte UDP header 20 byte IP header).

Checksum
The checksum field is used for error-checking of the header and data. If no checksum is generated by the transmitter, the field uses the value all-zeros. Packet produced at transport layer by UDP is called user datagram UDP is faster than TCP

4.3 IPv6
Text Book Name : Forouzen : Page No : 596, Ref. Book Name : A. S. Tanenbaum IPv6 Internetwork Protocol Version 6 IPv6 also known as IPing (Internetworking Protocol, next generation) In IPv6, format and the length of the IP addresses were changed along with the packet format. IPv6 provide 128 bits addressing IPv6 has some advantages over IPv4 Features of IPv6 : 1. Large Address Space 2. Better Header Format 3. New Options 4. Allowance for extension of protocol 5. Support for Resource Allocation 6. Support for more Security

4.4 TCP: Introduction, frame format, connection establishment and termination


Text Book Name : Forouzen : Page No : 721 to 727, Ref. Book Name : A. S. Tanenbaum

TCP : Introduction
TCP (Transmission Control Protocol) provides full transport layer service to the applications. It is reliable and connection oriented Protocol. It is port-to-port protocol. (means one process in one computer to the one process in another computer provides service-point addressing [port addressing]) It is connection oriented protocol means connection must be established between both ends of a transmission before either may transmit data TCP generates a virtual circuit between sender and receiver that is active for the duration of transmission. TCP divides long data into smaller data units i.e. called segment. Packets produced at transport layer are called segments. Each segment includes a sequencing number for reordering receipt, together with an acknowledgement ID number and a window-size field for flow controlling. Error controlling and flow controlling is handled by TCP.

TCP : Frame Format


Figure shows TCP frame format or segment format.

TCP frame Format


Figure Source : www.techrepublic.com

Source Port Address


This 16 bits field defines port number of the application program in the source computer.

Destination Port Address


This 16 bits field defines port number of the application program in the destination computer.

Sequence Number
The bytes of data being transferred are numbered by TCP. This numbering of bytes are called byte number.

After bytes have been numbered, TCP assign a sequence number to each segment that is being sent. The sequence number for each segment is the number of the first byte carried in that segment. [ First byte number in first segment is first sequence number. Fist byte number in second segment is second sequence number and so on.]

Acknowledgement Number
This 32 bits field defines the byte number that are the receiver wants to receive. If the byte number x has been successfully received, x+1 is the acknowledgement number.

HLEN Header Length


This 4 bit field indicates the number of 4-byte words in the TCP header. Length of header can be between 20 and 60 bytes.

Reserved
This is a 16-bit field reserved for future use.

Control Field :
This field defines 6 different control flags.

1. URG - Urgent
URG = 1, The value of urgent pointer field is valid

2. ACK - Acknowledgement
ACK = 1, Value of acknowledgement field is valid

3. PSH Push the data


PSH = 1, Request for push data

4. RST - Reset
RST = 1, The connection must be reset

5. SYN - Synchronize
SYN = 1, Synchronize sequence number during connection

6. FIN - Finished
FIN = 1, Terminate the connection

Window Size
This 16 bits field defines the size of the sliding window. This field is used for flow controlling.

Checksum
This 16 bits field used in error detection.

Urgent Pointer
This field is only valid when URG flag is set. It is a pointer that points to the location from which urgent data starts. Sender is informing the receiver that there are urgent data in the portion of the segment.

Option
This field is up to 40 bytes of optional information in the TCP header. Extra features or functionalities are added in this field.

TCP : Connection establishment and termination


TCP is connection oriented protocol. In TCP, connection oriented transmission requires 3 procedures: (1) Connection Establishment (2) Data Transfer (3) Connection Termination

(1) Connection establishment :

Figure Source : www.wiki.mikrotik.com

(2) Data Transfer :


Now the actual data will be transferred.

(3) Connection termination :

Figure Source : www.wiki.mikrotik.com

CHAPTER 5 INTRODUCTION TO HIGH SPEED NETWORKING TECHNOLOGIES


5.1 Cable modem system 5.2 Digital Subscriber Line technology: HDSL and ADSL 5.3 Fast Ethernet 5.4 Gigabit Ethernet

5.5 FDDI and CDDI

5.1 CABLE MODEM


Text Book Name : Forouzen, Reference : www.lchu.net

A cable modem is an external device that allows your computer to connect to the Internet through a cable TV wire, instead of a telephone line (or another system). Basically you just connect the Cable Modem to the TV outlet for your cable TV, and the cable operator connects a Cable Modem Termination System (CMTS) in his end (the Head-End). A cable modem can be added to or integrated with a set-top box that provides your TV set with channels for Internet access. In most cases, cable modems are furnished as part of the cable access service and are not purchased directly and installed by the subscriber. A subscriber can continue to receive cable television service while simultaneously receiving data on cable modems to be delivered to a personal computer (PC) with the help of a simple one-to-two splitter (see Figure 5.1). The data service offered by a cable modem may be shared by up to sixteen users in a local-area network (LAN) configuration.

A cable modem has two connections: one to the cable wall outlet and the other to a PC or to a set-top box for a TV set.

Cable Modem at the subscriber Location

Figure Source : www.lchu.net

A cable modem does modulation between analog and digital signals, it is a much more complex device than a telephone modem. It can be an external device or it can be integrated within a computer or set-top box. In a business environment, the cable modem interfaces with a local area network (LAN) through an Ethernet hub, switch or router, providing access to multiple users through a single cable modem.

Business Environment Figure Source : www.lchu.net

Types of Cable Modems :


A number of different Cable Modem configurations are possible. These three configurations are the main products nowadays. 1) External Cable Modem 2) Internal Cable Modem 3) Interactive Set-Top Box

External Cable Modem :


The external Cable Modem is the small external box that connects to your computer normally through an ordinary Ethernet connection. The downside is that you need to add a (cheap) Ethernet card to your computer before you can connect the Cable Modem. A plus is that you can connect more computers to the Ethernet. Also the Cable Modem works with most operating systems and hardware platforms, including Mac, UNIX, laptop computers etc. Another interface for external Cable Modems is USB, which has the advantage of installing much faster. The downside is that you can only connect one PC to a USB based Cable Modem.

Internal Cable Modem :


The internal Cable Modem is typically a PCI bus add-in card for a PC. That might be the cheapest implementation possible, but it has a number of drawbacks. First problem is that it can only be used in desktop PC's. Mac's and laptops are possible, but require a different design and many more drawbacks.

Interactive Set-Top Box :


The interactive set-top box is really a cable modem in disguise. The primary function of the set-top box is to provide more TV channels on the same limited number of frequencies. An interactive set-top box provides a return channel - often through the ordinary plain old telephone system (POTS) - that allows the user access to web-browsing, email etc. directly on the TV screen.

Advantages of Cable Modem :


1) Speed
The peak Internet connection speed using a cable modem is over 100 times faster than a standard 28.8 modem. Cable modems will be able to receive data at up to 10 Mbps and send data at speeds up to 2 Mbps (some up to 10 Mbps).

2) Always-on service
Cable modem service is always on. With a cable modem, you will receive a constant stream of information to your computer. You will not experience busy signals, dial-up errors, or disconnects due to inactivity. Cable modem access transforms the Internet into an important tool that you can use every day, because getting information on the Internet is faster and easier than looking in the paper or the Yellow Pages.

3) Cost
Cable Internet access is as cost-effective as dial-up services, even though dial-up services are significantly slower. For one fixed monthly fee, you get unlimited Internet access without having to pay the "hidden costs" of an extra telephone line or additional usage charges. Often, the cost of a second phone line is the difference between the cost of cable modem service and dial-up service.

Disadvantages of Cable Modem :


Disadvantage of cable modems is the shared bandwidth to the cable head-end. You and your neighbors share the same cable which should be able to carry about 30 MBit/sec total bandwidth. The access points to the Internet (gateway) as well as the Internet itself turn out to be slower than the local cable loop. Another problem of shared bandwidth is security. There are still some cable modem systems in existence that do not encrypt/filter traffic within the local cable loop.

Applications of Cable Modem :


Cable modem technology offers high-speed access to the Internet and World Wide Web services. Cable data networks integrate the elements necessary to advance beyond modem technology and provide such measures as privacy, security, data networking, Internet access, and quality-of-service features.

5.2 DSL (Digital Subscriber Line)


Text Book Name : Forouzen : Page No : 251 to 255, Ref. Book Name : A. S. Tanenbaum After the traditional modems, to provide higher-speed access to the Internet, telephone companies developed another technology, DSL (Digital Subscriber Line). DLS technology is one of the most promising for supporting high-speed digital communication over the existing local loops. The term Digital Subscriber Line is widely understood to mean Asymmetric Digital Subscriber Line (ADSL), the most commonly installed technical variety of DSL. Digital Subscriber Line technology is a set of technologies, each differing in the first letter (ADSL, VDSL, HDSL and SDSL).

ADSL (Asymmetric Digital Subscribe Line) :


The first technology in the set is Asymmetric Digital Subscribe Line (ADSL), ADSL, like 56k modem, provides higher speed (bit rate) in the downstream (from the Internet to the resident) than in the upstream direction (from the resident to the internet). That is the reason it is called asymmetric. The service is not suitable for business customers who need a large bandwidth in both directions. ADSL uses the existing local loops. But how does ADSL reach a data rate that was never achieved with traditional modems? The answer is that the twisted-pair local loop is actually capable of handling bandwidths up to 1.1 MHz.

ADSL used an adaptive technology that tests the condition and bandwidth availability of the line before setting on a data rate. The data rate of ADSL is not fixed; it changes based on the condition and type of the local loop cable.

The modulation technique used by ADSL is called the discrete multitone technique (DMT) which combines QAM and FDM. Typically, and available bandwidth of 1.1 MHz is divided into 256 channels.
Channel 0 is reserved for voice communication. Channels 1 to 5 are not used and provide a gap between voice and data communication. Channels 6 to 30 (25 Channels) are used for upstream data transfer and control. One channel is for control and 24 channels are for data transfer. Channels 31 to 255 (225 Channels) are used for downstream data transfer and control. One channel is for control, and 224 channels are for data. The figure 5.3 shows an ADSL modem installed at a customers site. The local loop connects to a splitter which separates voice and data communications. The ADSL modem modulates and demodulates the data, using DMT (Digital Multitone Technique), and creates downstream and upstream channels.

ADSL modem Figure Source : www.netidea.com


A new version of ADSL technology called ADSL Lite (or Universal ADSL splitter less ADSL) is available for these subscribers. It can provide a maximum downstream data rate of 1.5 mbps and an upstream data rate of 512 kbps.

HDSL (High-bit-rate Digital Subscribe Line) :


The high-bit-rate digital subscriber line (HDSL), was designed as an alternative to the T1 line (1.544 Mbps). The T-1 line uses alternate mark inversion (AIM) encoding, which is very susceptible to attenuation at high frequencies. The length of T-1 line is 3200 ft (1 km). For longer distance, a repeater is necessary, which means increased costs. HDSL uses 2B1Q encoding, which is less susceptible to attenuation. A data rate of 1.544 Mbps (sometimes up to 2 Mbps) can be achieved without repeaters up to a distance of 12000 ft (3.86 km). HDSL uses two twisted pairs (one pair for each direction) to achieve full-duplex transmission.

5.3 FAST ETHERNET


Text Book Name : Forouzen : Page No : 409 to 412, Ref. Book Name : A. S. Tanenbaum

Fast Ethernet (100BASE-T) offers a speed increase ten times that of the 10BaseT Ethernet specification, while preserving such qualities as frame format, MAC mechanisms, and MTU. Such similarities allow the use of existing 10BaseT applications and network management tools on Fast Ethernet networks. Officially, the 100BASE-T standard is IEEE 802.3u. Like Ethernet, 100BASE-T is based on the CSMA/CD LAN access method. There are several different cabling schemes that can be used with 100BASE-T, including: 100BASE-TX: two pairs of high-quality twisted-pair wires

100BASE-T4: four pairs of normal-quality twisted-pair wires

100BASE-FX: fiber optic cables

The Fast Ethernet specifications include mechanisms for Auto-Negotiation of the media speed. This makes it possible for vendors to provide dual-speed Ethernet interfaces that can be installed and run at either 10-Mbps or 100-Mbps automatically.
The TX and FX medium standards are collectively known as 100BASE-X.

The 100BASE-TX and 100BASE-FX media standards used in Fast Ethernet are both adopted from physical media standards first developed by ANSI, the American National Standards Institute.

5.4 GIGABIT ETHERNET


Text Book Name : Forouzen : Page No : 412 to 415, Ref. Book Name : A. S. Tanenbaum

Gigabit Ethernet (GbE or 1 GigE) is a term describing various technologies for transmitting Ethernet frames at a rate of a gigabit per second (1,000,000,000 bits per second), as defined by the IEEE 802.3-2008 standard. Half-duplex gigabit links connected through hubs are allowed by the specification but in the marketplace full-duplex with switches is normal. Under the International Standards Organizations Open Systems Interconnection (OSI) model, Ethernet is fundamentally a Layer 2 protocol. 10 Gigabit Ethernet uses the IEEE 802.3 Ethernet Media Access Control (MAC) protocol, the IEEE 802.3 Ethernet frame format, and the minimum and maximum IEEE 802.3 frame size. Just as 1000BASE-X and 1000BASE-T (Gigabit Ethernet) remained true to the Ethernet model, 10 Gigabit Ethernet continues the natural evolution of Ethernet in speed and distance. Since it is a full-duplex only and fiber-only technology, it does not need the carrier-sensing multiple-access with collision detection (CSMA/CD) protocol that defines slower, half-duplex Ethernet technologies. In every other respect, 10 Gigabit Ethernet remains true to the original Ethernet model.

1000BASE - X
1000BASE-X is used in industry to refer to gigabit Ethernet transmission over fiber, where options include 1000BASE-CX, 1000BASE-LX, and 1000BASE-SX, 1000BASE-LX10, 1000BASE-BX10 or the non-standard -ZX implementations.

1000BASE - T
1000BASE-T (also known as IEEE 802.3ab) is a standard for gigabit Ethernet over copper wiring. Each 1000BASE-T network segment can be a maximum length of 100 meters (328 feet), and must use Category 5 cable or better. Category 5e cable or Category 6 cable may also be used.

5.5 FDDI And CDDI


Text Book Name : Forouzen, Reference : www.techpubs.sgi.com

FDDI (Fiber Distributed Data Interface) :


FDDI (Fiber Distributed Data Interface) is a set of ANSI and ISO standards for data transmission on fiber optic lines in a local area network (LAN) that can extend in range up to 200 km (124 miles). The FDDI protocol is based on the token ring protocol. In addition to being large geographically, an FDDI local area network. Can support thousands of users, FDDI is frequently used on the backbone for a wide area network (WAN). An FDDI network contains two token rings, one for possible backup in case the primary ring fails. The primary ring offers up to 100 Mbps capacity. If the secondary ring is not needed for backup, it can also carry data, extending capacity to 200 Mbps. The single ring can extend the maximum distance; a dual ring can extend 100 km (62 miles).

Figure shows the basic FDDI ring.

A basic FDDI ring Figure Source : www.techpubs.sgi.com

FDDI Devices :
In addition to the FDDI components, the FDDI standard defines the types of devices that can be connected to the ring. These devices include the following:

Stations
DAS: dual attach station (usually attaches directly to FDDI dual ring) SAS: single attach station (attaches to the FDDI ring through a concentrator)

Concentrators
DAC: dual attach concentrator (usually attaches directly to the FDDI dual ring) SAC: single attach concentrator (attaches to the FDDI ring through another concentrator) FDDI is a product of American National Standards Committee and conforms to the Open Systems Interconnection (OSI) model of functional layering. It can be used to interconnect LANs using other protocols.

FDDI-II is a version of FDDI that adds the capability to add circuit-switched service to the network so that voice signals can also be handled. Work is underway to connect FDDI networks to the developing Synchronous Optical Network (SONET).

Advantages of FDDI :
FDDI supports real-time allocation of network bandwidth.

This allows you to use a wide array of different types of traffic.


FDDI has a dual ring that is fault-tolerant. The benefit here is that if a station on the ring fails or if the cable becomes damaged, the dual ring is automatically doubled back onto itself into a single ring.

The FDDI compensates for wiring failures. The stations wrap within themselves when the wiring fails.

Disadvantages of FDDI :
There's a potential for multiple ring failures. As the network grows, this possibility grows larger and larger. The use of fiber optic cables is expensive.

CDDI (Copper Distributed Data Interface) :


CDDI is a version of FDDI (Fiber Distributed Data Interface) designed to run on shielded and unshielded twisted-pair cable instead of fiber-optic cables. CDDI supports a dual-ring capacity of 200 Mbps. CDDI's maximum distance is up to 200 meters, which is much shorter than FDDI. CDDI is defined by the American National Standards Committee and conforms to the Open Systems Interconnection (OSI) model of functional layering. CDDI is officially named the Twisted-Pair Physical Medium Dependent (TP-PMD) standard and is also referred to as Twisted Pair Distributed Data Interface (TP-DDI).

CHAPTER 6 INTERNET APPLICATIONS


6.1 Domain Name System: Introduction, mapping to IP addresses 6.2 World Wide Web: Web browser, HTML, web servers 6.3 Electronic Mail: - Functions of E-mail system

- Message format
- User agent

6.1 DNS (Domain Name Server)


Text Book Name : Forouzen : Page No : 797 to 807, Ref. Book Name : A. S. Tanenbaum

Domain name system is a client server application that identifies each host on the internet, with a unique user friendly name. Domain name system is a method to identifying hosts with user friendly names instead of ip addresses. Because to remember numeric addresses are difficult compare to names.

In Domain Name System names must be unique because the addresses are unique.
Each Domain is partitioned into sub domains. Once an Organization assigned domain name, the name is reserved for the Organization, means no other Organization will be assigned the same name. To map a name into IP address, an application program calls a library procedure called the Resolver, passing it the name as a Parameter. The Resolver sends a UDP packet to local DNS server, which then looks up the name and returns the IP address to the resolver, which then returns it to the caller process. Domain names are always read from the bottom to top.

Domain Name Server :


Information contained in the domain name system must be stored. It is very difficult and not reliable to have just one computer store such large information. To solve above problem, we have to distribute the information among many computer called DNS servers. The hierarchy of servers shown below:

Domain Name Server Figure Source : www.ntchosting.com

DNS in the internet :


In the internet domain name space is divided into three different sections. 1. Generic domain 2. Country domain 3. Inverse domain

1. Generic domain : Generic domain defines registered host according to their generic
behavior. Each node in the tree defines a domain.

Figure Source : www.harrykar.blogspot.com

In first level, generic domain uses three character code

LABLE Com Edu Gov Int Mil Net

DESCRIPTION Commercial Organization Educational Institutions Government Institutions International Organization Military Groups Network Organization

Org

Non profit Organization

2. Country domain : The Country domain uses a two-character abbreviation in place of


three character abbreviation at first level.

Figure Source : www.harrykar.blogspot.com

3. Inverse domain: The inverse domain is used to map address to a name.


When a server has received a request from a client to do a task, server lists only the IP address of the client. To determine if the client is on the authorized list, the server can send a query to the inverse DNS server and ask for a mapping of address to name. The inverse domain is added to the domain name space with the first-level node called arpa. (Advanced Research Projects Agency) The second level is also one single node named in-addr. (for inverse address) The rest of the domain defines IP address.

Figure Source : www.harrykar.blogspot.com

6.2 WWW (World Wide Web)


Text Book Name : Forouzen : Page No : 851 to 857, Ref. Book Name : A. S. Tanenbaum

The World Wide Web (WWW) is a collection of information linked together from points all over the world. The WWW has a unique combination of flexibility, portability, and user-friendly features that distinguish it from other services provided by the Internet. The World-Wide Web was developed at CERN (European Laboratory for Particle Physics) in Geneva, to create a system to handle distributed resources. The WWW today is a distributed client/server service, in which a client using a browser can access a service using a server. The World-Wide Web was developed to be a pool of human knowledge, and human culture, which would allow collaborators in remote sites to share their ideas and all aspects of a common project.

However, the service provided is distributed over many locations called sites, as shown in Figure below:

Architecture of WWW Figure Source : Data Communication & Networking, -Forouzen (Page no )

Each site holds one or more documents, referred to as Web Pages. Each web page can contain a link to other pages in the same site or at other sites. The pages can be retrieved and viewed by using browsers. As shown if figure-(a), the client send a request through its browser, a program that is designed to fetch Web documents. The request includes address of the site and the Web page, called the URL (Uniform Resource Locator). URL defines four things: protocol, host computer, port address, and path as shown below:

PROTOCOL

://

HOST

PORT

PATH

The protocol is the client/server program used to retrieve the document. Many different protocols can retrieve a document; among them are FTP and HTTP. The most common protocol is HTTP (Hyper Text Transfer Protocol). HTTP is a protocol used mainly to access data on the World Wide Web. HTTP functions as a combination of FTP and SMTP. There is no separate control connection; only data are transferred between the client and the server. The host is the computer on which the information is located. Web pages are usually stored in computers. The URL can optionally contain the port number of the server. If the port is included, it is inserted between the host and the path, and it is separated from the host by a colon. Path is the pathname of the file where the information is located.

According to the figure-(a), the server at the site A finds the document and sends it to the client. The client sends another request to the new site, and the new page is retrieved. The retrieved page is in HTML form, Hyper Text Markup Language is a language for creating Web pages. Web pages are formatted by HTML tags for interpretation by a browser. For example the text displayed in boldface with HTML, we put beginning and ending boldface tags in the text, as shown below:

<B>

THIS TEXT IS I N BOLDFACE

</B>

The two tags <B> and </B> are instructions for the browser. When the browser sees these two marks, it knows that the text must be boldfaced.

A markup language such as HTML allows us to formatting instructions in the file itself. The instructions are included with the text. In this way, any browser can read the instructions and format the text according to the specific workstation.
The web page is stored in Server. Each time a client request arrives, the corresponding document is sent to the client. To improve efficiency, servers normally store requested files in a cache in memory; memory is faster to access than disk. A server can also more efficient through multiprocessing. In this case, a server can answer more than one request at a time.

6.3 E-Mail (Electronic Mail)


Text Book Name : Forouzen : Page No : 824 to 839, Ref. Book Name : A. S. Tanenbaum Electronic mail, often abbreviated to E-mail, or simply mail, is a store & forward method of writing, sending, receiving, and saving messages over internet.

E-mail is most popular network services, used to send messages to others on the network.
To send an E-mail to someone, you just need their E-mail ID means address which is divided in two parts, the username and the domain name. These two parts are separated by @ sign. A typical E-mail address might read,

SMTP (Simple Mail Transfer Protocol) is the standard protocol use for electronic mail in the internet.

Message Format :
Sending Mail :
To send mail, the user creates mail that looks like similar to postal mail. It has an Envelope and a Message (see the figure)

Message Format Figure Source : Data Communication & Networking, -Forouzen (Page no )

Envelope contains the sender address, the receiver address and other information.
Message contains the header and body. Header of the message contains the address of the
sender, receiver and subject of the message, date etc.

Body of the message contains the actual information to be read by the recipient. Receiving Mail :
The e-mail system periodically checks the mailboxes. If user has mail, it informs the user with a notice. If the user is ready to read the mail, a list of mail displayed with sender address, subject, date and time the mail was sent etc. The user can select any of the messages and display its contents on the screen.

Addresses :
To deliver mail, a mail handling system must have an addressing system with unique addresses.

The addressing system used by SMTP consists of two parts:

1) Local part 2) Domain Name


Both are separated by @ sign.

Figure Source : Data Communication & Networking, -Forouzen (Page no ) 1) Local Part: It defines the name of a special file, called the user mailbox, where all the mail
received for a user is stored.

2) Domain Name: The second part of the address is the domain name. An organization
selects one or more hosts to receive & send e-mail, they are sometimes called mail exchangers.

User Agent :
The user agent prepares the message, creates the envelope and puts the message in envelop. Mail transfer agent (MTA) transfers the mail across the internet. Services Provided by user agent :

1. Composing Messages

2. Reading Messages

3. Replying Messages

4. Forwarding Messages

5. Handling Mailboxes

1. Composing Messages :
User agent provides a template or a form on the screen to be filled in by the user. A user can use their favorite text editor or word processor to create the message and impart it or cut and paste into the uses agent.

2. Reading Messages :
When a user login, first User Agent checks the mail in the incoming mailbox.
User Agent show a one-line summary of each received mail which contain following details number field of the message, the size of the message, the sender name, the subject field, flag field, which shows if the mail is new, already read but not replied, read and replied and so on.

3. Replying Messages :
After reading message, a user can use the user agent to reply to a message. The reply message contains the original message and the new message.

4. Forwarding Messages :
Forwarding means to send the message to the third party.
User Agent allows the receiver to forward the message, with or without extra comments to a third party.

5. Handling Mailboxes :
A uses agent creates two mailboxes :-

(1) Inbox (2) Outbox


Each box is a file with special format that can be handled by the user agent. The inbox keeps the entire received emails until they are deleted by the user.

The outbox keeps all the send emails until the user deletes them.

Mail Delivery System :


Transmission of mail from sender to receiver consists of 3 stages :

(1) First Stage :


Email goes from the user agent to the local server through SMTP, mail server until it can be sent. is stored in the local

(2) Second Stage :


Email goes local server to mail access server. E-mail is received by this mail server and stored in the mailbox of the user for later retrieval.

(3) Third Stage :


In third stage e-mail goes to mailbox to remote server or mail access client.

Mail Protocols :
SMTP (Simple Mail Transfer Protocol)
POP3 (Post Office Protocol Version 3)

IMAP4 (Internet Mail Access Protocol Version 4)

MIME (Multipurpose Internet Mail Extensions) SMTP is a standard protocol to sending e-mail messages between one system to another system or between servers.

POP3 protocol is used to retrieve e-mail from a mail server, although some can use the newer IMAP protocol to receive an e-mail.

MIME used to formatting non-ASCII messages so that they can be sent over internet

You might also like