I am reading a document:
The default gateway generally refers to the 0.0.0.0/0 route, which is used when there is no clear routing entry to a destination address.
How to understand this sentence?
Network Engineering Stack Exchange is a question and answer site for network engineers. It only takes a minute to sign up.Sign up to join this community
All IPv4 networks are subnets of the
0.0.0.0/0 network, so in a routing table that network matches any IPv4 network, making it a default network.
If the destination address on a packet does not match any network in a routing table, the router will simply drop the packet. A route pointing to
0.0.0.0/0 matches the network of any destination address. Such an entry in the routing table can be used so that no packets get dropped because any packet with a destination address not matching any other routing table entry will be sent toward the next hop of the
0.0.0.0/0 routing table entry, rather than being dropped.
The "default gateway" or "default route" is a route of last resort. 0.0.0.0/0 matches every possible IPv4 address, but it also has the shortest possible prefix, so following the "longest prefix match" rules it will only be used if no more-specific route matches.
This allows you to have a much smaller routing table, rather than having routes for every network on the internet (750K or so nowadays) you just have routes for your downstream network and then a default route that essentially says "the internet is this way".
Of course there are some routers where it is nessacery or desirble to have a routing table for the full Internet, but generally such routers are a minority.
The default gateway generally refers to the 0.0.0.0/0 route, which is used when there is no clear routing entry to a destination address
As per above sentences ! Default route is configured as when packets wants to reach unknown destination this default route is configured . Generally in real time default route is mostly configured to route internet traffic . When users wants to acces resources on internet with domains . Users it's might don't know which IP address it's resolve to what is destination ip address in this case traffic is routed towards ISP with default route configured in perimeter device.