Вы находитесь на странице: 1из 10

Subnet Mask, Static and Dynamic Router, Gateway, Router Information Protocol, Routing Table, and Routing Protocol

What is a Subnet Mask? An IP address has two components, the network address and the host address. A subnet mask separates the IP address into the network and host addresses (<network><host>). Sub netting further divides the host part of an IP address into a subnet and host address (<network><subnet><host>). It is called a subnet mask because it is used to identify network address of an IP address by performing bitwise AND operation on the net mask. A Subnet mask is a 32-bit number that masks an IP address, and divides the IP address into network address and host address. Subnet Mask is made by setting network bits to all "1"s and setting host bits to all "0"s. Within a given network, two host addresses are reserved for special purpose. The "0" address is assigned a network address and "255" is assigned to a broadcast address, and they cannot be assigned to a host. Examples of commonly used net masks for classed networks are 8-bits (Class A), 16-bits (Class B) and 24-bits (Class C), and classless networks are as follows:
Class CIDR CIDR CIDR CIDR A CIDR CIDR CIDR CIDR CIDR CIDR CIDR B CIDR CIDR CIDR CIDR CIDR CIDR CIDR C CIDR CIDR CIDR CIDR CIDR CIDR Address /4 /5 /6 /7 /8 /9 /10 /11 /12 /13 /14 /15 /16 /17 /18 /19 /20 /21 /22 /23 /24 /25 /26 /27 /28 /29 /30 # of Hosts 240,435,456 134,217,728 67,108,864 33,554,432 16,777,216 8,388,608 4,194,304 2,097,152 1,048,576 524,288 262,144 131,072 65,534 32,768 16,384 8,192 4,096 2,048 1,024 512 256 128 64 32 16 8 4 Netmask (Binary) 11110000 00000000 11111000 00000000 11111100 00000000 11111110 00000000 11111111 00000000 11111111 10000000 11111111 11000000 11111111 11100000 11111111 11110000 11111111 11111000 11111111 11111100 11111111 11111110 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 11111111 Netmask (Decimal) 240.0.0.0 248.0.0.0 252.0.0.0 254.0.0.0 255.0.0.0 255.128.0.0 255.192.0.0 255.224.0.0 255.240.0.0 255.248.0.0 255.252.0.0 255.254.0.0 255.255.0.0 255.255.128.0 255.255.192.0 255.255.224.0 255.255.240.0 255.255.248.0 255.255.252.0 255.255.254.0 255.255.255.0 255.255.255.128 255.255.255.192 255.255.255.224 255.255.255.240 255.255.255.248 255.255.255.252

00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 10000000 11000000 11100000 11110000 11111000 11111100 11111110 11111111 11111111 11111111 11111111 11111111 11111111 11111111

00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 10000000 11000000 11100000 11110000 11111000 11111100

Sub netting an IP network is to separate a big network into smaller multiple networks for reorganization and security purposes. All nodes (hosts) in a sub network see all packets transmitted by any node in a network. Performance of a network is adversely affected under heavy traffic load due to collisions and retransmissions.

Applying a subnet mask to an IP address separates network address from host address. The network bits are represented by the 1's in the mask, and the host bits are represented by 0's. Performing a bitwise logical AND operation on the IP address with the subnet mask produces the network address. For example, applying the Class C subnet mask to our IP address 216.3.128.12 produces the following network address: IP: 1101 1000 . 0000 0011 . 1000 0000 . 0000 1100 (216.003.128.012) Mask: 1111 1111 . 1111 1111 . 1111 1111 . 0000 0000 (255.255.255.000) --------------------------------------------1101 1000 . 0000 0011 . 1000 0000 . 0000 0000 (216.003.128.000) Sub netting Network Here is another scenario where sub netting is needed. Pretend that a web host with a Class C network needs to divide the network so that parts of the network can be leased to its customers. Let's assume that a host has a network address of 216.3.128.0 (as shown in the example above). Let's say that we're going to divide the network into 2 and dedicate the first half to itself, and the other half to its customers. 216 . 3 . 128 . (0000 0000) (1st half assigned to the web host) 216 . 3 . 128 . (1000 0000) (2nd half assigned to the customers) The web host will have the subnet mask of 216.3.128.128 (/25). Now, we'll further divide the 2nd half into eight blocks of 16 IP addresses. 216 . 3 . 128 . (1000 0000) Customer 1 -- Gets 16 IPs (14 usable) 216 . 3 . 128 . (1001 0000) Customer 2 -- Gets 16 IPs (14 usable) 216 . 3 . 128 . (1010 0000) Customer 3 -- Gets 16 IPs (14 usable) 216 . 3 . 128 . (1011 0000) Customer 4 -- Gets 16 IPs (14 usable) 216 . 3 . 128 . (1100 0000) Customer 5 -- Gets 16 IPs (14 usable) 216 . 3 . 128 . (1101 0000) Customer 6 -- Gets 16 IPs (14 usable) 216 . 3 . 128 . (1110 0000) Customer 7 -- Gets 16 IPs (14 usable) 216 . 3 . 128 . (1111 0000) Customer 8 -- Gets 16 IPs (14 usable) ----------------------------255 . 255 . 255 . (1111 0000) (Subnet mask of 255.255.255.240) Classless Inter Domain Routing Classless Inter Domain Routing (CIDR) was invented to keep the Internet from running out of IP Addresses. The IPv4, a 32-bit, addresses have a limit of 4,294,967,296 (232) unique IP addresses. The classful address scheme (Class A, B and C) of allocating IP addresses in 8-bit increments can be very wasteful. With classful addressing scheme, a minimum number of IP addresses allocated to an organization is 256 (Class C). Giving 256 IP addresses to an organization only requiring 15 IP addresses is wasteful. Also, an organization requiring more than 256 IP addresses (let's say 1,000 IP addresses) is assigned a Class B, which allocates 65,536 IP addresses. Similarly, an organization requiring more than 65,636 (65,634 usable IPs) is assigned a Class A network, which allocates 16,777,216 (16.7 Million) IP addresses. This type of address allocation is very wasteful. With CIDR, a network of IP addresses is allocated in 1-bit increments as opposed to 8-bits in classful network. The use of a CIDR notated address can easily represent classful addresses

(Class A = /8, Class B = /16, and Class C = /24). The number next to the slash (i.e. /8) represents the number of bits assigned to the network address. The example shown above can be illustrated with CIDR as follows: 216.3.128.12, with subnet mask of 255.255.255.128 is written as 216.3.128.12/25 Similarly, the 8 customers with the block of 16 IP addresses can be written as: 216.3.128.129/28, 216.3.128.130/28, and etc. With an introduction of CIDR addressing scheme, IP addresses are more efficiently allocated to ISPs and customers; and hence there is less risk of IP addresses running out anytime soon. For detailed specification on CIDR, please review RFC 1519. With introduction of additional gaming, medical, applicance and telecom devices requiring static IP addresses in addition to more than 6.5 billion (July 2006 est.) world population, the IPv4 addresses with CIDR addressing scheme will eventually run out. To solve shortage of IPv4 addresses, the IPv6 (128-bit) address scheme was introduced in 1993. REFERENCE: http://www.iplocation.net/tools/netmask.php

What is Static and Dynamic Routers? For routing between routers to work efficiently in an internetwork, routers must have knowledge of other network IDs or be configured with a default route. On large internetworks, the routing tables must be maintained so that the traffic always travels along optimal paths. How the routing tables are maintained defines the distinction between static and dynamic routing. Static Routing - A router with manually configured routing tables is known as a static router. A network administrator, with knowledge of the internetwork topology, manually builds and updates the routing table, programming all routes in the routing table. Static routers can work well for small internetworks but do not scale well to large or dynamically changing internetworks due to their manual administration. Static routers are not fault tolerant. The lifetime of a manually configured static route is infinite and, therefore, static routers do not sense and recover from downed routers or downed links. A good example of a static router is a multi-homed computer running Windows 2000 (a computer with multiple network interface cards). Creating a static IP router with Windows 2000 is as simple as installing multiple network interface cards, configuring TCP/IP, and enabling IP routing. Dymanic Routing - A router with dynamically configured routing tables is known as a dynamic router. Dynamic routing consists of routing tables that are built and maintained automatically through an ongoing communication between routers. This communication is facilitated by a routing protocol, a series of periodic or on-demand messages containing routing information that is exchanged between routers. Except for their initial configuration, dynamic routers require little ongoing maintenance, and therefore can scale to larger internetworks.

Dynamic routing is fault tolerant. Dynamic routes learned from other routers have a finite lifetime. If a router or link goes down, the routers sense the change in the internetwork topology through the expiration of the lifetime of the learned route in the routing table. This change can then be propagated to other routers so that all the routers on the internetwork become aware of the new internetwork topology. The ability to scale and recover from internetwork faults makes dynamic routing the better choice for medium, large, and very large internetworks. A good example of a dynamic router is a computer with Windows 2000 Server and the Routing and Remote Access Service running the Routing Information Protocol (RIP) and Open Shortest Path First (OSPF) routing protocols for IP and RIP for IPX. REFERENCE: http://technet.microsoft.com/en-us/library/cc957844.aspx Differences between Static Routing and Dynamic Routing In static routing the routes are described by fixed paths through a data network. The routes are entered by system administrator. The whole network can be configured by using static routes. Dynamic routing protocols are the applications which discover network destinations dynamically. Routers will communicate the adjacent routers which informs the network to which each router is connected. These routers adjusts automatically in a network when traffic changes. Static Routing: Manually set up route Stable. No impact of traffic and transmission failures Dynamic Routing: Route setting is automatic Responds to the changes of the network Optimized route is selected automatically REFERENCE: http://careerride.com/Networking-what-is-static-and-dynamic-routing.aspx What is a Gateway? A gateway is a data communication device that provides a remote network with connectivity to a host network. A gateway device provides communication to a remote network or an autonomous system that is out of bounds for the host network nodes. Gateways serve as the entry and exit point of a network; all data routed inward or outward must first pass through and communicate with the gateway in order to use routing paths. Generally, a router is configured to work as a gateway device in computer networks. Any network has a boundary or a limit, so all communication placed within that network is conducted using the devices attached to it, including switches and routers. If a network node wants to communicate with a node/network that resides outsides of that network or autonomous system, the network will require the services of a gateway, which is familiar with

the

routing

path

of

other

remote

networks.

The gateway (or default gateway) is implemented at the boundary of a network to manage all the data communication that is routed internally or externally from that network. Besides routing packets, gateways also possess information about the host network's internal paths and the learned path of different remote networks. If a network node wants to communicate with a foreign network, it will pass the data packet to the gateway, which then routes it to the destination using the best possible path. REFERENCE: http://www.techopedia.com/definition/5358/gateway Gateways The link between two computers to connect to internet or another network is called gateway. The gateway works like a portal among two programs by means of communications between protocol and permit them to share data on same computers or among different computers. Gateways are also known as protocol converter that can perform at nay OSI model layer. The task of a gateway is very complex as compared to router and switch. How Gateways works A gateway is a network point that works as an access to another network. Generally in intranet a node can be either a gateway node or the nodes that join the network are gateways. In large organization where the computers control the traffic between organization networks are gateway nodes. Like that the computers used by ISP to connect different user with each other at a time to the internet are gateway nodes. In a project of any business company computer server work as a gateway nodes and it may be proxy server or firewall some time. A gateway may connected to a router because a router exactly known where to through a given packet of data that appears at the gateway then a switch finalize the actual in and out path of the gateway for the specified packet .A gateway is a compulsory features of routes even though other devices can perform as a gateway. The operating system mostly used this term and internet connection sharing act as a gateway and creating a connection among internal network. Gateway security A gateway generally works as a safeguard to a local network and also connects the local network to public network. A gateway offers security just like a firewall with the technique of NAT. Gateway facilitating machine with local internet protocol addresses to access the internet via inclusive address of the gateway. Gateway get packets from the local network and alternate its exterior IP address and a new port address into the resource fields of the IP and UDP headers. Gateway devices A gateway is full of various types of devices which are essential to make available system interoperability as signal translators. The other devices are protocol translators, impedance matching devices, rate converters, and fault isolators. Some time gateway attached with both router and switch to perform action. When a user using home network with gateway has a transceiver used to set up a wireless connection.

Gateway usage, Uses of Gateways There are many kind of usage of gateway in a network as listed below. A gateway can be implemented in software, hardware and some time as a mixture of together. There are lots of equipments and techniques which are being processed such as voice and data communication. The gateways are the best option to achieve the multimedia communications between dissimilar networks because every network has different protocol and characteristics. Gateways are also a key mechanism of any telephony communications. Gateway is offering bridge between telephone network and internet. For real time communication gateway supporting audio conversion and carry out extinction and call setup. Gateway also controls the processing information across the network which contains information about to set up the actual end to end call. A network gateway work like a firewall and filters packets. It also separates corporate network as intranet from a public network. A gateway may also install on a stand alone device. A gateway performs as the interface between local and wide area protocols such as TCP/IP on the Internet. A gateway supervises its client devices, gather their data and execute other task. Gateway devices allow net client to access a variety of computer networks. Gateway is also offering on-line services exclusive of having a preceding service agreement or a continuing association with the service supplier. REFERENCE: http://freewimaxinfo.com/network-gateways.html

What is Routing Information Protocol? RIP (Routing Information Protocol) is a widely-used protocol for managing router information within a self-contained network such as a corporate local area network (LAN) or an interconnected group of such LANs. RIP is classified by the Internet Engineering Task Force (IETF) as one of several internal gateway protocols (Interior Gateway Protocol). Using RIP, a gateway host (with a router) sends its entire routing table (which lists all the other hosts it knows about) to its closest neighbor host every 30 seconds. The neighbor host in turn will pass the information on to its next neighbor and so on until all hosts within the network have the same knowledge of routing paths, a state known as network convergence. RIP uses a hop count as a way to determine network distance. (Other protocols use more sophisticated algorithms that include timing as well.) Each host with a router in the network uses the routing table information to determine the next host to route a packet to for a specified destination. RIP is considered an effective solution for small homogeneous networks. For larger, more complicated networks, RIP's transmission of the entire routing table every 30 seconds may put a heavy amount of extra traffic in the network. The major alternative to RIP is the Open Shortest Path First Protocol (OSPF). REFERENCE: http://searchnetworking.techtarget.com/definition/Routing-Information-Protocol

Definition - What does Routing Information Protocol (RIP) mean? Routing Information Protocol (RIP) is a dynamic protocol used to find the best route or path from end-to-end (source to destination) over a network by using a routing metric/hop count algorithm. This algorithm is used to determine the shortest path from the source to destination, which allows the data to be delivered at high speed in the shortest time. Techopedia explains Routing Information Protocol (RIP) RIP plays an important role providing the shortest and best path for data to take from node to node. The hop is the step towards the next existing device, which could be a router, computer or other device. Once the length of the hop is determined, the information is stored in a routing table for future use. RIP is being used in both local and wide area networks and is generally considered to be easily configured and implemented. REFERENCE: http://www.techopedia.com/definition/24846/routing-information-protocol-rip

What is a Routing Table? A routing table is a set of rules, often viewed in table format, that is used to determine where data packets traveling over an Internet Protocol (IP) network will be directed. All IP-enabled devices, including routers and switches, use routing tables. A routing table contains the information necessary to forward a packet along the best path toward its destination. Each packet contains information about its origin and destination. When a packet is received, a network device examines the packet and matches it to the routing table entry providing the best match for its destination. The table then provides the device with instructions for sending the packet to the next hop on its route across the network. A basic routing table includes the following information: Destination: The IP address of the packet's final destination Next hop: The IP address to which the packet is forwarded Interface: The outgoing network interface the device should use when forwarding the packet to the next hop or final destination Metric: Assigns a cost to each available route so that the most cost-effective path can be chosen Routes: Includes directly-attached subnets, indirect subnets that are not attached to the device but can be accessed through one or more hops, and default routes to use for certain types of traffic or when information is lacking. Routing tables can be maintained manually or dynamically. Tables for static network devices do not change unless a network administrator manually changes them. In dynamic routing, devices build and maintain their routing tables automatically by using routing protocols to exchange information about the surrounding network topology. Dynamic routing tables allow devices to "listen" to the network and respond to occurrences like device failures and network congestion. REFERENCE: http://searchnetworking.techtarget.com/definition/routing-table

What is a Routing Protocol? A routing protocol specifies how routers communicate with each other, disseminating information that enables them to select routes between any two nodes on a computer network, the choice of the route being done by routing algorithms. Each router has a priori knowledge only of networks attached to it directly. A routing protocol shares this information first among immediate neighbors, and then throughout the network. This way, routers gain knowledge of the topology of the network. The term routing protocol may refer specifically to one operating at layer three of the OSI model, which similarly disseminates topology information between routers. Although there are many types of routing protocols, three major classes are in widespread use on IP networks: Interior gateway routing via link state routing protocols, such as OSPF and IS-IS Interior gateway routing via path vector or distance vector protocols, such as IGRP and EIGRP Exterior gateway routing. BGP v4 is the routing protocol used by the public Internet. Many routing protocols are defined in documents called RFCs. The specific characteristics of routing protocols include the manner in which they either prevent routing loops from forming or break them up if they do the manner in which they select preferred routes, using information about hop costs the time they take to converge how well they scale up many other factors REFERENCE: http://en.wikipedia.org/wiki/Routing_protocol Routing protocols A routing protocol is a set of rules or standard that determines how routers on a network communicate with each other and exchange information enabling them to select best routes to a remote network, It is the implementation of a routing algorithm in software or hardware. A routing protocol uses metrics to determine which path to utilize to transmit a packet across an internet work. The metrics used by routing protocols include: Number of Network devices along the path (Hop count), Bandwidth, Delay, and Load Remote networks are added to the routing table in two ways: By the network administrator manually configuring static routes. By implementing a dynamic routing protocol. Static Routing Advantages No overhead on router CPU. No bandwidth usage between links. Security (only administrator adds routes).

Disadvantages Administrator must really understand internetwork and how each router is connected. If a new network is added, administrator must update all routers. Not practical on large networks as it is time intensive. Uses syntax of: ip route [destination_network] [subnet_mask] [next_hop_address | exit_interface] Example of static route Router1(config)#ip route 192.168.2.0 255.255.255.0 serial0 Default Routing A default route, which will point to a router, can be established to receive and attempt to process all packets for which no route appears in the routing table instead of discarding them. Only used when there is only 1 exit interface on a router. Same as static route with the ip route command, but use 0.0.0.0 0.0.0.0 for the IP network and subnet mask followed by the next hop routers common interface. Have to also use the ip classless command since there arent any routes in the routing table. Router3(config)#ip route 0.0.0.0 0.0.0.0 172.16.2.3 Dynamic Routing Advantages Dynamic routing protocols update and maintain the networks in their routing

tables. Dynamic routing protocols not only make a best path determination to various networks, they will also determine a new best path if the initial path becomes unusable or there is a change in the topology.
Routers that use dynamic routing protocols automatically share routing information with other routers and compensate for any topology changes without involving the network administrator. Administrative Distance for IP Routes

The Three Classes of Routing Protocols 1. Distance Vector - Uses the distance to a remote network to find the best path. Each time a packet goes through a router, it is called a hop. The route with the least number of hops is determined to be the best. Easy to configure Not many features RIP,IGRP 2. Link State - Typically called shortest path first, each router creates three tables. 1 tracks directly attached neighbors, 1 determines the entire network topology, and 1 is used for routing table. An example of LS is OSPF. Difficult to configure (More Knowledge required) Feature Riffic OSPF , IS-IS 3. Hybrid - Uses parts of Distance vector and Link state. The best of Both Proprietary EIGRP

REFERENCE: http://www.techbitnbyte.com/what-is-routing-protocols/

Вам также может понравиться