[zebra]ospfdを使う

FreeBSDでの注意
OSPFはマルチキャストを使用しているが、FreeBSD上ではそのルーティングテーブルがなく、そのままでは Hello パケットが出ない。
この現象は、必要なマルチキャストアドレスに対して事前にスタティックルートを切っておくことで解決する。
 # route add 224.0.0.5 -interface lo0
 # route add 224.0.0.6 -interface lo0
コンフィグレーション例 [zebra-0.91a]
! hostname test1-ospfd password 8 xxxxxxxxx enable password 8 xxxxxxxxx service password-encryption ! ! interface vr0 description lan2 ip ospf cost 10 ! interface fxp0 description lan1 ip ospf cost 10 ! router ospf ospf router-id 10.1.20.1 redistribute connected redistribute static network 172.16.0.0/29 area 11 network 172.17.0.0/29 area 11 ! access-list 1 permit 127.0.0.1/32 ! ipv6 access-list login permit ::1/128 ! line vty access-class 1 ipv6 access-class 1 ! end
確認例
test1-ospfd> sh ip ospf int vr0 is down, line protocol is down OSPF not enabled on this interface fxp0 is up, line protocol is up Internet Address 172.17.0.3/29, Area 0.0.0.11 Router ID 10.1.20.1, Network Type BROADCAST, Cost: 10 Transmit Delay is 1 sec, State DR, Priority 1 Designated Router (ID) 10.1.20.1, Interface Address 172.17.0.3 Backup Designated Router (ID) 10.1.20.2, Interface Address 172.17.0.4 Timer intarvals configured, Hello 10, Dead 40, Wait 40, Retransmit 5 Hello due in 00:00:06 Neighbor Count is 3, Adjacent neighbor count is 3 lo0 is up, line protocol is up OSPF not enabled on this interface test1-ospfd> sh ip ospf neighbor Neighbor ID Pri State Dead Time Address Interface RXmtL RqstL DBsmL 10.1.2.1 1 Full/DROther 00:00:35 172.17.0.1 fxp0 0 0 0 10.1.2.2 1 Full/DROther 00:00:33 172.17.0.2 fxp0 0 0 0 10.1.20.2 1 Full/Backup 00:00:38 172.17.0.4 fxp0 0 0 0 test1-ospfd> sh ip ospf route ============ OSPF network routing table ============ N IA 192.168.10.0/30 [16] area: 0.0.0.11 via 172.17.0.1, fxp0 (略)

もどる