neighbour default-originate
Enables a BGP router to forward the default route 0.0.0.0 to a BGP neighbor.
​
Syntax: neighbor {ip-address | peer-group-name} default-originate
ip-address IP address of a BGP neighbor to which this router sends the default route.
peer-group-name Name of a BGP peer group to whose members this router sends the default route.
(Use the show ip bgp peer-group command to display the names of defined peer groups.)
Description: The network address 0.0.0.0 is used when no other routes are available. By default, you are not allowed to redistribute network 0.0.0.0. The neighbor default-originate command enables the local router to send the default route 0.0.0.0 to a neighbor. The neighbor can then use this route to reach the router if all other routes are not available.
​
You do not need to explicitly configure network 0.0.0.0 on the router.
When used in conjunction with a route map, the default route 0.0.0.0 is injected if two condition are met:
​
-
The route map includes a match ip address clause
-
There is a route that matches the IP access list exactly
Use the neighbor default-originate command to forward the default route 0.0.0.0 to a neighbor.
​
Use the no neighbor default-originate command to delete the default route.
​
Factory Default: No default route forwarded to the neighbor.
​
Command Mode: Router configuration.
​
Example 1: In the following example, the neighbor default-originate command enables the router to advertise the default route 0.0.0.0 to neighbor 10.5.1.121, and the show ip bgp neighbor command displays the setting:
router(config)#router bgp 110
router(config-router)#network 10.5.0.0
router(config-router)#neighbor 10.5.1.190 remote-as 120
router(config-router)#neighbor 10.5.1.190 default-originate
router(config-router)#end
router#show ip bgp neighbor 10.5.1.190
BGP neighbor 10.5.1.190 using remote AS 110
router ID: 0.0.0.0 version: 4
state: Connect time: 0:00:00
def orignat: True ebgp multihop: False
Example 2: In the following example
​
-
The access-list command creates an access list named ISP3_Net120 that permits only routes to 120.12.3.0.
-
The route-map command creates a route-map named DEFAULT that permits routes that match the IP addresses in access list ISP3_Net120.
-
The neighbor remote-as command configures an external neighbor 10.5.1.190.
-
The neighbor default-originate command applies the route map DEFAULT to route updates to and from neighbor 10.5.1.121. The router injects the default route to neighbor 10.5.1.121 only if there is a route to 120.12.3.0:
router(config)#access-list ISP3_Net120 permit 120.12.3.0
router(config)#route-map DEFAULT 10 permit
router(config-route-map)#match ip address ISP3_Net120
router(config)#router bgp 110
router(config-router)#network 10.5.0.0
router(config-router)#neighbor 10.5.1.190 remote-as 120
router(config-router)#neighbor 10.5.1.190 default-originate route-map DEFAULT