You are on page 1of 35

The Fundamentals of Data Communication "Internet Technologies" Part 3

Lecturer: Martin Hsler E-Mail: Schedule: Winter Semester 2004/2005 University of Applied Sciences Solothurn Northwestern Switzerland

This manuscript is part of an introduction to network technologies. The content specializes primarily in the TCP/IP protocol family.

Modular Goals
To understand the fundamentals of data communication To know the basic terms of network technologies To be able to explain current network topologies To know the most important components of a network To understand the functional cycle of data transmission To be able to describe elementary network protocols

Einfhrung in die Informatik, 3. Auflage
Oldenbourg Verlag, H.-P. Gumm / M. Sommer ISBN: 3-486-24422-1

TCP/IP und ONC/NFS in Theorie und Praxis Unix in lokalen Netzen, 2. Auflage
Addison Wesley, Michael Santifaller ISBN: 3-89319-531-9

Technik der IP-Netze

HANSER-Verlag, Anatol Badach / Erwin Hoffmann ISBN: 3-446-21501-8

Grundlagen des Netzwerkbetriebes, 3. Auflage

Microsoft Press, Microsoft Corporation ISBN: 3-86063-279-5

EDV-Grundwissen Eine Einfhrung in Theorie und Praxis der modernen EDV, 4. Auflage
Addison Wesley, M. Precht, N. Meier, J. Kleinlein ISBN: 3-8273-1222-1

Internetworking with TCP/IP Volume 1; Principles, Protocols, and Architecture 2nd Edition
Prentice Hall International Editions, Douglas E. Comer ISBN: 0-13-474321

University of Applied Sciences Olten


1. THE FUNDAMENTALS OF DATA COMMUNICATION 1.1 Communication 1.2 Parallel and serial transmission 1.3 Simplex, Half-duplex and Full-duplex 1.5 Error Detection 1.6 Modulation Methods 1.7 Protocols 1.8 The OSI Model 1.9 The Organisation of the Networks 1.9.1 LAN (Local Area Network) 1.9.2 WAN (Wide Area Network) 1.9.3 MAN (Metropolitan Area Network) 1.9.4 GAN (Global Area Network) 1.10 Data Transmission in Public Networks 1.11 Network Topologies 1.11.1 Bus 1.11.2 Ring 1.11.3 Star 1.11.4 Access methods 2. ACTIVE NETWORK ELEMENTS 2.1 Repeater 2.2 Bridge 2.3 Router 2.4 Hub 2.5 Gateway 5 5 5 5 6 7 10 11 12 12 12 12 13 13 14 15 15 16 16 17 17 18 18 18 18

University of Applied Sciences Olten


3. THE ETHERNET 3.1 Transmitting Media 3.2 Ethernet Address 3.3 Ethernet-Frame 4. TRANSMITTING MEDIA 4.1 Coaxial cable 4.2 Twisted Pair 4.3 Fiber Optic Cable 4.4 Satellites / Directional Radios 5. SUMMARY TCP/IP 5.1 The Basics 5.2 Organization 5.3 The IP Address 5.4 Address Resolution Protocol ARP 5.5 Internet Protocol IP 5.6 User Datagram Protocol UDP 5.7 Transmission Control Protocol TCP 5.8 Internet Applications 5.9 Domain Name Service DNS

18 19 19 19 20 20 20 20 20 21 21 22 23 24 26 32 33 33 34

University of Applied Sciences Olten


1. The Fundamentals of Data Communication

1.1 Communication
Definition: Communication is the exchange of information. Every kind of communication can be reduced to this simple statement. For the exchange of information to be successful, two conditions must be fulfilled: Both partners must be connected in some physical way

It must be possible to transfer information, i.e. bits, by some method. This can be, for example, a network cable, a telephone line or a radio link. Both partners must have a common protocol.

There must be a set of laws that allows both partners to interpret the exchanged bits in the same way. Every type of communication must obey these rules so that each partner can understand the other. We are talking about the type of language used and the point in time, when communication is possible. Now, we want explain in detail certain fundamental rules of data communication.

1.2 Parallel and serial transmission

It is commonly known that computers use a binary representation of data. For reasons of speed, hardware components are, for example, connected to each other through a number a parallel transmitter lines. Depending on the time interval, either 8 bits (parallel port of a printer) or 32 bits (microprocessor chip) can be transmitted. For a larger distance, it is preferable to use less cable. The data is transmitted bit by bit successively (serial) over a wire. A typical example is the serial ports that were created for the exchange of data via modems over expensive external lines.

1.3 Simplex, Half-duplex and Full-duplex

The transmission line between data transmitting equipment can function in one of three ways: Simplex: Half-duplex. traffic in one direction Examples are radios and televisions Traffic in both directions, but only in one direction at a time, The transmission channel is used alternatively in both directions. Examples here include wireless intercom systems. However, the change in transmission direction can cause considerable loss of time. (In electronic data processing, this type is often called bi-directional.) Traffic in both directions at the same time Often called, simply, duplex. Here, data is transmitted over four-wire-leased-lines there are 2 wires for each direction. However, full-duplex is also possible with two-wire-lines.


Today, three modes are known with two-wire-full-duplex. For each transmission direction, a separate carrier frequency is used. The communication devices operate with high speed on lines in half-duplex mode and simulate fullduplex for the connected devices.

Both communication devices send and receive at the same time, whereby they suppress their own echo with a sophisticated circuit (echo compensation).

University of Applied Sciences Olten


1.4 Baud and Bit per second

In the following illustration, every 2-bit combination with four cycles in the carrier frequency will be presented. This results in a carrier frequency of 1200 Hz: 1200/4 = 300 signal elements per second = 300 Baud (rate of modulation) When 1 bit is transmitted per signal element, then the rate of modulation (baud) corresponds to the number of bits per second (Bit/s). In our example, 2 bits are transmitted per signal unit. This results in 300 Baud 600 Bits/s.

1.5 Error Detection

Echo: In a simple way, errors can be detected by returning and comparing each signal. Parity Check: In 7-bit-data codes, the eighth bit can be used to prevent error. The receiver controls the correctness of the eighth bit. This error detection is of little consequence for the PC world, since it is usual to work with 8-bit-codes. However, the following kinds can be distinguished: None: Odd: Even: Space: Mark: no parity check the eighth bit insures that the number of bits having the value 1 will be odd per 8 data bit: e.g. 00111000 the eighth bit insures that the number of bits having the value 1 will be even per 8 data bit: e.g. 00111001 the eighth bit is always 0 (not very effective) the eighth bit is always 1 (not very effective)

This byte-by-byte method of securing data is called Vertical Redundancy Check (VRC). If the block of data is supplemented with a byte, which contains a parity bit for every first bit and a further parity bit for every second to eighth bit, then one speaks of a Longitudinal Redundancy Check. With this method, a one-bit-error can be directly corrected.
University of Applied Sciences Olten 6 08.03.05

Cyclic Block Check: During the cyclic block check, the block information is taken from the data of a text block, whereby the whole text block is viewed as a binary number. This number is divided by another pre-assigned one and the remainder is the checksum. Typical representatives of the cyclic block check are BCS (Block Check Sequence), CRC (Cyclic Redundancy Checking), or FCS (Frame Check Sequence).

1.6 Modulation Methods

Usually, telephone lines are used for the transmission of data because they are readily available. The data that needs to be transmitted is normally stored digitally. However, not all telephone networks today are digital, some are still analogue. Due to this, the data must be converted. On the sender' side, the digital information of a carrier frequency will be modulated and on the receiver's side, it will be demodulated. The pertinent device is called a modem (Modulator and Demodulator). The main function of a modem is the conversion of digital data from a data terminal to the transmission characteristics of the lines. In addition, modems must interpret and trigger the control signals to the digital interfaces. Modern modems are equipped with local microprocessors and an internal memory. The functions are activated by a command language. The 'Hayes' commands are now considered standard. They are initialised with the letters 'AT'. The data is automatically compressed and, under certain circumstances, this can double efficiency. An error check assures that the data is correctly transmitted. Furthermore, the speed of transmission adapts itself dynamically to the quality of the line. Data that must travel great distances is transmitted by satellite from one country to another. Data send through the atmosphere to a satellite must be modulated. The following text will give some insight into the possibilities of modulation. Carrier frequency is determined by three characteristics: frequency, amplitude and phase There are three techniques of modulation that result from these characteristics (pitch, loudness and the moment of zero passage). The job of these techniques is to impose a carrier signal on a carrier frequency (carrier wave) so that the carrier signal can be clearly transmitted.

University of Applied Sciences Olten


Amplitude Modulation (AM)

The service signal is encoded in the amplitude. (e.g. loud = 1, quiet = 0).

Carrier frequency:

t U Digital signal: 0

0 t

Modulated signal:

Frequency Modulation (FM)

The drift from the carrier frequency results in the carrier signal. During the data transmission, the carrier signal has only two states resulting in two frequencies that lie symmetrically above and below the carrier frequency. The latter is then also called medium frequency. By V.21, the middle- or carrier frequency is 1080 Hz.

Carrier frequency: t

Digital signal: 0 1 0 1 1 0 t

Modulated signal:

University of Applied Sciences Olten


Phase Modulation (PM)

The carrier signal is encoded by a shift in the phase of the carrier: this means that the usual sinus curve of the signal path is interrupted and, after a while, it continues on again. Several bits are encoded into a state at the same time. (PSK Phase Shift Key = Phase Modulation).

Carrier frequency: t

Digital 0 1 0 1 1 0 t

Modulated signal

Quadrature amplitude modulation (QAM, AMP)

QAM is a combination of AM and PM, whereby one part of the status is encoded in AM and the remainder in PM. By V.22, there are four states (two bits) with AM and at the same time another four with PM. In all, 16 (4X4) states (4 bits) a Quad bit (square bit) can be transmitted at the same time.
11 10 01 01 00


10 11



University of Applied Sciences Olten


1.7 Protocols
Computer applications communicate through protocols. Protocols are rules that coordinate the exchange of information between partners and make it efficient. This is just like humans who use certain formulisms to simplify understanding. An example of a human protocol is the use of "roger" and "over" in wireless radio communication. Communicating partners acknowledge the change in communication direction by saying "over". When data is exchanged between data processing systems, similar, but more advanced demands take place. However, due to the complexity of the communication between data processing systems, it is often not useful to handle all of the necessary functions in just one single protocol. As a result, it is common that several data processing protocols are used simultaneously. These protocols are layered into stacks and the various functions are divided among the different protocols in the stack. They all cooperate with one another and together provide a service for the user. Some functions: Controlling the electrical signals during the communication Controlling the sequence, in which a computer communicates (see access method) Defining the language for communication Recognizing and correcting errors in communication Addressing the data that is to be communicated In addition to the addressing of the endpoint communication, the controlling of the data flow and many more things, one of the main functions of protocols is the provision of services to make data transfer reliable. Behavior Error recognition Error correction Address Flow control What happens (examples) checksum, sequence number, timer supervision acknowledgements packet repetition, correction procedure address data destination window, acknowledgements

In the above table, some more important protocol behaviors and how they happen are listed. Networks, computers and data lines are by no means immune to data corruption or system failure. A user of a network service expects correct data, and it does not matter if it is the end-user at a computer station or a protocol that is higher in the stack. Therefore, during the transfer of data, these problems must be first recognized and, when possible, solved.

University of Applied Sciences Olten



1.8 The OSI Model

The "International Standard Organisation" (ISO) has developed a seven-layered-model that is often used to describe the construction of network systems. This is due to the clear division of the functions into seven layers. In addition, it is an official standard that is open to future development and modification. The ISO has named this model the "Open System Interconnections" (OSI) a seven-layered reference model.
Layer Application 1 Application Layer Application 2 Application Layer User system

7 6 5 4 3 2 1

Presentation Layer Session Layer Transport Layer Network Layer Link Layer Physical Layer

Presentation Layer Session Layer Transport Layer Network Layer Link Layer Physical Layer

Transport system

The seven layers of the OSI Reference Model Usually, each protocol collection (e.g. TCP/IP) has its own architecture. Individual protocols, or rather their functions, are modelled into the various layers. The stacking is based on the principle that one layer (e.g. the network layer) can use the one below it (in this case the link layer) without knowing how the layer renders its service. The layer directly above it (here the transport layer) will offer its own defined service. In this way, a division of the work per layer is achieved. The OSI model divides the entire communication protocol (from the physical level to the application level) into a total of seven protocol layers. Applications, which communicate through the network, pass through all seven layers. As the protocol passes from the lowest layer to the highest one, it experiences an increasing abstraction. This means that the uppermost layer describes the communication protocol from the point of view of the user, while the lower layers increasingly refer to the technical aspects of the data transmission. The lowest layer deals solely with the physical transmission: it defines, for example, the signal level for the data transmission. Due to the particular importance of layers 1 4, we will look at them later in more detail.

University of Applied Sciences Olten



1.9 The Organisation of the Networks

We differentiate between local networks LAN (local area network) and long-range networks WAN (wide area network). Occasionally, we also talk about MAN (metropolitan area network), but here, one must remember that MAN is more a local network. The question arises, whether a given network can be viewed as a local network. Furthermore, the term GAN or global area network is also used.

1.9.1 LAN (Local Area Network)

Local networks are limited spatially only a few kilometres and they usually belong to a company. These LANs can transmit data at high speed. Characteristics: Limited distance between the systems (e.g. max. 1 km) No public lines are used A physical connection to all stations within LAN exists at all times. No modulation of the digital signals Either no norm or only the in-house norm Access control possible High speed of transmission (10 / 100 Mbits/s)

1.9.2 WAN (Wide Area Network)

The Wide Area Network connects data processors with servers within one or several countries. In contrast to a LAN, WAN uses public lines and facilities for data transfer. Its rate of transmission lies in the area of up to 2 Mbits/s. By using broadband networks, however, rates of up to 1 Gbit/s should be possible. Wide-area networks are always large networks, e.g. CompuServe, which offer worldwide service. WANs usually work slower than LANs and normally they belong to service providers, who sell their data services to end-users. LAN-Station LAN-Station



LAN: Twisted Pair Radio Light guide (Possible means of transportation)

Based on the OSI-Model, this structure illustrates the protocols in the nodes of a common data network. Important for the differentiation between the various types of local networks are only the two lower layers. Everything else above them either belongs in the station itself or in the nodes of the wide-area network. Both middle protocol towers, each with three layers, represent nodes in the wide-area network. They are pure communication nodes, which do the routing.

1.9.3 MAN (Metropolitan Area Network)

University of Applied Sciences Olten 12 08.03.05

A MAN is a special wide-area network, which is limited to an urban area or to the area of a company. Mainly, it differs from WANs only in the rates of transmission (approx. up to 100 Mbits/s).

1.9.4 GAN (Global Area Network)

The Global Area Network connects processors worldwide and is the logical pooling of all the abovementioned parts. It allows the forwarding of e-mails, data, language and pictures. The Internet or CompuServe is a typical representative of a GAN.

1.10 Data Transmission in Public Networks

The speed of analogue signal transmissions is measured in baud and indicates the number of signalling elements per second. A signal element (a bit of information) does not necessarily correspond to a data bit, so that 1 baud is not identical to 1 bps (bit per second), the usual unit of measurement for the speed of data transmission. With today's coding and compressing methods, it is possible to reach data transfer speeds of 56,000 bps. Besides analogue data transmission, telecommunication companies usually also offer the following digital services: Datex-L The Datex-L network is a so-called circuit-switched network, in which the sender and the receiver are permanently linked to each other. With this kind of transfer, rates of 64,000 bps are possible. With this type, the connection set-up is very quick. This network is normally used for short distances and is unsuitable for large amounts of data. A disadvantage lies in the high cost for the permanent line. As a result, this type of network is being replaced by Datex-P. Datex-P Datex-P is a packet switcher Datex network. With this connection, only a 'virtual' link is established between the sender and the receiver. The data that is to be sent is divided into separate packets and these packets, independent of each other, are then sent to the receiver. In addition, these packets can even arrive at the sender by various ways. The transport occurs by means of so-called remote front-end processors, which have a cache for the data. Telephone Networks (Pubic Switched Telephone Network) The largest WAN is the public telephone system. One talks about a switched telephone network. Through a chain of serially switched transmission lines, the calling party is directly connected to the called party. Circuit Switched Data Network In this system, just like a telephone network, lines are switched together. Data is transmitted digitally. The channel remains open for the duration of the transmission, even when no data is being transferred. The calling and the called station are directly linked to each other. Packet Switched Data Network In packet transmission, blocks of data are transferred from network node to network node. The data is then stored in each node's cache. Transmission is from segment to segment. Data packets belonging to one dialogue can find their way through the various nodes using different routes, depending on the utilization of a single segment. Transmission facilities such as lines and transmission circuits can be utilized to a much better advantage. It is a disadvantage, however, to use caches because that can cause delays. With packet transmission, one also differentiates between connection-oriented and connectionless service. Connection-oriented service consists of three phases:
University of Applied Sciences Olten 13 08.03.05

1. the establishment of a connection 2. the transmission of data 3. the ending of the connection A connectionless service, trusting on the reliability of the medium, just sends the packet - well aware of the fact that the occasional loss of a data packet can be put up with. The eventual error will be corrected in the higher layers. ISDN (Integrated Services Digital Network) Since that moment when we have been able to transmit the human voice digitally, it has become unnecessary to have separate networks for data and voice. As a result of this modern public communication network, all services can be simultaneously offered (integrated). ISDN makes this idea possible. Rates of transmission of at least 144 Kbits/s are possible (2 bearer channels with 64 Kbits/s and one control channel with 16 Kbits/s). 8 devices can be connected, whereby only two of them (computer and telephone) can be in use at the same time. Service charges are about twice as high as those of a normal telephone connection. DSL / ADSL The acronym DSL means digital subscriber line and needs two modems; one at the switching center and the other one at the client's. At the moment, today's technology allows transmission rates of up to 8Mbit per second over existing cables. In actuality, though, slower transfer rates are in use because there are then fewer reciprocal disturbances in the cable strands. There are ADSL and SDSL connections: the A stands for asymmetrical and the S for symmetrical. It is called asymmetrical because the speed of the data stream is higher to the ADSL user than it is to the sender. Downloads are, therefore, faster than uploads. With symmetrical connections, upstream is as fast as downstream. The normal Internet user usually requests more data from the Internet than they feed back to it. Therefore, an ADSL connection seems more logical. A company, on the other hand, might need to send large quantities of data into the network, for example, building or floor plans, digital pictures, etc. Here, a SDSL connection would be more advantageous. UMTS UMTS is well known because people had to bid millions for the adequate licenses. The new UMTS standard (Universal Mobile Telecommunication System) allows a transfer rate of up to 2 Mbit. This is 31 times the speed of the current ISDN devices in the conventional telephone network. Faster Internet connections, multimedia usage, stock market transactions, or online reservations all these things should have been made possible with this third generation mobile phone technology. However, in order to keep investments in the new network from getting out of hand, the maximum data rate was limited to 384 Kbits/s. UMTS is based upon the Wideband Code Division Multiplexing Access scheme (WCDMA), which differs greatly from the time division multiplex scheme, which has been in use up to now. With WCDMA, all the data within a radio cell are transferred over the same frequency and at the same time. The data are kept apart through codes, which have been agreed upon by the sender and the receiver. As with GPRS, the totality of the available radio cell spectrum is split dynamically (automatically adapted) among the clients; with UMTS, though, this is around four times higher. ATM The ATM network (Asynchronous Transfer Mode) is based on broadband technology. It could be the network of the future. The network is also based on the transfer of packets, (which are indeed smaller), and because of its possible transfer rate of up to 1 giga bps, it is far more capable than the other network types. At the moment, this network is being used in various research networks and has not yet won wide acceptance among commercial users. Because of its great performance potential, it could be used for LANs.

1.11 Network Topologies

University of Applied Sciences Olten 14 08.03.05

The topology of a network is the spatial arrangement of the stations and the transmission units. Two distinct topologies will be briefly described below, but it must be remembered that there are hybrids and combinations of the two.

1.11.1 Bus

A bus is the linear layout of the transmission medium with several port possibilities for stations. Because there is no central distribution center, error search can be difficult. To avoid reflections, both ends have to be fitted with end resistors.

Today, more and more systems are used which employ so-called hubs as buses rather than a physical cable. The construction of a bus looks more like a multiple star network, but it behaves like a bus network. This form of networking is also known as structured cabling.

Bus network with hubs Bus networks have become very important. We will look at one of its most important advocates, the Ethernet, later on.

1.11.2 Ring

In a ring, all the data is transmitted in one direction. Packets of data are read by any one of the stations on the loop and the data can be passed forward by any one of the 'listening' stations. If a transported packet is addressed to a particular station on the loop, then the message is regenerated and passed forward. And finally, once the loop has been completed, the packet will be absorbed once again by the sender. Each station on the ring can be in one of three states. a) listening b) sending c) by pass

University of Applied Sciences Olten



1.11.3 Star

With the classic star topology, all the computers are connected to a central hub. One disadvantage is the amount of cables that are necessary for the set up. This has caused people to switch to the bus and ring topology. Today, though, the star topology is again very popular. The expense caused by the amount of cable is set off by other advantages. For example, the hub can contain errors better. In addition, if there are problems with a computer or if there is a cable disruption, the other stations are not necessarily affected. And finally, the connected computers do not have to share the connection with other users, thus leading to faster rates of transmission.

There are two types of communication: 1. controlled access through polling or reservation. Polling: Each station that desires communication with another one has to first receive permission either to permit data transmission or to establish a firm connection. People differentiate between 'roll call polling' and 'hub polling'. With roll call polling, the hub of a given loop will call each station in succession to ask if communication is desired. If the distance is long, then this can take a long time. 'Hub polling' can help the situation. Here, the station next in line simply gives permission to transmit to the next following station, once its own communication is ended. 2. competition: A station that is ready to transmit a packet of data, sends this packet when there is no other traffic. Due to the finite speeds, this can, however, lead to collisions. There are combinations of the star and ring topologies. So-called 'wiring concentrators' are placed on a ring, to which groups of stations are radially connected. There are several reasons for this. First, the number of stations should not be too large because of the synchronisation of the whole ring. (A concentrator counts as one station.) Second, due to geographic or to cabling reasons, it is often advisable to install concentrators.

1.11.4 Access methods

In a round of discussion, if all the participants start to talk at the same time, no one will be able to understand the other because of the jumble of words. A similar situation can happen to computers in a network. If they start to send data at the same time, this will invariably leads to collisions individual packets of data will overwrite themselves. This means that some data will not be transmitted as desired to a receiver. Therefore, rules are needed to control communication on a network (In the case of the round of discussion, this could be a list organizing the speakers.) In the area of network technology, there are two methods of preference: CSMA-CD (Carrier Sense Multiple Assess Collision Detector) Token Ring CSMA-CD CSMA-CD stands for Carrier Sense multiple Access with Collision Detection and the name essentially describes the principle of the method: All devices have shared access to the medium All data transmitters listen in to the medium and try to detect if another station is sending a signal. There is a chance of collision when several stations send at the same time. If a collision happens and transmission will be stopped. (Collision detection)

University of Applied Sciences Olten



Two data stations sending data simultaneously can cause data collision. As soon as a collision is detected, transmission is stopped. Both devices wait for a short period of time before they try to re-transmit. The waiting time for both stations is random and it also depends on the failed transmission attempt. This procedure is to prevent the signal from being re-sent at the same time. The procedure can be describes as follows: a group of people are sitting in a dark room. They are all talking with one another. The information is no longer being sent by electronic signals but by sound waves. Each person can understand the other, but only if one person is speaking (carrier sense). Each person can rise to speak (multiple access) and each person is invited to make only a short statement. If someone breaks this rule, he or she is excluded from the group. No one interrupts the other. If two people rise to speak at the same time, they will notice this since they will hear something that they themselves are not saying (collision detection). As soon as the speakers become aware of this problem, they will both stop talking, whereby the length of the pause will vary randomly. The second speaker will wait until the first speaker is finished, before making his/her remarks. This procedure assures that all the devices can communicate over a common medium, only one single device can transmit, the other devices are still able to receive at the same time. Token Ring The token-ring method is an enabling method, which allows only that computer to send, which has received permission to do so. This principle is analogue to a round of discussion, in which a person can speak only when he/ she has received permission from the chairperson. In a token-ring, a special bit pattern (authorization token) assumes the role of the chairperson. This marker travels around the token-ring network. As the token circulates, a computer that wants to speak can capture the token (plants a flag), attaches its message and the receiver's address to it and lets it circulate to its destination. The flag lets the other computers know that a message is underway and now they control the destination address to see if the attached message is for them. The target station can now receive the data and places a 'have read' flag in the authorization token. When the token returns to the sender, it recognizes that the message has been read and then releases the token back into the network. The token-ring method is used only in ring networks.

2. Active Network Elements

In a network, there are several components whose purpose is to build a network out of numerous stations over sometimes great distances or to link various nets with each other. Furthermore, the cable length in a network cannot always be arbitrarily chosen, it is often limited by technical problems. For example, an Ethernet segment can have a cable length of maximum 500 meters, depending on the medium. This is because the transmission time for a data packet, from one end of the line to the other, has to remain under a certain threshold value to ensure the optimal detection of collisions. As a result, a network has to be divided into smaller units, which can be linked to one another with the following active devices. In the case of Ethernet, such units are called segments.

2.1 Repeater
A repeater is purely a signal amplifier, which works on the first layer of the OSI model. This means, a repeater forwards the data exactly as the sender sent it, it does not change the data in any way. A repeater simply strengthens the input signal, thus enabling it to be sent over greater distances. Repeaters, however, can only be used with networks of similar type. For example, several Ethernet segments can be linked together, in order to build a larger network. Collision detection of is done separately in each Ethernet segment.

University of Applied Sciences Olten



2.2 Bridge
Bridges work on the second layer of the OSI model. They are also used to link to Ethernet segments together, but they have, in contrast to repeaters, a much larger function range. Whereas a repeater only strengthens simple signals, bridges are responsible for the forwarding of whole packets of data (frames). They also increase data security and the capacity of a network. In each case, a bridge reads the Ethernet sender's and receiver's address (MAC address). It recognizes whether the packet should be transmitted over another segment, thus greatly reducing communication within a network. On the other hand, data can be simultaneously transmitted within a segment so that a considerable improvement in capacity can be achieved with skilful network segmentation. A bridge can be its own computer without a keyboard and screen or it can be a special program on a normal computer. Whereas the aforementioned linking elements serve only as connectors for networks with the same topology, the elements discussed below are used to connect differing networks.

2.3 Router
Routers work on the third layer of the OSI model. Routers link networks with differing topologies, e.g. an Ethernet can be linked with a token-ring network. The networks that are to be connected need to be based only on the same transport layer (e.g. TCP/IP or DECNet). Routers are, therefore, used for the construction of wide area networks (WANs). A special function of a router is its ability to determine the shortest path between two computers. To do this, a router maintains a 'routing table', which stores the necessary information and actualises it continuously. Since routers play such a central role in the connecting of networks on the Internet, we will talk about them again later.

2.4 Hub
We were introduced to hubs in an earlier chapter as they are used in the construction of bus networks. Their main function is to switch interfaces, i.e. a cable always goes out from the hub to each computer. The hub can be used as the connecting point for either other network components or other networks. Hubs can function like a repeater or can be equipped to act like a bridge. Hubs can have 4, 8, 16, or 24 ports. All the information from the attached devices passes through the hub, thus substantially facilitating network management.

2.5 Gateway
Gateways work solely on the application level of the OSI model, implementing all seven layers of the OSI model. This allows networks with different protocols and topologies to interconnect. In telecommunication, gateways are used as the transmission units for certain services. With its range of function, gateways can be compared to routers, but in addition, they must do various protocol conversions and they must insure that the correct protocols are used. Typically, a gateway is the entrance to a postal service LAN (x25 gateways) or the interface for the exchange of e-mails between computers with different networks

3. The Ethernet
The Ethernet today is the most widespread local network. It was developed in the 70s by Xerox PARC and together with Intel Corp. and Digital Equipment Corp. standardized. The Ethernet is a bus-oriented network because all its stations are connected to a common medium. It uses the CSMA-CD access method. It is a so-called broadcast system since all stations can receive a transmitted message. Each Ethernet connection is essentially made up of two components. The transceiver (transmitter-receiver) connects the station to the bus cable. The transceiver contains the transmitter and receiver logics and the collision detection. Ultimately, the host interface connects the transceiver with the computer, that is, it implements the communication between the two and contains for example the logic whether a packet is meant for the station.
University of Applied Sciences Olten 18 08.03.05

In today's computers, the Ethernet port is pre-installed or is available as an additional Ethernet card.

3.1 Transmitting Media

Today, various media are used to transmit data using the Ethernet. They differ partly in the speed of transmission, in the maximum cable length and in cost. ThickWire The yellow ThickWire is the original Ethernet cable. It is a thick coaxial cable with the standard type-name 10Base5. An Ethernet segment built with ThickWire has a maximum length of 500 meters and can be connected to up to 100 transceivers. The advantage of ThickWire is that a new station can be added while the system is still running. This is possible because it is not necessary to break the circuit; it is only necessary to tap into it. Cheapernet (ThinWire) CheaperNet is a thinner and cheaper coaxial cable when compared to ThickWire. Its maximum length is 185 meters and only 30 devices can be attached to it. It is especially good for the building of smaller networks. The main advantage of ThinWire is its reduced cost. With ThinWire, all the stations are connected to the transceiver with a Tee connector. The other two Tee-connector-ends are attached to neighbouring stations. All stations are thus plugged into a single strand. And here is the major disadvantage: even if only one plug-in connection fails, the whole network crashes. TwistedPair TwistedPair (10BaseT) cable is growing more and more popular. It consists of two copper wires that are twisted together. Each station is connected to a hub with its own line (point to point connection). The big advantage of such a structure is that an error in one station or line will not disturb the rest of the network. Changing the cables around becomes an easy process. The line can have a maximum distance of 100 meters. A disadvantage is the somewhat higher costs when compared to CheaperNet.

3.2 Ethernet Address

Each Ethernet card has a globally unique Ethernet address that is 6 bytes large. Each manufacturer of network interface cards has to register with a central organization (IEEE) for its own series of numbers. Example: The network interface cards from the SUN Company always start with the numbers 08-00-20. The SUN server of our school has the Ethernet address 08-00-20-88-9a-87. The Ethernet address can do more than identify or address one single network card. The address FF-FF-FFFF-FF-FF (in hexadecimal) is thus reserved and has the same meaning as a broadcast address. Broadcast here means that a message is addressed to all the cards within the physical network. These cards must also send an answer. A multicast address allows the simultaneous addressing of several stations on a network.

3.3 Ethernet-Frame
Data packets (frames) that are sent in the Ethernet have various lengths, but are at least 64 bytes long. An Ethernet Frame has essentially the following components: the Ethernet address of the destination the Ethernet address of the source a type field and the data The following illustration shows the complete structure of an Ethernet frame Preamble
64 bits

48 bits

48 bits

16 bits 304

-12000 bits


32 bits

The preamble synchronizes the network nodes and the CRC field (Checksum) at the end of the frame identifies transmission errors. The type field specifies the kind of data that are transmitted. In a way, the
University of Applied Sciences Olten 19 08.03.05

type field allows the self-identification of the frame. Thus, the system can recognize which communication protocol the frame should process.

4. Transmitting Media
The transmission media are the actual ways in which signals are transmitted that carry the information to be communicated, i.e., the cable and the kind of signal transmission on it. When transmitting electrical signals, we basically differentiate between closed or open transmission. Open transmission is found in systems which radiate information to the receiver by using electromagnetic waves via space. Essentially, three types of closed transmission can be found today: 1. twisted pair (2 copper wires that are twisted together, sheathed or unsheathed) 2. coaxial cable (in many varieties) 3. optical fibers (optical characteristics: multimode, monomode)

4.1 Coaxial cable

Until recently, coaxial cable or also coax cable was the most frequently used cable type. It consists of a central conducting wire, a layer of insulation, an outer conductor (usually a grounded shield of braided wire) and a final outer plastic sheath. In addition, there are also coaxial cables with several central conducting wires. For the diverse LANs, there are specified types of coaxial cables. Cable types:
Cable type: RG-8 RG-11 RG-58 RG-59 RG-62 Designation Thick Ethernet cable Thick Ethernet cable Thin Ethernet cable Cable TV Arcnet Resistance: 50 Ohm 50 Ohm 50 Ohm 75 Ohm 93 Ohm

Characteristically, conductors can show constant resistance, independent of the conductor length. This resistance corresponds to the alternating current resistance of the line for high frequencies. It is determined by the material and the dimensioning of the cable. The end resistance of bus conductors has to be the same as the resistance of the cable. It hinders reflexions by simulating a further conductor.

4.2 Twisted Pair

Twisted pair cabling is made up of pairs of conductors that are twisted together. The twisting insures that the transmitted signals are protected from electrical and magnetic interference. These cables come shielded (STP: Shielded Twisted Pair) or unshielded (UTP: Unshielded Twisted Pair). In addition, the shield reduces external interference. Depending on the quality, twisted pair cables can be used for speed up to 100 Mbits/s. The twisted pair cables used in LANs usually have 4 twisted conductor pairs. A so-called RJ45 jack with 8 'pins' or electrical connectors is used as an interface.

4.3 Fiber Optic Cable

Fiber optic cable, also called light-wave cable, is made up of very thin glass fibers (about the width of a strand of hair) that are surrounded by a sheath of plastic. Fiber optic cable is very expensive and the establishing of a connection is not easy. Advantages: Fiber optic cables are tap-proof, they are protected from interference, they are suitable for long distances and have a high rate of transmission.

4.4 Satellites / Directional Radios

Satellites are being used more and more to transmit data between continents. The transmission medium is
University of Applied Sciences Olten 20 08.03.05

microwaves, which allow a transmission capacity of up to several Gigabits/s. Microwaves are also used to transmit data over large distances within a country. With directional radio, the transmitter sends a directed beacon to a reception facility.

5. Summary TCP/IP
5.1 The Basics
Normally, the term TCP/IP comprises everything that is somehow connected with a TCP or IP protocol, so for example, other protocols (UDP, ARP, ) diverse applications (telnet, ftp, ect.) or even network media (Ethernet, ) The term, Internet Technology, describes this technique more exactly. A network that uses this technique is called the Internet. Essentially, TCP/IP spans the layers 1 through 5 of the OSI-Model. However, the following four-layered model has established itself as the description of this protocol. It is based on a design of the American Defence Department.
Application Layer Transport Layer Internet Layer Network Access Layer Network applications TCP UDP IP ARP Ethernet
Ethernet address IP address


The main function of the network access layer is the transfer of an IP-datagram to other devices through a directly connected network. This layer defines how an IP-datagram is to be transported over the network. The protocols of this layer have to know the exact construction of the network underneath it. The Internet layer defines the IP-Datagram. It assumes the routing of the datagrams to other computers and is responsible for their fragmentation and defragmentation. The transport layer represents the computer-to-computer connection, which means, it is the connector between the application layer and the Internet Layer, which lies below it. Here, the user can access several protocols, with which data can be transferred. Ultimately, the individual protocols represent modules, which process the data that is being transferred through them. The Ethernet cable is then connected to the computer with a transceiver. In the diagram, one can see, for example, that the Internet layer has only one protocol (IP Protocol), but the transport layer has two protocols available.(TCP and UDP).

University of Applied Sciences Olten



The Data Framing: If a user sends a data packet from the application layer, then the data are not just simply sent unchanged to the layer underneath. Each layer adds control and address fields to the existing packet. However, upon reception of the data in the reverse direction, each layer will again remove its control fields before forwarding it to the next higher layer. This process is called data framing or data de-framing. Terms The following table contains a summary of the terms for the data, which has various names depending on the processing stage within the individual protocols. Name Ethernet Frame IP Datagram Description The data lies on the cable as a packet. IP = Internet Protocol The data has been framed by the IP and lies between the IP and the Ethernet Modules. UDP = User Datagram Protocol The data has been framed by the UDP and lies between the UDP and IP Modules. TCP = Transmission Control Protocol The data has been framed by the TCP and lies between the TCP and IP Modules. The data is lying as a data stream in the network applications.

UDP Datagram

TCP Segment

Applications data

If we follow the data flow down from the application layer through to the lower layers, we can see that the data either passes through the TCP module (Transmission Control Protocol) or through the UDP module (User Datagram Protocol). This means there are applications on the applications layer that use either the TCP protocol or the UDP protocol. SNMP (Simple Network Management Protocol) is an example for a UDP application, whereas FTP (File Transfer Protocol) uses the TCP protocol.

5.2 Organization
The IAB (Internet Activities Board) is the highest body that coordinates the development of the TCP/IP protocol family and organizes the expansion of the Internet. The IRTF (Internet Research Task Force) and the IETF (Internet Engineering Task Force) are subordinate to the IAB. The much smaller IRTF deals with basic research activities and the IETF endeavours to solve short and medium term problems. The IETF is divided into 8 sub organisations, which are coordinated by a common body, the IESG (Internet Engineering Steering Group). The goals of the individual task groups are determined in regularly occurring meetings and are then published on the Internet.

University of Applied Sciences Olten



Internet Institutes:

Sub org 1

Sub org 2 Sub org 3


The ICANN (Internet Corporation for Assigned Names and Numbers) is probably the absolutely most important authority of the Internet. It is a non-profit organization. It is responsible for the administration of IP addresses and domain names. (Formerly, the IANA (Internet Assigned Numbers Authority) had this responsibility alone). The ICANN is at the apex of a hierarchy. Both IP controllers RIPE (Resaux IP Europene) and APNIC (Asian-Pacific Network Information Center) are subordinate to it. Internet Administration:











SWITCH manages NIC.CH. SWITCH is also the place of registration for the top level domain names "ch" and "li". A registered domain name must have at least 3 and at most 24 letters or numbers. The only special character that is permitted is the hyphen (-) that cannot be at the beginning nor at the end of a name.

5.3 The IP Address

Before we look at the protocol of the individual layers, we will examine Internet addresses. A computer on the Internet has to have a unique address (IP address). An IP address is made up of 4 bytes, and like an Ethernet address, it can exist only once globally as long as the computer is connected to the Internet. Addresses are allocated by central organizations in each country. The IANA (Internet Assigned Numbers Authority) in the USA has the worldwide responsibility. Addresses are not assigned to single computers, but whole address blocks are allocated to individual organizations, for example, the UAS Solothurn (University of Applied Sciences). The University applies for an IP netblock at a central registry. The school then allocates this block of addresses as it wishes. The school bears the full responsibility for this block. A
University of Applied Sciences Olten 23 08.03.05

school computer that is connected to the Internet has, for example, the following IP address: The IP address is made up of a network and a host part. Internet addresses are divided into 3 network types, called class A, B, and C. The class is recognizable by the position of the first 0 in the bit pattern of the address. For each class, a certain number of bits are reserved for the identification of the networks in that class. The remaining bits identify the individual hosts in the net. The following table shows the starting bits for each net class and the number of reserved bits for the identification of the networks and the individual hosts in this class. This table also shows the resulting address block and the numbers of networks and hosts in the respective network class.

Network class
Class A Class B Class C

Start Bits 0 10 110

Bits Bits (Network) (Host) 7 14 21 24 16 8

IP block -

Number of Number of addresses networks per network 128 16384 approx. 16 mil approx. 65000 255 - - approx. 2 Mio.

The above table shows the address blocks that are theoretically possible. The IANA (Internet Assigned Numbers Authority) has reserved 3 areas for private Internets. (RFC-1918). If a private net needs to be configured, then these suggestions should be followed without fail. The subnet mask defines the number of bits of the IP address that belong to the netblock. In the UAS, the subnet mask is used, i.e., the first 3 bytes determine the network portion and the remaining bytes are allocated to the host. This also means that this IP area can maintain 2^8 = 256 addresses and represents a C Network Class. 11000001 11111111 11000001 00000000 10000111 11111111 10000111 00000000 11110001 11111111 11110001 00000000 10111000 00000000 00000000 10111000 IP Address Subnetmask Network part Host part

Perspectives Due to the enormous expansion of the Internet over the last years and in spite of the seemingly large number of possible IP addresses, a shortage of address is foreseeable in the near future. This is why; efforts are being made to define new IP address structures. A new version uses a 128-bit address and this should suffice for the time being. At the same time, however, a new IP protocol is also being defined, known under the name of IPV6. It will also be retroactively compatible with existing protocols.

5.4 Address Resolution Protocol ARP

ARP is a very important part of the network access layer. When an IP datagram is passed on to an Ethernet browser, it is then transmitted through the network to the destination. But how is the Ethernet address of the receiver obtained? The ARP protocol is used for this purpose. ARP assumes the conversion of an IP address into an Ethernet address. This conversion can only be done when sending because it is only during this process that an Ethernet header has to be generated with the appropriate destination address. ARP Table A table helps with the conversion. This table, called the ARP table, is kept in memory and has an entry for

Addresses higher than 223 are reserved. They are not for public use. 24 08.03.05

University of Applied Sciences Olten

each computer on the local network. Basically, the ARP table has a column of IP addresses and a column of corresponding Ethernet addresses. If an Ethernet address has to be resolved, then the table will be searched for this address. If the address is there, the corresponding Ethernet address will be selected. It should be remembered, a host must maintain its own ARP table for each network card. ARP Table: IP Address Ethernet Address 08-00-39-00-2F-C3 08-00-5A-21-A7-22 08-00-10-99-AC-54

The ARP table is insofar necessary because Ethernet addresses and IP addresses are neither allocated at the same time nor from the same body. No algorithm is useful to calculate the corresponding Ethernet address from an IP address. The organization's network administrator allocates the IP address, whereas the producer of network cards allocates Ethernet addresses. If a host is moved to another place on the Internet, then the IP address must also be changed, but not the Ethernet address. This address, however, is changed, if the network card has to be replaced. ARP Request When an IP datagram is generated and broadcast to the Ethernet driver, then the Ethernet driver calls upon the ARP module. The module looks through its ARP table and selects the receiver's Ethernet address that corresponds to the IP address. If, however, the desired Ethernet address is missing, then an ARP request must be sent. The pertinent IP diagram is queued. An Ethernet broadcast (Address FF-FF-FF-FF-FF-FF) is started that is directed to all hosts on the local network. This is why every computer receives this request. The Ethernet driver examines the type of request and, based on the value of the ARP packet, recognizes that it must forward the request to the ARP module. An ARP request looks like this: "If your IP address corresponds to the IP address of the receiver, then let me know your Ethernet address." Addresses IP address Ethernet address Sender 08-00-39-00-2F-C3 Receiver ?

Example of an ARP request The ARP Module controls these IP addresses and if there is a match, the requesting computer is answered directly since the Ethernet address in already known. The answer can be: " Yes, this IP address belongs to me. I will tell you my Ethernet address." Addresses IP address Ethernet address Sender 08-00-39-00-2F-C3 Example of an ARP reply The answer is sent back to the sender. The Ethernet driver recognizes the information as an ARP packet and sends it farther to the ARP module. The ARP module can now complete its table. Receiver 08-00-28-00-38-A9

University of Applied Sciences Olten



IP addresses

Ethernet addresses 08-00-39-00-2F-C3 08-00-5A-21-A7-22 08-00-10-99-AC-54 08-00-28-00-38-A9

The ARP table after the ARP request This update takes only a few milliseconds. The IP datagram that is being queued can now be retrieved. The missing information is added and forwarded to the Ethernet driver.

If the destination computer does not exist, then, there is neither an entry in the ARP table nor does the request lead to a result. The IP module throws out the affected IP datagram. Thus, it cannot be ascertained in the higher layers if the connection is interrupted or if the computer with the questionable IP address even exists.

5.5 Internet Protocol IP

The IP datagram is made up of the following fields: The address of the destination The address of the source Protocol number, e.g. TCP or UDP Checksum of the IP header Data area The IP module plays a central role in the TCP/IP stack. Since this module maintains chiefly the routing table, it is one of the most important components. The routing table is used for routing tasks. For reasons of performance, this module is kept in memory, just like the ARP tables. The network administrator must maintain these tables. All communication can be blocked if there are errors in these tables. If the function of the routing tables has been understood, then the basis for a successful system and network administration has been achieved. Direct Routing If a source computer sends a data packet to a receiver on the same local network, then the end IP address and the end Ethernet address are known. Thus, a packet can be sent directly to the destination. This is called direct routing. (Actually, there is no routing, i.e. no switching, because the packet can be sent directly.) Below you see a simple IP network with 3 computers: pilatus, rigi and titlis. Each computer has the same TCP/IP stack, its own IP and its own Ethernet address.
pilatus rigi titlis

IP Network "Engineering"
If pilatus sends an IP datagram to rigi, then the IP header contains the IP address of pilatus as the sender IP address and the Ethernet header contains die Ethernet address of pilatus as the sender Ethernet address. In
University of Applied Sciences Olten 26 08.03.05

addition, the IP header recognizes the IP address of the receiver rigi and the Ethernet header recognizes the Ethernet address of the receiver rigi. Addresses IP Header Ethernet Header Sender Pilatus Pilatus Addresses in an Ethernet frame In this simplified case, the IP is redundant because the IP datagram does not contain any further information which is not already in the Ethernet frame. The IP will make unnecessary resource demands because it will first generate a header, then transfer a larger packet and finally, on the other side, unpack the header and analyse it. Once the IP datagram arrives at rigi, the IP module will see if the receiver's address is identical to its own. If it is, then, the data will be transferred into the upper layers. Indirect Routing If the sender wants to send a packet to a computer on another network, then, the IP address of the destination computer will be known to him, but not the Ethernet address. Because of this, the data packet will now be switched over a local computer, the IP router, to the destination computer (or further routers). This process is called indirect routing. The following illustration shows a complex IP network. It is made up of 3 subnets, development, administration and production. Each computer, except asterix, has a TCP/IP protocol stack consisting of an IP address and an Ethernet address. The computer asterix has the function of the IP router. It is equipped with 3 network cards, each of which has an IP address and an Ethernet address. Asterix has 3 Ethernet drivers, 3 ARP modules but only one IP module.
pilatus rigi titlis

Receiver Rigi Rigi

IP Network development





IP Network administration IP Network production




An Internet made of 3 IP Networks The network administrator has allocated to each IP network its own IP address and a name. If computer pilatus has a message for computer titlis, then "direct routing" will use direct routing.
University of Applied Sciences Olten 27 08.03.05

But what happens if computer pilatus wants to communicate with a computer that is outside of its subnet and "direct routing" can no longer be used? Pilatus must now call upon the services of asterix, which can forward IP datagrams from one subnet to another. This technique is called "indirect routing". If pilatus wants to send an IP datagram to lucerne, then pilatus will attach the IP sender address and the Ethernet sender address. Lucerne's IP address will be used as the destination, but the router asterix will be used as the destination's Ethernet address. Addresses IP Header Ethernet Header Sender pilatus pilatus Receiver lucerne asterix

Addresses in an Ethernet frame from pilatus to lucerne (before asterix) The IP module asterix receives this IP datagram and after comparing IP addresses, it recognizes that this packet is not addressed to it: "This is not my IP address," and forwards the IP datagram to lucerne, regenerating the Ethernet frame during this process. Addresses IP Header Ethernet Header Sender pilatus asterix Receiver lucerne lucerne

Addresses in an Ethernet frame from pilatus to lucerne (after asterix) Both of these examples illustrate the actual routing procedure, but not how it really works. The next subchapter will explain the rules of routing or rather, the routing algorithms. IP Module: Routing Rules The rules that an IP module must observe before it can forward an IP datagram or consult the ARP tables are as follows: 1. When the IP module receives an IP datagram from the transport layer, it has to decide whether the packet is to be sent directly or indirectly. In addition, a network interface has to be chosen. These decisions are made after the routing tables have been consulted. 2. When the IP module receives an IP datagram from the network access layer, it must then decide whether the packet should be forwarded on the transport layer or on a network interface. When it is being forwarded, the packet is re-marked as "to be sent". 3. The IP module receives an IP datagram from a certain interface. When a packet is forwarded, it can never be forwarded over the same network interface again. DNS Names Each interface with an IP address can be matched to a computer name, e.g., the computer with the IP address has the name pilatus. Names are given because they are easier to remember than numerical addresses and names are easier to type mistake-free. For small networks, the host name-to-IP address mapping is stored in a hosts file that every computer has. Due to the administrative expense, larger organizations usually set up a service to maintain these allocations. This service is called the Domain Name Service (DNS). Below, you can see an excerpt from a hosts file: pilatus rigi titlis asterix geneva lucerne Excerpt from a hosts file
University of Applied Sciences Olten 28 08.03.05

The IP address is always in the first column, followed by the computer names in the second column. Please note that in this case, the IP router asterix has only been allocated one IP address. However, asterix is reachable over all three IP addresses and it will also correctly process the IP datagrams that are addressed to it that have the address IP networks are also allocated a name. The networks file maintains the allocation of IP addresses to host names. 192.168.10 192.168.20 192.168.30 development administration production Excerpt from a networks file From these examples, it can be seen that computer pilatus belongs to the network development and the computer lucerne belongs to the network administration. The above hosts file is not necessarily of much use to the network administrator. To the line with the asterix entry, he/she will probably add the following: developrouter adminrouter prodrouter asterix

Addition to a hosts file with router entries The three new lines give each network interface a significant name, whereby there are 2 entries in the first line: the entry for a router and the entry for the computer itself. In practice, the IP router is normally called up by using the name asterix; only if a dedicated interface needs to be called upon, e.g. the network administration, will the appropriate router host name be chosen. These files are not essential for the correct functioning of a network, but working with names and not addresses greatly facilitates the network administration. IP Routing Tables The IP router asterix has 3 network cards. How can its IP module recognize to which interface it must forward a datagram? To solve this problem, the IP module will consult the IP routing table and from the entries, choose the appropriate interface. For each path (= route) in the routing table, there is an entry. These are: The IP network number of the destination computer The IP address of the router The direct / indirect flag The number of the interface The table is consulted before each sending. The routing table can be administered by using the route command. Direct IP Routing In order to exemplify this process, computer entries are supplemented with an interface number.
pilatus : 1 rigi : 1 titlis : 1

IP Network "development" with interface numbers

University of Applied Sciences Olten



The routing table of pilatus could look like this: Network destination Router development < > Direct/Indirect flag direct Interface number 1

Basic Routing Table with DNS names This information can be gotten by using the command netstat -r. In this simple example, all the computers have the same routing table. The table can also be shown with IP addresses: netstat rn Network destination Router 192.168.10 < > Direct/Indirect flag direct Interface number 1

Basic Routing Table with IP addresses The computer pilatus now wants to send an IP datagram to the computer rigi. The data is already in the IP module from pilatus. The destination is rigi or The IP module trims the network part from the IP address by overlaying the IP address with the subnet mask. In the example, the subnet mask is, the IP network 192.168.10 will be reached. With this address, the routing table will be consulted and a match found in the first entry. The additional information found in this entry shows that the computer is addressable on subnet 192.168.10 directly over interface 1. Now, using the IP address and the ARP table, the Ethernet address will be sought. Finally, this address with the IP datagram will be delivered to the Ethernet module of interface 1. If an application wants to send data to an IP address outside of the network development with this routing table, then the IP module will not find an entry in the table. It will then delete the IP datagram and trigger the error "network not reachable". The next subchapter will show how such a process can still be managed. Indirect IP Routing Analogue to the above example, the more complicated example for the illustration of indirect IP routing will be amended.
pilatus : 1

IP Network development

lucerne : 2

asterix : 1 : 2 : 3

IP Network administration IP Network production

oak : 3

IP Networks amended with Interface Numbers

University of Applied Sciences Olten



In this example, pilatus' routing table looks like this: Network destination Router development administration production < > asterix asterix Direct/Indirect flag direct indirect indirect Routing Table of pilatus and now with IP addresses: Network destination Router 192.168.10 192.168.20 192.169.30 < > Direct/Indirect flag direct indirect indirect Interface number 1 1 1 Interface number 1 1 1

Routing Table of pilatus only with IP Addresses

Asterix is the IP router for pilatus and the IP address corresponds to the interface that is connected to the network development. The computer pilatus wants to send an IP datagram to the computer lucerne. The data is in the IP module from pilatus and the destination is lucerne or The IO module trims the network part from

the IP address by laying the subnet mask over the IP address. In the example, the subnet mask is, the result is the IP network address 192.168.20. With this address, the routing table is consulted and a match is found in the second entry. The additional information in this entry shows that the destination computer lucerne, which has the IP address, is in the network administration and is reachable through the IP router asterix. Now, using the IP address and the ARP table, the Ethernet address from asterix is sought out. This is now, together with the IP datagram, forwarded to the Ethernet module of interface 1. It should be noted that the destination IP address is still lucerne. By way of interface 1 on the IP router asterix, the IP datagram now arrives and will be transmitted up to the IP module. The destination address is now controlled and it is realized that the IP datagram is not meant for asterix. Because of this, the IP datagram must be forwarded further. The IP module re-trims the network part out of the IP address. The IP module obtains the IP network address 192.168.20 as the result. Using this address, the routing table is consulted. The routing table of asterix can look this: Network destination Router development administration production < < < > > > direct/indirect flag direct direct direct Interface number 1 2 3

IP Routing Table of asterix with DNS Names And only with IP addresses: Network destination Router 192.168.10 192.168.20 192.169.30 < < < > > > direct/indirect flag direct direct direct Interface number 1 2 3

IP Routing Table of asterix with IP Addresses

University of Applied Sciences Olten



A match is found in the second entry. Now, the IP module forwards the IP datagram by means of interface 2 directly to the computer lucerne. The computer lucerne is not only the IP destination but also the Ethernet destination. The IP datagram now arrives at the computer lucerne and is transmitted up to the IP module. There, the IP addresses are compared and a match between the destination and its own address is found. Now, the signal can be given to the transport layer. Summary If an IP datagram is wandering around a large network, it is possible that, depending on the services, many IP routers must be used before the end destination is finally reached. A central source does not control the path of the IP datagram. It is the result of the entries in the routing tables of those computers, through which the IP datagram has to pass. In a large network, it is a difficult task to maintain correct routing tables on all computers because the network configuration can change daily. On the one hand, errors in the routing tables can block network traffic and on the other hand, it is difficult to find them. Various services can simplify this administrative job: ICMP (Internet Control Message Protocol) can discover various route errors. Another possibility is to patch in a routing protocol, which allows the dynamic exchange of information between computers. In addition, the Domain Name System (DNS) simplifies the maintenance of hosts files on the individual computers.

5.6 User Datagram Protocol UDP

UDP is one of the two standard protocols of the transport layer. It provides the applications with various services. Some examples are: Network File System (NFS) or Simple Network Management Protocol (SNMP). UDP is a connectionless protocol. This means that: the correct delivery of data cannot be guaranteed. a direct connection to a partner UDP model is not maintained. the datagram is simply sent into the system and received by the system. UDP boosts the functional range of communication by only two additional features, the remainder stays with the IP: Two fields for the source port and the destination port, in order to deliver the data to the desired application process. A checksum field that watches over the integrity of the sent data. These fields are packed into a UDP header, which, together with the application's message, is forwarded to the IP module for further processing. When data is sent, UDP does not segment the data nor does it put it together again once the data packets have been received. This means, when an application transmits data, it will be received at the other end in the same sized chunks. These data packets are called messages by the UDP protocol. So-called ports organize the coordination between the client/server applications. These ports are numbered, from zero on up. One certain server application is allocated a globally unique port. For example, a HTTP server will always listen to port number 80. The checksum (= sum of all digits) is a value that is calculated by using the data components. The checksum is used to verify the correct transfer of data. The sender calculates the checksum using the data components adds it to the header and sends the data plus the header. At the end destination, the header is unpacked, the checksum and data are filtered out and then, and a new checksum is calculated using the received data. The two checksums are compared. If there is a difference, then one assumes that the data was damaged during transmission and no longer matches the originally sent data. If, upon reception, an IP datagram sets the word UDP in the field "type", then it will be forwarded to the UDP module. The UDP module controls first the UDP checksum. The value zero says that the checksum was not calculated at the source end. If there is another value, then the data can be verified. With a valid checksum, the field port can be controlled and if an application is linked to this port, the message will be forwarded to this application.
University of Applied Sciences Olten 32 08.03.05

5.7 Transmission Control Protocol TCP

In contrast to UDP, TCP offers a connection-oriented transport system, e.g. TCP guarantees the successful delivery of the data. TCP is used by applications that are built on the guaranteed delivery of data and do not want to be concerned with "time-outs" and "re-transmissions". Two popular TCP applications are FTP (File Transfer Protocol) and TELNET. When compared to UDP, TCP is more complicated because it has more functions. It also needs more network and computer resources. Like UDP, TCP applications are linked by ports: for example, Port 23 belongs to TELNET and port 21 is assigned to the FTP service. A TELNET client can find his TELNET server when he calls port 23 on the destination computer. When an application is booted up via TCP, the sender TCP module will start a dialogue with the receiver TCP module and exchange status information, so for example, the size of the segment, before the actual transmission is started. In contrast to UDP, TCP divides an application's data stream into data packets, which in TCP are called segments. The size of the segments is negotiated during initialisation. For example, it can happen on the receiver's side that10 read commands result from 5 write commands before all the data has been received or that only one single read command is necessary. Each sent TCP segment has to be acknowledged by the receiver within a certain period of time, otherwise the segment will be re-transmitted. Both sides can control the data stream on the other side and that is why this mechanism can prevent congestion on the receiver's side.

5.8 Internet Applications

There are a number of applications that build on the functionality of TCP and UDP. Since its beginning, Email has been an important component of the TCP protocol family. The basis for this popular service is a very simple application layer network protocol the SMTP (Simple Mail Transfer Protocol). This standard is supplemented by the POP3-Protocol (Post Office Protocol), which creates simple access possibilities for already sent e-mails.




Mail Server

Mail Server

E-Mail on the Internet SMTP SMTP (Simple Mail Transfer Protocol) is primarily used to send messages. The protocol contains the necessary functions to define the sender, the receiver and the text of the message. Furthermore, it permits the building of user groups, which then can be used as an addressee. If only a message for a local user is involved, then the mail server will send the message directly to the user. With any other destination, the mail server has to first establish a TCP/IP connection to the end computer and then it will hand over the message for delivery. If the connection cannot be established, then delivery will be regularly attempted over a period of time and this can be several days - before the mail is finally returned to the sender as undelivered. Port Nummer Port numbers - it is 25 for SMTP - play a very important role in every network communication. The port number establishes the connection from the TCP layer to the application layer. If you want to access a remote computer e.g. the SMTP service (a computer also provides other services at the same time), you
University of Applied Sciences Olten 33 08.03.05

must indicate not only the computer's address, but also the service that you want to use. This is done with port numbers. The following example should illustrate this: Let us assume we want to send a file with the FTP protocol from computer to computer To start this process, we need know not only the Internet address, but also how to call the FTP server on the other side. Fortunately, everyone knows that port number 21 has been allocated to the FTP server. If we now start the program ftp on our computer, we will be assigned any free user port, e.g. 1234. While establishing the connection to the other side, port 21 will be explicitly addressed in order to activate the FTP server. A unique connection can be established using Internet addresses and port numbers. Once the connection has been established, the application can forward the message to the transport layer for Internetapplications, principally to the TCP protocol.

5.9 Domain Name Service DNS

In small networks, hosts and networks tables can control the allocation of names to addresses. On the Internet, however, the administration of these tables is impossible and very prone to error. The Domain Name Service has replaced these computer tables and implemented a solution: DNS can be expanded. It is not based on a single, large table, but is implemented as a distributed database system, which does not become unusable if the network grows. DNS guarantees that information will be distributed over new computers to everyone else on the Internet, whenever necessary. This information is not automatically distributed, but only when it is really necessary. When a DNS server receives a request about a computer and it has no information about it, then it will forward the request to authoritative server. An authoritative server is any server whose job it is to hold ready the exact information for the questionable domain. When the authoritative server answers, the local server will remember (cache) the answer. If the local server is re-asked about this information, then it can answer the request by itself. It is the ability to seek information about computers from an authoritative source and the ability to distribute exact information that lets DNS be a more powerful instrument than a computer table. DNS does not know a central database with all of the information about computers on the Internet. The information is distributed throughout thousands of name-servers, the so-called root-servers. The Top Level Domains are directly under the root domain. There are two types of Top Level Domains geographic and organizational. Geographic domains have been established for each country on earth. They are identified by a two-letters-long code: e.g. CH for Switzerland, JP for Japan, DE for Germany. The American code US is hardly used because the organizational domains play a much more important role within the United States. The Top Level Domains within the United States are organizational domains: COM EDU GOV MIL NET ORG commercial business educational institution government agencies military organizations that deal with the operation of the Internet organization that do not fit in one of the above categories such as non-profit organizations

University of Applied Sciences Olten



Amplitude Modulation (AM).............................8 APNIC ............................................................23 ARP ................................................................24 ATM ...............................................................14

Layers ............................................................ 11 M
MAN (Metropolitan Area Network)................ 13 Modem ............................................................ 7

Baud .................................................................6 Bridge .............................................................18

OSI-Model ..................................................... 11

Parity Check..................................................... 6 Phase Modulation (PM).................................... 9 Polling............................................................ 16 POP3 ............................................................. 34 Port Nummer ................................................. 34

Cheapernet .....................................................19 CRC..................................................................7 CSMA-CD ......................................................16

Datex-L...........................................................13 Datex-P ..........................................................13 DNS................................................................34 DNS Names ....................................................28 DSL / ADSL.....................................................14

Quadratur Amplitude Modulation .................... 9

Repeater ........................................................ 17 RIPE ............................................................... 23 Router............................................................ 18 Routing .......................................................... 28

Echo .................................................................6 Ethernet ..........................................................18 Ethernet-Frame ...............................................19

Simplex ............................................................ 5 SMTP ............................................................. 34 Subnet Mask .................................................. 24 Switch ............................................................ 23

Frequency Modulation (FM)..............................8

GAN (Global Area Network) ...........................13 Gateway .........................................................18

TCP................................................................ 33 Token-Ring .................................................... 17 Carrier Frequency ............................................. 7 TwistedPair .................................................... 19

Half-duplex.......................................................5 Hayes Commands ...........................................7 Hub ................................................................18

UDP ............................................................... 33 UMTS ............................................................ 14

IANA ..............................................................23 ICANN............................................................23 ISDN...............................................................14

Full-duplex ....................................................... 5

Coaxial Cable..................................................20

WAN (Wide Area Network)............................ 12

LAN (Local Area Network) ..............................12

Cyclic Block Check............................................ 7

University of Applied Sciences Olten