0

On my router I'm having a following static routing configuration:

ID Destination Subnet Gateway Interface
1 0.0.0.0 0.0.0.0 <3-octet base>.1 wan
2 <3-octet-base>.0 255.255.255.0 0.0.0.0 wan
3 192.168.1.0 255.255.255.0 0.0.0.0 lan

I'd love to understand justification of each of those entries, considering:

  • my router IP is set to 192.168.1.1
  • my ISP provider Gateway is set to <3-octet-base>.1
  • my dynamic IP is assigned to one of <3-octet-base>.0/24 pole

Please correct my understanding, but do I get this correctly:

ID 1 is example of "catch-all", so if any IP from any range is send, pass it to <3-octet base>.1, what would be my ISP next hop gateway

ID 2 is to pass all inner-ISP sub-network <3-octet base>.0/24 to direct IP address, omitting gateway (thus gateway address is zeroed)

ID 3 is to pass all my inner-home network adresses to directly communicate with each other without usage of my network gateway (router in this case) (thus gateway address is zeroed)

And next question is, does all those entries are mandatory? Will the routing with/without them will be more/less efficient?

And extra question to entry no. 3, isn't that the case, that if all devices are using correct subnet mask, then this entry is completely useless, as inner-network communication always happens without gateway?

Many thanks in advance for your advanced knowledge!

Tomas
  • 101
  • 1
  • re. that last part, if route 3 didn't exist, what would happen when this router tried to communicate with one of the hosts in 192.168.1.0/24, that is, with your LAN devices? Where would it direct the traffic? (Note that that's the routing table of your router, not that of your devices within the LAN) – ilkkachu Oct 09 '23 at 05:59
  • @ilkkachu I'd assume that in compliance to OSI model, if device lives in same subnet (it does) then by default communication goes on without gateway interaction. In worst case, would land on default gateway for LAN network communication (router itself) and yet again frwarded directly to LAN device. Thus last entry have no sense for me, as effect is exactly same with or w/o it – Tomas Oct 09 '23 at 07:50
  • Mmm, ok, you're assuming that the information that last route entry contains is also contained somewhere else. Which would perhaps make that route redundant, but would also mean that doing the routing decision would require looking at two places, which seems rather less straightforward. You could try and see what happens if you remove that route entry. – ilkkachu Oct 09 '23 at 08:06

0 Answers0