Richard's recipe for OSPF on gated




This recipe is simple. In this example, all the OSPF routers are on a single "backbone" network, 192.168.0.x

The OSPF key is "dumbsecret".

The primary interface is 192.168.0.12 We could use the interface name (like ed0, eth0, lan0, le0, etc.), but we run into trouble if there are alias addresses on the interface. This is common when you have virtual domain services on the machine.

The routerid is the address you want to use to identify this router when it communicates with other OSPF routers. If you do not specify one, gated will pick the address of one of your interfaces - probably not the address you would have picked...

The priority is set to one here. When OSPF routers connect, they negotiate a "DR" (designated router) and "BDR" (backup designated router). The ones with the highest priority win. I suggest using the same number for all routers.
interfaces {
	interface 192.168.0.12;
} ;
routerid 192.168.0.12;
rip no;
hello no;
ospf yes {
	backbone {
		authtype simple ;
		interface 192.168.0.12 {
			priority 1 ;
			authkey "dumbsecret";
		} ;
	} ;
} ;


Note the semicolon after everything, including the end braces.
Are you looking into using a Linux or BSD box as a router? Quagga is routing protocol software that looks and acts like Cisco IOS, but runs on your favorite operating system and is free.
More info here: Quagga Project (new branch of old Zebra project)