To enable OSPF on all Ethernet interfaces, simply create the OSPF configuration object. With no settings it will operate OSPF (unauthenticated) on all Ethernet interfaces as the backbone (0.0.0.0) area.
More complex configurations allow use of OSPF within a specific area, and authentication of OSPFv2 (for IPv4) using a password. It is also possible to configure various system timers to fit in with other devices' configuration, but the defaults will match in most cases.
Most networking configuration settings, e.g. network, static routes, subnets, etc, allow an OSPF setting to be defined which causes the routes for the configuration to be included in OSPF. This is default for many things such as subnets, and means that once you connect to an OSPF network you tell all other devices all of the subnets you have available for routing.
It is however possible to lock down OSPF to work only on some interfaces. You can also make multiple OSPF configurations so that different interfaces have different settings.
The key features supported are:-
<ospf/>
Yes, that is all you need for an unauthenticated OSPF setup working on all Ethernet interfaces and announcing all connected subnets!
Table 18.1. OSPF config attributes
Attribute | Meaning |
area-id | Area ID (default is backbone area 0.0.0.0) |
router-id | Router ID (default is an IP address) |
table | You need different OSPF entries for each routing table. |
interfaces | You can lock a config to specific interfaces - the first matching config is used so you can have multiple configurations for different interfaces and even a final default if you wish. |
priority | Router priority setting - impacts choice of designated router on a network. |
instance | OSPFv3 instance value. |
password | OSPFv2 MD5 based password or simple authentication. |
key-id | OSPFv2 MD5 key-id (or -1 for simple auth instead of MD5). |
localpref | Base localpref for OSPF routes, to which a type 2 external value can be added (up to 16777216). |
spi | The SPI to use for AH/ESP for OSPFv3 authentication |
bgp | If OSPF routes are announced into BGP (and what community tag applies). |
Other settings define timeouts and logging, etc.