Programmable Internetworking & Communication Operating System Docs ... Click Spaces -> Space Directory to see docs for all releases ...
Page tree
Skip to end of metadata
Go to start of metadata

BGP cannot discover routes and needs to import routes such as IGP routes into BGP routing tables so that the imported routes can be transmitted within an AS or between ASs. BGP imports routes in either redistribute or network mode.

Redistribute Mode

In redistribute mode, BGP imports IGP routes, including RIP, OSPF, and IS-IS routes, into BGP routing tables based on protocol type. To ensure the validity of imported IGP routes, BGP can also import static routes and direct routes in redistribute mode.

Use the following command to configure to import BGP route:

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>]

Network Mode

In network mode, BGP imports the routes in the IP routing table one by one to BGP routing tables. The network mode is more accurate than the redistribute mode. The ORIGIN attribute of BGP routes advertised in this way is IGP.

Use the following commands to configure BGP to statically add routes in the IP routing table to the BGP routing table and advertise these routes to peers.

Apply the specified route policy or a route label to control network advertisements with the following command:

set protocols bgp [vrf <vrf-name> {ipv4-unicast|ipv6-unicast} network <ipv4/prefixlen> [label-index<label-index>|route-map <ROUTE-MAP-NAME>]

The network mode command is used to import exactly-matching routes. The mask length as configured in the network statement must match the mask length of prefixes in the routing table. This means that the specified network must be available and active in the local IP routing table.

  • No labels