Step 12. Configure an interface as Passive¶
Goals¶
The goal of this step is to demonstrate the Passive interface mode in OSPF.
A passive interface in OSPF is one that:
Does NOT send or receive Hello packets (no adjacencies are formed)
IS advertised in Router LSAs (the network is visible to OSPF)
Passive mode is useful for stub networks (networks with only hosts, no other OSPF routers). It reduces OSPF overhead by not running the protocol where it’s unnecessary, while still advertising the network so it’s reachable from other parts of the OSPF domain.
Configuration¶
This configuration is based on Step 3. One of the router’s interfaces is configured with
interfaceMode="Passive".
The configuration in omnetpp.ini is the following:
[Config Step12]
description = "Configure an interface as Passive"
extends = Step3
*.R*.ospf.ospfConfig = xmldoc("ASConfig_Passive.xml")
The OSPF configuration:
<?xml version="1.0"?>
<OSPFASConfig xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="OSPF.xsd">
<!-- Routers -->
<Router name="R1" RFC1583Compatible="true">
<BroadcastInterface ifName="eth0" interfaceMode="Passive" />
<PointToPointInterface ifName="ppp0" />
</Router>
<Router name="R2" RFC1583Compatible="true">
<BroadcastInterface ifName="eth0" interfaceMode="Passive" />
<PointToPointInterface ifName="ppp0" />
</Router>
</OSPFASConfig>
Results¶
With the interface configured as Passive:
No OSPF Hello packets are sent on the interface.
No OSPF adjacencies can form on this interface.
However, the network is still advertised in the router’s Router LSA as a stub network.
Other OSPF routers learn about this network and can route to it.
Hosts on the passive network can communicate with the rest of the OSPF domain.
Passive mode is commonly used on interfaces connected to end-user networks or networks where no other OSPF routers are expected, reducing unnecessary protocol overhead.
Sources:
omnetpp.ini,
Network.ned,
ASConfig_Passive.xml
Discussion¶
Use this page in the GitHub issue tracker for commenting on this tutorial.