Hot Downloads

Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1
  • 2

TOPIC: routing table information

routing table information 13 years 1 month ago #1645

  • praveen
  • praveen's Avatar
  • Offline
  • New Member
  • Posts: 2
  • Karma: 0
I wanted to know what are the information stored in the routing table of a router/host.

pls any one could explain me on this and also how the IP look up is done are there any standard algorithms for IP look up???

thanks in advance
The administrator has disabled public write access.

Re: routing table information 13 years 1 month ago #1646

  • Chris
  • Chris's Avatar
  • Offline
  • Administrator
  • Posts: 1446
  • Thank you received: 13
  • Karma: 8
Praveen,

Here is a sample of our Cisco router's routing table:
212.205.250.0/32 is subnetted, 1 subnets
C 212.205.250.210 is directly connected, BRI0
C 192.168.1.0/24 is directly connected, Ethernet0
62.0.0.0/32 is subnetted, 1 subnets
C 62.103.2.251 is directly connected, BRI0
S* 0.0.0.0/0 is directly connected, BRI0

The above routing table shows the networks the router is aware of. In this case it knows that its directly connected to a few networks, meaning that one of the router's interfaces is connected to the relative network.

For example, the router's Ethernet0 interface is directly connect the network 192.168.1.0/24.

Since this particular router is setup for Dial on Demand Routing (DDR) the IP addresses on the BRI0 interface will change everytime a new call is initiated.

It's also important to note the last entry:
S* 0.0.0.0/0 is directly connected, BRI0

This entry is a static router, indicated by the 'S'. This route was entered by myself in the router's configuration. It tells the router that if an incoming packet has a destination other than the networks you are aware of, then forward it out the BRI0 interface, which in its turn is connected to our ISP.

This is also called "Gateway of last resort".

The distance vector page has some good information and examples on how routers populate their routing tables. I suggest you take a look at it and post any further questions you might have right here!

Cheers,
Chris Partsenidis.
Founder & Editor-in-Chief
www.Firewall.cx
The administrator has disabled public write access.

Re: routing table information 13 years 1 month ago #1658

  • tfs
  • tfs's Avatar
  • Offline
  • Expert Member
  • Posts: 521
  • Karma: 0
If you do a route print on a host, you will get something like this:

[code:1]
C:\WINNT\system32>route print
===========================================================================
Interface List
0x1 ........................... MS TCP Loopback interface
0x2 ...44 45 53 54 42 00 ...... NOC Extranet Access Adapter
0x1000004 ...00 02 b3 5c ec 0a ...... Intel(R) PRO/100+ Management Adapter
===========================================================================
===========================================================================
Active Routes:
Network Destination Netmask Gateway Interface Metric
0.0.0.0 0.0.0.0 192.168.122.1 192.168.122.7 1
127.0.0.0 255.0.0.0 127.0.0.1 127.0.0.1 1
192.168.122.0 255.255.255.0 192.168.122.7 192.168.122.7 1
192.168.122.7 255.255.255.255 127.0.0.1 127.0.0.1 1
192.168.122.255 255.255.255.255 192.168.122.7 192.168.122.7 1
224.0.0.0 224.0.0.0 192.168.122.7 192.168.122.7 1
255.255.255.255 255.255.255.255 192.168.122.7 2 1
Default Gateway: 192.168.122.1
===========================================================================
Persistent Routes:
None
[/code:1]

Information on the Route command, which is how you display and manually manipulate the Routing table, can be found at:

www.microsoft.com/technet/treeview/defau...o/proddocs/route.asp

You can play with the table yourself using "route add" and "route delete" and then look at the routing table. This table is built using information put in during the configuration of your NIC. For example, looking at the above table you will see a Network Destination of 0.0.0.0. This is the default gateway. If you go to your NIC configuration and take this entry out and reissue the command. You will find the 0.0.0.0 entry gone.

To get a full explanation on what is in the table, go to:

www.microsoft.com/technet/treeview/defau...mp_routing_table.asp

In essence, the way you look at this table is to say:

To get to the Network Destination, according to the Netmask, you go to the gateway address via the interface and it will take you x hops to get there.

An interesting thing I noticed when playing with setting up the same gateway on 2 network cards on my NT. I got the following table:

[code:1]
C:\WINNT\system32>route print
===========================================================================
Interface List
0x1 ........................... MS TCP Loopback interface
0x2 ...44 45 53 54 42 00 ...... NOC Extranet Access Adapter
0x1000004 ...00 02 b3 5c ec 0a ...... Intel(R) PRO/100+ Management Adapter
===========================================================================
===========================================================================
Active Routes:
Network Destination Netmask Gateway Interface Metric
0.0.0.0 0.0.0.0 192.168.122.1 192.168.122.7 1
0.0.0.0 0.0.0.0 192.168.122.1 192.168.120.7 1
127.0.0.0 255.0.0.0 127.0.0.1 127.0.0.1 1
192.168.122.0 255.255.255.0 192.168.122.7 192.168.122.7 1
192.168.122.7 255.255.255.255 127.0.0.1 127.0.0.1 1
192.168.122.255 255.255.255.255 192.168.122.7 192.168.122.7 1
224.0.0.0 224.0.0.0 192.168.122.7 192.168.122.7 1
255.255.255.255 255.255.255.255 192.168.122.7 2 1
Default Gateway: 192.168.122.1
===========================================================================
Persistent Routes:
None
[/code:1]

You'll notice 2 default gateways (0.0.0.0). If I were to use this table and wanted to go to 66.218.71.86, I would check all the routes and find that I could not get to this destination, using any of the normal routes. This means I would go to the default gateway route.

Whether this would work or not depends on which default gateway the system looks at first. If I were to look at the 1st gateway, it would work fine. The 2nd would not.

I would, in essence, be saying: To get to 66.218.71.86 go to 192.168.122.1 through interface 192.168.120.7. The problem here is that they are on different subnets, so the packet would not get routed correctly. This is why you can only have one default gateway.

Tom.
Thanks,

Tom
The administrator has disabled public write access.

Re: routing table information 13 years 1 month ago #1660

  • sahirh
  • sahirh's Avatar
  • Offline
  • Honored Member
  • Posts: 1700
  • Karma: 0
Basically the routing table is the list of networks that the router knows how to communicate with. It can be filled up automatically using a routing protocol (such as RIP, IGRP, OSPF etc) or by the admin manually configuring routes.

If you want to see an example of a routing table, then do this
Go to a DOS prompt when you're online and type 'route print'. Here's a sample of mine



[code:1]

C:\WINDOWS>route print
===========================================================================
Interface List
0x1 ........................... MS TCP Loopback interface
0x2 ...00 50 56 c0 00 08 ...... VMware Virtual Ethernet Adapter for VMnet8
0x20004 ...00 53 45 00 00 00 ...... WAN (PPP/SLIP) Interface
===========================================================================
===========================================================================
Active Routes:
Network Destination Netmask Gateway Interface Metric
0.0.0.0 0.0.0.0 203.94.231.157 203.94.231.157 1
127.0.0.0 255.0.0.0 127.0.0.1 127.0.0.1 1
169.254.0.0 255.255.0.0 169.254.218.201 169.254.218.201 20
169.254.218.201 255.255.255.255 127.0.0.1 127.0.0.1 20
169.254.255.255 255.255.255.255 169.254.218.201 169.254.218.201 20
203.94.230.147 255.255.255.255 203.94.231.157 203.94.231.157 1
203.94.231.157 255.255.255.255 127.0.0.1 127.0.0.1 50
203.94.231.255 255.255.255.255 203.94.231.157 203.94.231.157 50
224.0.0.0 240.0.0.0 169.254.218.201 169.254.218.201 20
224.0.0.0 240.0.0.0 203.94.231.157 203.94.231.157 1
255.255.255.255 255.255.255.255 169.254.218.201 169.254.218.201 1
Default Gateway: 203.94.231.157
===========================================================================
Persistent Routes:
None[/code:1]

The basic format of any routing table entry is
<destination network> <dest network subnet mask> <next hop to that network>

for example say you needed to reach the 192.168.10.0 network (subnet mask 255.255.255.0) and the next router on the way was 192.168.5.1, then the entry might look like

192.168.10.0 255.255.255.0 192.168.5.1

Ok now question number 2, when you say 'how are IP lookups done ?' I'm assuming you're talking about when you type something like www.hotmail.com how does it get resolved to an IP or vice versa ? This is not based on an algorithm, its done through DNS (Domain Naming Service) which is a protocol and a service.

To explain it VERY simply, there are nameservers that are responsible for keeping the list of names to ips for parts of the internet (called a domain). When you ask for a name, the nameserver that is responsible for that particular domain will give you the reply. Chris has done a very good section on DNS you can find it under
Networking >> Protocols >> DNS
in the top bar of the site.
Sahir Hidayatullah.
Firewall.cx Staff - Associate Editor & Security Advisor
tftfotw.blogspot.com
The administrator has disabled public write access.

Re: routing table information 13 years 1 month ago #1664

  • tfs
  • tfs's Avatar
  • Offline
  • Expert Member
  • Posts: 521
  • Karma: 0
Pretty funny Sahirh. :lol:

I notice that you pressed you submit button a few seconds after I did.
Thanks,

Tom
The administrator has disabled public write access.

Re: routing table information 13 years 1 month ago #1668

  • sahirh
  • sahirh's Avatar
  • Offline
  • Honored Member
  • Posts: 1700
  • Karma: 0
OMG I don't believe this ! I probably clicked it before you, but yours registered first because you have a faster connection ! I don't have the heart to delete my post, you do it !

So now we don't just answer the same questions, we answer them more or less identically -- you stole the ]code[ tags trick from me you.. you.. you.. dirt-biking, systems architecting, forum moderating swine hehe !!

Lol either way, Praveen gets two worthwhile answers.
Sahir Hidayatullah.
Firewall.cx Staff - Associate Editor & Security Advisor
tftfotw.blogspot.com
The administrator has disabled public write access.
  • Page:
  • 1
  • 2
Time to create page: 0.088 seconds

CCENT/CCNA

Cisco Routers

  • SSL WebVPN
  • Securing Routers
  • Policy Based Routing
  • Router on-a-Stick

VPN Security

  • Understand DMVPN
  • GRE/IPSec Configuration
  • Site-to-Site IPSec VPN
  • IPSec Modes

Cisco Help

  • VPN Client Windows 8
  • VPN Client Windows 7
  • CCP Display Problem
  • Cisco Support App.

Windows 2012

  • New Features
  • Licensing
  • Hyper-V / VDI
  • Install Hyper-V

Linux

  • File Permissions
  • Webmin
  • Groups - Users
  • Samba Setup