Lecture notes on computer Networking, Lecture notes of Computer Networks

An overview of internetworking and networking devices. It covers topics such as bridges, routers, gateways, routing, and the global internet. the concept of internetworking and how it connects different types of networks. It also describes the different types of networking devices such as routers, bridges, repeaters, and gateways. the functions of bridges and routers and how they work. It also covers distance vector and link-state routing protocols. useful for students studying computer networking and related fields.

Typology: Lecture notes

2012/2013

Available from 04/01/2022

reshma-praveen
reshma-praveen 🇮🇳

5 documents

1 / 18

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
Module II(13 hours)
Internetworking - Networking devices - Bridges, Routers, Gateways, Routing- Network as a
graph, distance vector (RIP), link state (OSPF), Metrics, Routing for mobile hosts, Global
Internet - Subnetting, CIDR, BGP, Routing areas.
Internetworking
Internetworking is the practice of connecting a computer network with other networks
through the use of gateways that provide a common method of routing information packets
between the networks. The resulting system of interconnected networks is called an
internetwork, or simply an internet. Internetworking started as a way to connect disparate
types of networking technology, but it became widespread through the developing need to
connect two or more local area networks via some sort of wide area network. The original
term for an internetwork was catenet.
The definition of an internetwork today includes the connection of other types of computer
networks such as personal area networks. The network elements used to connect individual
networks in the ARPANET, the predecessor of the Internet, were originally called gateways,
but the term has been deprecated in this context, because of possible confusion with
functionally different devices. Today the interconnecting gateways are called Internet routers.
Networking Devices
An internetworking device is a widely-used term for any hardware within networks that
connect different network resources. Key devices that comprise a network are routers,
bridges, repeaters and gateways. Routers are highly intelligent network devices that are
primarily used for large networks and provide the best data path for effective communication.
Routers have memory chips which store large quantities of network addresses. Bridges are
used to connect two large networks by providing different network services. Repeaters are
used for signal and data regeneration and are primarily responsible for data amplification.
Gateways are internetworking devices used to convert formats and are the backbone of any
network architecture.
Bridges
A bridge is a type of computer network device that provides interconnection with other
bridge networks that use the same protocol. Bridge devices work at the data link layer of the
Open System Interconnect (OSI) model, connecting two different networks together and
providing communication between them. Bridges are similar to repeaters and hubs in that
they broadcast data to every node. However, bridges maintain the media access control
1
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12

Partial preview of the text

Download Lecture notes on computer Networking and more Lecture notes Computer Networks in PDF only on Docsity!

Module II(13 hours)

Internetworking - Networking devices - Bridges, Routers, Gateways, Routing- Network as a graph, distance vector (RIP), link state (OSPF), Metrics, Routing for mobile hosts, Global Internet - Subnetting, CIDR, BGP, Routing areas.

Internetworking

Internetworking is the practice of connecting a computer network with other networks through the use of gateways that provide a common method of routing information packets between the networks. The resulting system of interconnected networks is called an internetwork , or simply an internet. Internetworking started as a way to connect disparate types of networking technology, but it became widespread through the developing need to connect two or more local area networks via some sort of wide area network. The original term for an internetwork was catenet. The definition of an internetwork today includes the connection of other types of computer networks such as personal area networks. The network elements used to connect individual networks in the ARPANET, the predecessor of the Internet, were originally called gateways, but the term has been deprecated in this context, because of possible confusion with functionally different devices. Today the interconnecting gateways are called Internet routers.

Networking Devices

An internetworking device is a widely-used term for any hardware within networks that connect different network resources. Key devices that comprise a network are routers, bridges, repeaters and gateways. Routers are highly intelligent network devices that are primarily used for large networks and provide the best data path for effective communication. Routers have memory chips which store large quantities of network addresses. Bridges are used to connect two large networks by providing different network services. Repeaters are used for signal and data regeneration and are primarily responsible for data amplification. Gateways are internetworking devices used to convert formats and are the backbone of any network architecture.

Bridges

A bridge is a type of computer network device that provides interconnection with other bridge networks that use the same protocol. Bridge devices work at the data link layer of the Open System Interconnect (OSI) model, connecting two different networks together and providing communication between them. Bridges are similar to repeaters and hubs in that they broadcast data to every node. However, bridges maintain the media access control

(MAC) address table as soon as they discover new segments, so subsequent transmissions are sent to only to the desired recipient. Bridges are also known as Layer 2 switches. A network bridge device is primarily used in local area networks because they can potentially flood and clog a large network thanks to their ability to broadcast data to all the nodes if they don’t know the destination node's MAC address. A bridge uses a database to ascertain where to pass, transmit or discard the data frame.

  1. If the frame received by the bridge is meant for a segment that resides on the same host network, it will pass the frame to that node and the receiving bridge will then discard it.
  2. If the bridge receives a frame whose node MAC address is of the connected network, it will forward the frame toward it.

Routers

A router is a device that analyzes the contents of data packets transmitted within a network or to another network. Routers determine whether the source and destination are on the same network or whether data must be transferred from one network type to another, which requires encapsulating the data packet with routing protocol header information for the new network type. Based on designs developed in the 1960s, the Advanced Research Projects Agency Network (ARPANET) was created in 1969 by the U.S. Department of Defense. This early network design was based on circuit switching. The first device to function as a router was the Interface Message Processors that made up ARPANET to form the first data packet.

 IPX - Internet Packet Exchange. Used on Netware systems.  NLSP - Netware Link Services protocol - Uses OSPF algorithm and is replacing IPX to provide internet capability.  RIP - Routing information protocol uses a distance vector algorithm. There is a device called a brouter which will function similar to a bridge for network transport protocols that are not routable, and will function as a router for routable protocols. It functions at the network and data link layers of the OSI network model.

Gateways

A gateway can translate information between different network data formats or network architectures. It can translate TCP/IP to AppleTalk so computers supporting TCP/IP can communicate with Apple brand computers. Most gateways operate at the application layer, but can operate at the network or session layer of the OSI model. Gateways will start at the lower level and strip information until it gets to the required level and repackage the information and work its way back toward the hardware layer of the OSI model. To confuse issues, when talking about a router that is used to interface to another network, the word gateway is often used. This does not mean the routing machine is a gateway as defined here, although it could be.

Network as a Graph

Routing is, in essence, a problem of graph theory. Figure shows a graph representing a network. The nodes of the graph, labeled A through F, may be either hosts, switches, routers, or networks. For our initial discussion, we will focus on the case where the nodes are routers. The edges of the graph correspond to the network links. Each edge has an associated cost , which gives some indication of the desirability of sending traffic over that link. The basic problem of routing is to find the lowest-cost path between any two nodes, where the cost of a path equals the sum of the costs of all the edges that make up the path. You could imagine just calculating all the shortest paths and loading them into some non-volatile storage on each node. Such a static approach has several shortcomings: ■ It does not deal with node or link failures; ■ It does not consider the addition of new nodes or links; ■ It implies that edge costs cannot change, even though we might reasonably wish to temporarily assign a high cost to a link that is heavily loaded. For these reasons, routing is achieved in most practical networks by running routing protocols among the nodes.

Distance Vector (RIP)

The idea behind the distance-vector algorithm is suggested by its name. Each node constructs a one-dimensional array (a vector) containing the “distances” (costs) to all other nodes and distributes that vector to its immediate neighbors. The starting assumption for distance-vector routing is that each node knows the cost of the link to each of its directly connected neighbors. A link that is down is assigned an infinite cost. In this example, the cost of each link is set to 1, so that a least-cost path is simply the one with the fewest hops. (Since all edges have the same cost, we do not show the costs in the graph.)We can represent each node’s knowledge about the distances to all other nodes as a table like the one given in Table 4.5. Note that each node only knows the information in one row of the table (the one that bears its name in the left column). The global view that is presented here is not available at any single point in the network. We may consider each row in Table4.5 as a list of distances from one node to all other nodes, representing the current beliefs of that node. Initially, each node sets a cost of 1 to its directly connected neighbors and ∞ to all other nodes. Thus, A initially believes that it can reach B in

stress that there is no one node in the network that has all the information in this table—each node only knows about the contents of its own routing table. The beauty of a distributed algorithm like this is that it enables all nodes to achieve a consistent view of the network in the absence of any centralized authority.

Link State (OSPF)

Link-state routing is the second major class of intradomain routing protocol. The starting assumptions for link-state routing are rather similar to those for distance-vector routing. Each node is assumed to be capable of finding out the state of the link to its neighbours (up or down) and the cost of each link. Again, we want to provide each node with enough information to enable it to find the least-cost path to any destination. The basic idea behind link-state protocols is very simple: Every node knows how to reach its directly connected neighbors, and if we make sure that the totality of this knowledge is disseminated to every node, then every node will have enough knowledge of the network to build a complete map of the network. This is clearly a sufficient condition (although not a necessary one) for finding the shortest path to any point in the network. Thus, link-state routing protocols rely on two mechanisms: reliable dissemination of link-state information, and the calculation of routes from the sum of all the accumulated link-state knowledge. Reliable Flooding Reliable flooding is the process of making sure that all the nodes participating in the routing protocol get a copy of the link-state information from all the other nodes. As the term “flooding” suggests, the basic idea is for a node to send its link-state information out on all of its directly connected links, with each node that receives this information forwarding it out on all of its links. This process continues until the information has reached all the nodes in the network. More precisely, each node creates an update packet, also called a link-state packet

(LSP), that contains the following information:  The ID of the node that created the LSP;  A list of directly connected neighbors of that node, with the cost of the link to each one;  A sequence number;  A time to live for this packet. Flooding works in the following way. First, the transmission of LSPs between adjacent routers is made reliable using acknowledgments and retransmissions just as in the reliable link-layer protocol. However, there are several more steps needed to reliably flood an LSP to all nodes in a network. Consider a node X that receives a copy of an LSP that originated at some other node Y. Note that Y may be any other router in the same routing domain as X. X checks to see if it has already stored a copy of an LSP from Y. If not, it stores the LSP. If it already has a copy, it compares the sequence numbers; if the new LSP has a larger sequence number, it is assumed to be the more recent, and that LSP is stored, replacing the old one. A smaller (or equal) sequence number would imply an LSP older (or not newer) than the one stored, so it would be discarded and no further action would be needed. If the received LSP was the newer one, X then sends a copy of that LSP to all of its neighbors except the neighbor from which the LSP was just received. The fact that the LSP is not sent back to the node from which it was received helps to bring an end to the flooding of an LSP. Since X passes the LSP on to all its neighbors, who then turn around and do the same thing, the most recent copy of the LSP eventually reaches all nodes. Open Shortest Path First Protocol (OSPF) One of the most widely used link-state routing protocols is OSPF. The first word, “Open,” refers to the fact that it is an open, nonproprietary standard, created under the auspices of the IETF. The “SPF” part comes from an alternative name for link-state routing. OSPF adds quite a number of features to the basic link-state algorithm described above, including the following:  Authentication of routing messages: This is a nice feature, since it is all toocommon for some misconfigured host to decide that it can reach every host in the universe at a cost of 0. When the host advertises this fact, every router in the surrounding neighborhood updates its forwarding tables to point to that host, and said host receives a vast amount of data that, in reality, it has no idea what to do with. It typically drops it all, bringing the network to a halt. Such disasters can be averted in many cases by requiring routing updates to be authenticated. Early versions of OSPF used a simple

A second version of the ARPANET routing algorithm, sometimes called the “new routing mechanism,” took both link bandwidth and latency into consideration and used delay, rather than just queue length, as a measure of load. This was done as follows. First, each incoming packet was timestamped with its time of arrival at the router (ArrivalTime); its departure time from the router (DepartTime) was also recorded. Second, when the link-level ACK was received from the other side, the node computed the delay for that packet as Delay = ( DepartTime− ArrivalTime ) +TransmissionTime +Latency where TransmissionTime and Latency were statically defined for the link and captured the link’s bandwidth and latency, respectively. Notice that in this case, DepartTime − ArrivalTime represents the amount of time the packet was delayed (queued) in the node due to load. If the ACK did not arrive, but instead the packet timed out, then DepartTime was reset to the time the packet was retransmitted. In this case, DepartTime − ArrivalTime captures the reliability of the link—the more frequent the retransmission of packets, the less reliable the link, and the more we want to avoid it. Finally, the weight assigned to each link was derived from the average delay experienced by the packets recently sent over that link. Although an improvement over the original mechanism, this approach also had a lot of problems. Under light load, it worked reasonably well, since the two static factors of delay dominated the cost. Under heavy load, however, a congested link would start to advertise a very high cost. This caused all the traffic to move off that link, leaving it idle, so then it would advertise a low cost, thereby attracting back all the traffic, and so on. The effect of this instability was that, under heavy load, many links would in fact spend a great deal of time being idle, which is the last thing you want under heavy load.

Routing Mobile Hosts

All mobile agents are assumed to have a permanent home location.When a portable computer is attached to a remote network it contacts a process that acts as the local foreign agent. Each home location has a process that acts as the home agent.

  • Periodically the foreign agent broadcasts its address
  • The mobile agent registers with the foreign agent and supplies its home address
  • The foreign agent contacts the mobile agent’s home agent reporting the mobile agent’s location. Security must be used to verify the identity of the mobile agent.
  • The foreign agent registers the mobile agent Routing Packets to a Mobile Agent Packets sent to the mobile agent are routed to the users home network. The home agent routes the packets to the foreign agent.The home agent provides the source of incoming packets with the remote address of the mobile agent Mobile host retains its original IP address; but borrows the service of a new COA for the network that it is visiting. Several mobile hosts can share the same COA. In that case the COA is actually the IP address of a router running the foreign agent. But this does not need to be the case. Home Agent (HA) system in the home network of the Mobile Node( MN), typically a router registers the location of the MN, tunnels IP datagrams to the COA Foreign Agent (FA) system in the current foreign network of the MN, typically a router forwards the tunneled datagrams to the MN, typically also the default router for the MN. Care-of Address (COA)

The network portion of the address is separated from the host portion of the address by a mask.The mask simply indicates how many bits are used for the network portion, leaving the remaining bits for the host portion. A 24-bit mask indicates that the first 24 bits of the address are network bits, and the remaining 8 bits are host bits. A 16-bit mask indicates that the first 16 bits of the address are network bits, and the remaining 16 bits are host bits. Significance of IP networks and hosts An IP host is any device with an IP address, such as a PC. Multiple hosts reside on a given IP network or subnet (short for subnetwork). A group of IP networks is an internetwork, with the largest internetwork being the Internet. What is typically called a “data network” is technically an internetwork, because multiple IP networks are connected together by routers.

BGP- Border Gateway Protocol

Border Gateway Protocol ( BGP ) is a standardized exterior gateway protocol designed to exchange routing and reachability information between autonomous systems (AS) on the Internet.[1]^ The protocol is often classified as a path vector protocol, but is sometimes also classed as a distance vector routing protocol. The Border Gateway Protocol does not use Interior Gateway Protocol ( IGP ) metrics, but makes routing decisions based on paths, network policies and/or rule-sets configured by a network administrator. An Interior Gateway Protocol (IGP) is a type of protocol used for exchanging routing information between gateways (commonly routers) within an Autonomous System (for example, a system of corporate local area networks). This routing information can then be used to route network-level protocols like IP. Interior gateway protocols can be divided into two categories: distance-vector routing protocols and link-state routing protocols. Specific examples of IGP protocols include Open Shortest Path First (OSPF), Routing Information Protocol (RIP) and Intermediate System to Intermediate System (IS-IS). By contrast, exterior gateway protocols are used to exchange routing information between Autonomous Systems and rely on IGPs to resolve routes within an AS. The Border Gateway Protocol plays a key role in the overall operation of the Internet and is involved in making core routing decisions.

The Border Gateway Protocol is the successor to the Exterior Gateway Protocol (EGP) and is currently the most widely used exterior gateway protocol by Internet service providers because BGP allows for fully decentralised routing. BGP was originally designed to help transition from the core ARPAnet model to a decentralized system that included the NSFNET backbone and its associated regional networks.

Operation

BGP neighbors, called peers, are established by manual configuration between routers to create a TCP session on port 179. A BGP speaker sends 19-byte keep-alive messages every 30 seconds to maintain the connection.[3]^ Among routing protocols, BGP is unique in using TCP as its transport protocol. When BGP runs between two peers in the same autonomous system (AS), it is referred to as Internal BGP ( iBGP or Interior Border Gateway Protocol ). When it runs between different autonomous systems, it is called External BGP ( EBGP or Exterior Border Gateway Protocol ). Routers on the boundary of one AS exchanging information with another AS are called border or edge routers or simply eBGP peers and are typically connected directly, while iBGP peers can be interconnected through other intermediate routers. Other deployment topologies are also possible, such as running eBGP peering inside a VPN tunnel, allowing two remote sites to exchange routing information in a secure and isolated manner. The main difference between iBGP and eBGP peering is in the way routes that were received from one peer are propagated to other peers. For instance, new routes learned from an eBGP peer are typically redistributed to all other iBGP peers as well as all eBGP peers (if transit mode is enabled on the router). However, if new routes were learned on an iBGP peering, then they are re-advertised only to all other eBGP peers. These route-propagation rules effectively require that all iBGP peers inside an AS are interconnected in a full mesh. Filtering routes learned from peers, their transformation before redistribution to peers or before plumbing them into the routing table is typically controlled via route-maps mechanism. These are basically rules which allow to apply certain actions to routes matching certain criteria on either ingress or egress path. These rules can specify that the route is to be dropped or, alternatively, its attributes are to be modified. It is usually the responsibility of the AS administrator to provide the desired route-map configuration on a router supporting BGP.

Extensions negotiation

the "OpenSent" state, the router sends an Open message and waits for one in return in order to transition to the "OpenConfirm" state. Keepalive messages are exchanged and, upon successful receipt, the router is placed into the "Established" state. In the "Established" state, the router can send/receive: Keepalive; Update; and Notification messages to/from its peer.

Partitioning an Internetwork into Routing Areas

This topic explains how to partition a large IPXTM^ internetwork into routing areas. Because large internetworks are typically linked by one or more WAN connections, the guidelines and examples provided in this topic are oriented primarily toward WAN connections, which require other Novell®^ products or third-party products in addition to NetWare®^ 4.1 x software or IPX Upgrade for NetWare Servers. However, the information in this topic can still help you partition a purely LAN-based internetwork.

Routing Areas

Routing areas establish hierarchy within an IPX internetwork. For growing networks, routing areas allow for better scaling---more LANs, servers, and routers than otherwise possible. Routing areas also separate an internetwork into manageable components, which is desirable for administrative simplicity. An area is a set of routers that are administratively configured to exchange link-state information with each other. There is one special area—the backbone area, also known as area 0. Routers R1, R2, and R3 are members of the backbone area. They are also members of at least one nonbackbone area; R1 is actually a member of both area 1 and area 2. A router that is a member of both the backbone area and a nonbackbone area is an area border router (ABR). Note that these are distinct from the routers that are at the edge of an AS, which are referred to as AS border routers for clarity.

All the routers in the area send link-state advertisements to each other, and thus develop a complete, consistent map of the area. However, the link-state advertisements of routers that are not area border routers do not leave the area in which they originated. This has the effect of making the flooding and route calculation processes considerably more scalable. For example, router R4 in area 3 will never see a link-state advertisement from router R8 in area 1. As a consequence, it will know nothing about the detailed topology of areas other than its own. Figure 4. Using RIP to Partition Routing Areas When dividing a domain into areas, the network administrator makes a trade-off between scalability and optimality of routing. The use of areas forces all packets travelling from one area to another to go via the backbone area, even if a shorter path might have been available. For example, even if R4 and R5 were directly connected, packets would not flow between them because they are in different nonbackbone areas. It turns out that the need for scalability is often more important than the need to use the absolute shortest path. This illustrates an important principle in network design. There is frequently a trade-off between some sort of optimality and scalability. When hierarchy is introduced, information is hidden from some nodes in the network, hindering their ability to make perfectly optimal decisions. However, information hiding is essential to scalability, since it saves all nodes from having global knowledge. It is invariably true in large networksthat scalability is a more pressing design goal than perfect optimality.