You are on page 1of 49

ADVANCES IN COMPUTERS

COMPUTER NETWORKS

We will learn about the following topics:


WHY A COMPUTER NETWORK? STANDARDIZATION THEORY: THE OSI MODEL REALITY: THE INTERNET NETWORK CLASSIFICATION MEDIA AND BASIC HARDWARE AN EXAMPLE: THE ETHERNET INTERNET ADDRESSING SUBNETS AND ROUTING WHERE TO FIND MORE

WHY A COMPUTER NETWORK?


The main reasons are: Distribute pieces of computation among computers (nodes) Coordination between processes running on different nodes Remote I/O Devices Remote Data/File Access Personal communications (like e-mail, chat, audio/video conferencing) World Wide Web ... and many other uses

WHY DO I NEED A STANDARD ?


There are: Many types of connection media : telephone lines, optical fibers, cables, radios, etc. Many different types of machines and operating systems Many different network applications so the need for a STANDARD in communication technology: OSI

WHAT "STANDARD" MEANS ?


Agreements must be at many levels ... How many volts pulse is a 0 and 1? How to determine the end of a message? How to handle lost messages? How many bits for different data types? Integers/Strings, etc. Are characters coded in ASCII ? How machines are identified in a network? Names, numbers ? How to find the way to reach a machine ? How if there are more choices ? How different applications (and OSs) speaks together through the network ?

THE ISO STANDARD MODEL FOR COMMUNICATIONS: OSI


ISO (the International Organization for Standardization) has developed a standard model for communications, called the OSI (Open Systems Interface) Model Model = it means that it's only theory! In fact the OSI model is not yet fully implemented in real networks. Open System : It can communicate with any other system that follows the specified standards, formats, and semantics. Protocols give rules that specify how the communication parties may communicate. Supports two general types of protocols. Both are common. Connection-Oriented : Sender and receiver first establish a connection, possibly negotiate on a protocol. (virtual circuit) Transmit the stream of data. Release the connection when done. E.g. Telephone connection. Connectionless No advance setup is needed. Transmit the message ( datagrams ) when sender is ready. E.g. surface mail

THE 7 LAYERS OF OSI


STRUCTURE

OSI MODEL
The OSI model consists of 7 layers : Each layer deals with a specific aspect of communication. Each layer provides an interface to the layer above. The set of operations define the service provided by that layer. As a message sent by the top layer is passed on to the next lower layer until the most bottom layer. At each level a header may be prepended to the message. Some layers add both a header and a trailer. The lowest layer transmits the message over the network to the receiving machine. It communicates with the most bottom layer of the receiver. Each layer then strips the header (trailer), handles the message using the protocol provided by the layer and passes it on to the next higher layer. Finally to the highest layer in the receiver.

(1) Physical Layer


Concerned with the transmission of bits. How many volts for 0, how many for 1? Number of bits of second to be transmitted. Two way or one-way transmission Standardized protocol dealing with electrical, mechanical and signaling interfaces. Many standards have been developed, e.g. RS232 (for serial communication lines). Example : X.21

(2) Data Link Layer


Handles errors in the physical layer. Groups bits into frames and ensures their correct delivery. Adds some bits at the beginning and end of each frame plus the checksum. Receiver verifies the checksum. If the checksum is not correct, it asks for retransmission. (send a control message). Consists of two sublayers: Logical Link Control (LLC) defines how data is transferred over the cable and provides data link service to the higher layers. Medium Access Control (MAC) defines who can use the network when multiple computers are trying to access it simultaneously (i.e. Token passing, Ethernet [CSMA/CD]).

(3) Network Layer


Concerned with the transmission of packets. Choose the best path to send a packet ( routing ). It may be complex in a large network (e.g. Internet). Shortest (distance) route vs. route with least delay. Static (long term average) vs. dynamic (current load) routing. Two protocols are most widely used. X.25 Connection Oriented Public networks, telephone, European PTT Send a call request at the outset to the destination If destination accepts the connection, it sends an connection identifier IP (Internet Protocol) Connectionless Part of Internet protocol suite. An IP packet can be sent without a connection being established. Each packet is routed to its destination independently.

(5) Sessions Layer


Just theory! Very few applications use it. Enhanced version of transport layer. Dialog control, synchronization facilities. Rarely supported (Internet suite does not).

(6) Presentation Layer


Just theory! Very few applications use it. Concerned with the semantics of the bits. Define records and fields in them. Sender can tell the receiver of the format. Makes machines with different internal representations to communicate. If implemented, the best layer for cryptography.

(7) Application Layer


Collection of miscellaneous protocols for high level applications Electronic mail, file transfer, connecting remote terminals, etc. E.g. SMTP, FTP, Telnet, HTTP, etc.

THE REAL STANDARD FOR COMMUNICATIONS: THE INTERNET


The INTERNET and TCP/IP Reference model (aka "the Internet suite"): Is the standard de facto for the majority of networks It has only four :

OSI Presentation and Session layers are missing The Internet layer (OSI: Network) handles packets The Host-To-Network layer (OSI: Datalink + Physical) handles frames and bits

HOW TO MEASURE A NETWORK ?


Performance parameters: Latency: Time required to transfer an empty message between relevant computers. Sum total of delay introduced by the sender software. delay introduced by the receiver software. delay in accessing the network. delay introduced by the network. Data transfer rate: is the speed at which data can be transferred between sender and receiver in a network, once transmission has begun. (bit/sec) Message transfer time = latency + (length of message) / (Data transfer rate). Bandwidth : is the total volume of traffic that can be transferred across the network. Max. data rate (bit/sec) = carrier BW log2 (1 + (signal/noise)) this maximum (Shannon's Limit) is theoretical, not reachable in practice! Ex.: phone line BW = 3 kHz, S/N = 30 dB = 1000 Max. data rate = 30 kbit/sec

HOW BIG ARE NETWORKS?


Networks can be divided into three types based on geographical areas covered: LANs : Local Area Networks

MANs : Metropolitan Area Networks

WANs : Wide Area Networks

WHICH MEDIUM?
There are four principal media for telecommunications: COAXIAL CABLE TWISTED PAIR CABLE OPTICAL FIBER

WIRELESS

MEDIA CHARACTERISTICS
Coaxial Cable Used extensively in LANs. Single central conductor surrounded by a circular insulation layer and a conductive shield. High bandwidth : Upto 400 Mhz. High quality of data transmission. Max. used data rates : 100 Mbits/s. Problems : signal loss at high frequencies. Twisted Pair Cable Extensively used in telephone circuits, where several wires are insulated and put together. Bandwidth :250 Khz. Low signal to noise ratio (cross talk) -> Low data rate. Good for short-distance communications. Used in LAN (UTP or 10baseT).

MEDIA CHARACTERISTICS
Optical Fiber High quality and high bandwidth data transmission applications. Use light instead of electric pulses for message transmission. Very high frequency ranges (20,000 Mhz). Single fiber can support over 30,000 telephone lines. Data transmission rates of 400 Mbits/s and more. Becoming very popular for MAN and LAN, also used for intercontinental links. High signal to noise ratio, difficulty in tapping (security). Cost is the single biggest drawback (currently). Wireless Media For WANs satellites provide global communication over the world, receiving signals from transmitters and relaying them back to the receivers. With geostationary satellites senders and receivers always points the same direction. High communication capacity. Big latency : 0.25 secs. For MANs microwave radio technology is widely used (2 to 24 Mbit/s). For LANs Spread Spectrum radio technology is becoming very popular (up to 2 Mbit/s). Infrared : Line of sight limitation.

WHICH HARDWARE FOR COMPUTER NETWORKING ?


Common requirements are: Connect networks of different types, different vendors. Provide common communication facilities and hide different hardware and protocols of constituent networks. Needed for extensible open distributed systems Network adapter : interfaces a computer board with the network medium Repeater : two-ports electronic device that just repeats what receives from one port to the other. Bridge : a more sofisticated repeater with logic capabilities that filters packets (OSI level 2). Hub : multi-port repeater Switch : multi-port bridge Router : links two or more networks (different types too), passing messages with appropriate routing information. It operates at OSI level 3. Must have extensive knowledge of the internetwork (routing tables) Gateway : Similar to routers, links two networks. Can also operate at OSI levels higher than 3.

THE ETHERNET
Developed at Xerox PARC in 1973. It's a standard for Media Access Control (MAC) sublayer. Data transmission rate : 10 Mbits/s (Fast Ethernet reaches 100 Mbit/s) High-speed driver on the computers connected by coax or UTP cables. Uses a bus (10base2, coax, max. distance 200 mt.) or a star (10baseT, UTP, max. 100 mt.) topology. Can be optical fibres based too (10baseF , max. 2000 mt.). How it works? All nodes wanting to send message contention for the bus. Broadcast frames to all stations on the network. All stations are continually listening to the bus looking for frames addressed to them. Variable length frames : 64 to 1518 bytes. Transmission time : 50 - 1200 microsec.

ETHERNET:
Frame Format : Destination address (6 bytes) Source address (6 bytes) Type (2 bytes) Data (46 ... 1500 bytes) Check sequence/checksum (4 bytes). Length of the frame is not provided. Mandatory interval between sending frames. Last 4bytes are assumed to be the frame check sequence (checksum). Type field is sometimes used to store the length of the frame. Not more than 1024 nodes in a single Ethernet, but the address field is 6 bytes. US Institute for IEEE gives a unique id for each Ethernet card. Each node has a unique address. CSMA/CD : Carrier Sense Multiple Access with Collision Detection Packet Collisions : When multiple stations attempt to send a frame simultaneously. Three mechanisms to address this.

ETHERNET :
Carrier Sensing : Listen for the presence of signal (carrier) in the cable. Wait until there is no signal before transmitting. Collisions may still occur. A sends a signal and B sends it right after that but before it has sensed A's signal. Collision Detection : Send the signal (output port) and listen (input port) and compare the two signals. If they are different then there is a collision. Stop sending the message but send a special signal to intimate all stations that collision has occurred. Retransmit after waiting for a random time (nT) : T : time taken by a signal to reach all stations, n < MAX: random number. If there is another collision, double MAX and so on. CSMA/CD Efficiency : Fraction of frames transmitted successfully. Possible to get 80 - 95 %. However, noticeable delay after 50%.

ETHERNET
Interconnecting Ethernets : Repeater : Analog device that simply retransmits the signal it receives. Bridge : Digital so less distortion, may be intelligent, it repeats frames passing only the addresses that are on the corresponding side of the bridge (filtering). Keep a list of addresses. (Note: Each ethernet address is unique)

WHAT ARE 10Base5, 10Base2, 10BaseT & 10BaseF ETHERNET ?


In Project 802, the IEEE established specifications for cables carrying Ethernet signals. 10Base5, 10Base2, 10BaseT and 10BaseF (FOIRL [Fiber Optic Inter Repeater Link]) refer to thick coaxial, thin coaxial, unshielded twisted-pair and fiber-optic cables respectively. The "10" refers to the Ethernet transmission speed - 10Mbit/s. The "Base" refers to baseband (single communications channel on each cable). Originally, the last character referred to the maximum cable distance in hundreds of meters. This naming convention changed, however, with the introduction of 10BaseT and 10BaseF. In these instances, the T and F refer to the cable types (twisted-pair and fiber-optic). "Link Integrity" and "Auto-partition" are part of the 10BaseT specification. This means that all network equipment claiming compliance with 10BaseT must support Link Integrity and Autopartitioning. Link Integrity is concerned with the condition of the cable between the network adapter and the hub. If the cable is broken, the hub will automatically disconnect that port. Auto-partitioning occurs when an Ethernet hub port experiences more than 31 collisions in a row. When this happens, the hub will turn off that port, essentially isolating the problem.

INTERNET ADDRESS
It's a 32 bits, 4-part period delimited, decimal number called IP number or IP address: www.xxx.yyy.zzz each part can vary from 1 to 254 (0 and 255 are reserved for the net and the broadcast) each network interface card attached to the Internet mast have an unique IP address the IP address can be splitted in two parts: network host

SUBNETS

Sub netting allow a network to be split into several parts for internal use but still act like a single one to the outside world.

DOMAIN NAMES
For convenience a domain name is normally assigned to each machine (for people remember names is easier than numbers) The name is assigned meaning with the most general part on the right (opposite to IP addresses): machine.subdomain.organization.country or in our case, for ex.: blueroom-1.ictp.trieste.it This allow the IP number to be changed while the user using the name sees no change To convert names into numbers you need the Domain Name System (DNS), a hierarchical domain-based naming scheme with a distributed database system

CONFIGURING THE TCP/IP STACK


The information you should need to configure the TCP/IP stack for your host are: IP address ( for ex. 140.105.17.2 ) Domain name ( in this case blueroom-1.ictp.trieste.it ) Broadcast address ( 140.105.19.255 ) Network mask ( also netmask, here 255.255.252.0 ) Default gateway ( here 140.105.17.1 ) DNS server(s) ( here 140.105.16.50 and 140.105.16.62 ) => take care to use always unique IP address and domain name for your host to avoid problems!

INTERNET ROUTING
A ROUTE is needed to send data to a remote host. It may require making many hops along the way. Routers (and gateways) perform these duties. To find routes each router must know about the topology of the subnet that connect it to the other routers and choose appropriate paths through it. This is achieved hierarchically with some complex algorithms generating routing tables for each router. Internet routing operates with packet (OSI Network layer). Each packet contains a destination address used by the router to decide which output line it should be sent on. Static routing don't care about network variables (load, changes in topology, temporary failures); routing tables are fixed. Dynamic routing changes routing tables to reflect the status of the net and achieve optimal performances. It's more complex to setup.

HOW A ROUTING TABLE LOOKS LIKE?


Each router has a routing table with many entries of two possible types: Net:

this entry tells how to get to a distant network identified by its network address in the form ( network, 0's ), i.e. sending the packets to another router (called gateway) through the specified Network Interface Card. the special network address "default" means all other destinations and points to a hierarchically higher router. In decimal form it's a 0.0.0.0 . host:

this entry tells how to get a local host ( = host on the router's LAN ) identified by its host address in the form (this network , host ), i.e. sending packets directly to it through the specified NIC.

AN EXAMPLE OF STATIC ROUTING


Version 1

ROUTING TABLES
Version 1

Those routing tables are simplified versions with only HOST-TO-HOST routes. This implementation is not suitable for pratical uses: it's not efficient at all, adding more hosts or subnets is difficult. Two hosts in the same group should pass through the group router to communicate. Two hosts in different groups should pass through the room main router to communicate. The solution routing to SUBNETS.

NETMASK
Knowing the class (A, B or C) of the network address, it's easy to split the network part and the host part of a given IP address: 44.134.177. 48 it's a class A network address 140.105. 28.160 it's a class B network address (but with subnetting!) 192. 41. 6. 20 it's a class C network address The standard way to specify it (with subnetting too) is using a further numeric field, called net mask the netmask (in binary format) is composed of as many 1s as the lenght (in bits) of the network (and subnet) part, followed of as many 0s as the lenght of the host part of the address:

the two example netmasks, expressed in a 4-part, period delimited, decimal form are 255.255.252.0 and 255.255.255.224

IT'S LOGIC !
The way to obtain the network part of a given address is:

to do a Boolean (i.e. logic) AND operation network = (IP address) AND (netmask)

let's try: IP address is 140.105. 17.226 ( = 10001100.01101001.00010001.11100010 ) netmask is 255.255.252.000 ( = 11111111.11111111.11111100.00000000 ) network address will be: 10001100.01101001.00010001.11100010 AND 11111111.11111111.11111100.00000000 = 10001100.01101001.00010000.00000000 in decimal 140. 105. 16. 0 this subnet goes from 140.105.16.0 to 140.105.19.255

AN EXAMPLE OF STATIC ROUTING


Version 2

Routing is performed by addressing subnets instead of hosts. Local net routes are common to every host in a given group and to every router.

ADDING ONE MORE SUBNET


Adding the new radio subnet requires a new entry in the routing tables of the "local" routers. No modifications are required at higher levels (i.e. "rest of the world"), due to the fact that the whole "class C like" subnet 140.105.38.0 (hosts from ...38.1 up to ...38.255) is routed to the Room Main Router. No modifications are required for the other hosts, locally and worldwide.

LET'S GO ALONG THE ROUTE !


Let us see the travelling packet route.

LET'S GO ALONG THE ROUTE:


Sending a packet from 140.105.38.226 to 140.105.38.34 We will follow the route of this packet through 5 steps: 1. This host is 140.105.38.226 and it should send out a packet of data with this information: destination address: 140.105.38.34 looking at the routing table the result is: send it to the gateway 140.105.38.225 through the interface ax0

CONTINUED.
2. This host is 140.105.38.225 - 140.105.38.68 and it should send out a packet of data with this information: destination address: 140.105.38.34 looking at the routing table the result is: send it to the gateway 140.105.38.65 through the interface eth1 3. This host is 140.105.38.65 - 140.105.38.2 and it should send out a packet of data with this information: destination address: 140.105.38.34 looking at the routing table the result is: send it to the gateway 140.105.38.1 through the interface eth2

CONTINUED.
4. This host is 140.105.38.1 - 140.105.38.33 and it should send out a packet of data with this information: destination address: 140.105.38.34 looking at the routing table the result is: send it to the host 140.105.38.34 through the interface eth1 5. This host is 140.105.38.34 and it received a packet of data with this information: destination address: 140.105.38.34 OK! This packet is for me.

THANK YOU FOR WATCHING

You might also like