[Prev][Next][Report an Error]

Injecting OSPF Routes into the BGP Routing Table (Optional)

You can specify a match condition for policies based on protocols by naming a protocol from which the route is learned or to which the route is being advertised. You can specify one of the following protocols: aggregate, BGP, direct, DVMRP, IS-IS, local, OSPF, PIM-dense, PIM-sparse, RIP, or static

For example, you can inject or redistribute OSPF routes into the BGP routing table by creating a routing policy.

To create a routing policy named injectpolicy1 that redistributes OSPF routes from Area 1 only into BGP and does not advertise routes learned by BGP:

  1. Navigate to the top of the configuration hierarchy in either the J-Web or CLI configuration editor.
  2. Perform the configuration tasks described in Table 115.
  3. If you are finished configuring the router, commit the configuration.
  4. To configure additional routing policy features, go on to one of the following procedures:

Table 115: Creating a Policy to Inject OSPF Routes into BGP


J-Web Configuration Editor

CLI Configuration Editor

Navigate to the Policy statement level in the configuration hierarchy.

  1. In the J-Web interface, select Configure>CLI Tools>Point and Click CLI.
  2. Next to Policy options, click Configure or Edit.
  3. Next to Policy statement, click Add new entry.

From the [edit] hierarchy level, enter

edit policy-options policy-statement

Create an injection policy and term—for example, injectpolicy1 and injectterm1.

  1. In the Policy name box, type injectpolicy1.
  2. Next to Term, click Add new entry.
  3. In the Term name box, type injectterm1.


set injectpolicy1 term injectterm1

Specify the OSPF routes.

  1. In the From option, click Configure.
  2. In the Protocol box, click Add new entry.
  3. In the Value drop box, select ospf.
  4. Click OK.

Specify the OSPF match condition:

set from ospf

Specify the routes from a particular OSPF area—for example, Area 1.

  1. In the Area box, type 1.
  2. Click OK.

Specify Area 1 as a match condition:

set from area 1

Specify that the route is to be accepted if the previous conditions are matched.

Set the default option to reject other OSPF routes.

  1. Next to Then, click Configure.
  2. From the Accept reject list, Select accept.
  3. From the Default action list, Select reject.
  4. Click OK until you return to the main Configuration page.

Specify the action to accept:

set then accept

Navigate to the Bgp level in the configuration hierarchy.

  1. On the main Configuration page next to Protocols, click Configure or Edit.
  2. Next to Bgp, click Configure or Edit.

From the [edit] hierarchy level, enter

edit protocols bgp

Apply the routing policy injectpolicy1 to BGP.

  1. Next to Export, click Add new entry.
  2. In the Value option, type injectpolicy1.
  3. Click OK.

Specify the OSPF match condition:

set export injectpolicy1

[Prev][Next][Report an Error]