A default route is a static route that matches all packets. Instead of routers storing routes for all of the networks in the Internet, they can store a single default route to represent any network that is not in the routing table.
Routers commonly use default routes that are either configured locally or learned from another router, using a dynamic routing protocol. They are used when no other routes match the packet's destination IP address in the routing table. In other words, if a more specific match does not exist, then use the default route as the Gateway of Last Resort.
Default static routes are commonly used when connecting:
- A company's edge router to a service provider network.
- A router with only an upstream neighbor router. The router has no other neighbors and is, therefore, referred to as a stub router.
As shown in the figure, the command syntax for a default static route is similar to any other static route, except that the ipv6-prefix/prefix-length is ::/0, which matches all routes.
The basic command syntax of a default static route is:
- ipv6 route ::/0 { ipv6-address | exit-intf }