The set protocols bgp redistribute command specifies IPv4/IPv6 routes to import into BGP. This command causes routes from the specified protocol to be considered for redistribution into BGP.
The delete protocols bgp redistribute command deletes the routes imported into BGP.
Command Syntax
set protocols bgp [vrf <vrf-name>] {ipv4-unicast|ipv6-unicast} redistribute {connected|kernel|ospf|static|table <table-number>} [metric <metric-number>|route-map <route-map>]
delete protocols bgp [vrf <vrf-name>] {ipv4-unicast|ipv6-unicast} redistribute {connected|kernel|ospf|static|table <table-number>} [metric <metric-number>|route-map <route-map>]
Parameter
Parameter | Description |
vrf <vrf-name> | Optional. Specifies a VRF name. The value is a string. It’s a user-defined VRF set by the command set ip vrf <vrf-name> [description <string>]. |
{ipv4-unicast|ipv6-unicast} | Required. Specifies the IP address family type. |
redistribute {connected|kernel|ospf|ospf6|static|table|table <table-number>} | Redistributes routes to import into BGP.
|
metric <metric-number> | Optional. Specifies route metric of the imported routes into BGP. The value is an integer that ranges from 0 to 4294967295. |
route-map <route-map> | Optional. Specifies the name of the route map. |
Example
• This example redistributes OSPF route to BGP process, and the route metric is set to 20.
admin@XorPlus# set protocols bgp ipv4-unicast redistribute ospf metric 20 admin@XorPlus# commit