A passive OSPF interface remains OSPF-enabled and advertises its network prefix, but does not send hello messages to form neighbor relationships. Use it where no other router connects, such as a user LAN or loopback interface. section 18.2.3
Passive interfaces prevent several unnecessary effects:
- They conserve router CPU and memory and avoid consuming network bandwidth with useless hello messages. section 18.2.3
- They reduce exposure to information-gathering attempts that could inspect unnecessary OSPF messages. section 18.2.3
- They do not suppress the interface prefix from OSPF advertisements, so neighbors can still route packets to that network. section 18.2.3
Configure selected interfaces
R3(config)# router ospf 1 R3(config-router)# passive-interface g0/1 R3(config-router)# passive-interface l0 This makes G0/1 and Loopback0 passive. To verify the result, use do show ip protocols and check the Passive Interface(s) list.
Make interfaces passive by default
R2(config)# router ospf 1 R2(config-router)# passive-interface default R2(config-router)# no passive-interface g0/0 R2(config-router)# no passive-interface g0/1 This leaves Loopback0 passive while explicitly allowing OSPF neighbor formation on G0/0 and G0/1.
