Dynamic routing (OSPF)

OpenBSD ospfd(8) OSPFv2 router: advertise your networks and learn routes from OSPF neighbours. BGP →

{{#DRIFT_BADGE}}{{#B_UNSAVED}}Unsaved edits{{/B_UNSAVED}}{{#B_DRIFT}}{{B_LABEL}}{{/B_DRIFT}}{{#B_OK}}In sync{{/B_OK}}{{/DRIFT_BADGE}}
{{#ERROR}}
{{ERROR}}
{{/ERROR}} {{#FLASH}}
{{FLASH}}
{{/FLASH}} {{#APPLY_JOB}}
{{APPLY_JOB_TITLE}}
This can take up to a couple of minutes (ospfd -n runs on the router); the page will update when it completes.
{{/APPLY_JOB}} {{#PENDING}}

Confirm OSPF change

A live OSPF change by {{PENDING_ACTOR}} is awaiting confirmation and reverts automatically in {{PENDING_REMAINING}} seconds unless you keep it. If the change severed your own path to this box, simply do nothing — the previous routing configuration restores itself.

{{#PENDING_REVERT_FAILED}}
Automatic revert failed — the routing configuration may be in an inconsistent state. The change keeps retrying in the background; if it persists, resolve it from the console.
{{/PENDING_REVERT_FAILED}} {{#WRITE}} {{/WRITE}}
{{/PENDING}} {{#PENDING_OTHER}}
A confirm window is open on {{PENDING_OTHER_SVC}} — resolve it on that page before applying routing changes.
{{/PENDING_OTHER}} {{#ADOPTION}}

Existing ospfd configuration detected

This router has an ospfd configuration that OgmaProtect does not manage. Applying from this page replaces it with the settings below. The current file is preserved to ospfd.conf.preadopt before the first overwrite, and shown read-only here — it is never imported automatically.

{{#LIVE_PREVIEW_TRUNCATED}}

Preview truncated — the full file is preserved on adoption.

{{/LIVE_PREVIEW_TRUNCATED}}
{{/ADOPTION}}
Configured {{ENABLED_LABEL}} ospfd {{RUNNING_LABEL}}
{{#ENABLED_DRIFT}}

The ospfd service state does not match the configuration — applying re-synchronizes it.

{{/ENABLED_DRIFT}} {{#CONFIG_DRIFT}}

The live /etc/ospfd.conf differs from the saved configuration (hand-edited, or never applied) — applying overwrites it with the settings below.

{{/CONFIG_DRIFT}} {{#DRIFT_PENDING_NOTE}}

A confirm window is open — the live /etc/ospfd.conf intentionally differs from the saved configuration until the change is confirmed or reverted.

{{/DRIFT_PENDING_NOTE}} {{#FWD_OFF_WARN}}

⚠ OSPF is enabled but IPv4 forwarding is off — this router peers and announces routes but will not forward transit traffic. Enable it under Setup → Network tuning.

{{/FWD_OFF_WARN}}

OSPF router

OSPF exchanges routes with neighbouring routers on the interfaces you attach in the Interfaces tab. Most edits reload ospfd without dropping adjacencies; changes to the router ID, authentication keys, redistribute filters, areas, or other global options restart it, briefly resetting adjacencies.

A dotted-quad identifier for this router in the OSPF domain. Leave blank to let ospfd derive one from an interface address.

More settings

The kernel route priority OSPF-learned routes are installed at (fib-priority). Only matters when fib-update is on. Leave blank for the default.

{{#FIB_PRIO_WARN}}

⚠ This priority collides with a well-known route source — 48 is BGP (bgpd), 4 is connected and 8 is static. With both daemons installing routes the kernel's choice is non-deterministic; OgmaProtect refuses an apply where OSPF and an enabled, FIB-updating bgpd both use priority 48.

{{/FIB_PRIO_WARN}}

Tune how quickly ospfd recomputes the shortest-path tree after a topology change (spf-delay / spf-holdtime). Leave blank for the defaults; lower values converge faster but cost more CPU on churn.

Graceful drain (stub router yes) advertises max-metric so neighbours route around this box for transit while it keeps its own routes — for maintenance. A non-default rdomain binds ospfd to that routing table; the OSPF interfaces must already be in it (ifconfig <if> rdomain N), and OSPF routes then install there.

{{#STUB_ROUTER_WARN}}

⚠ Stub-router (drain) is set to yes and is persisted — this box stays drained of transit traffic across reboots until you set it back to default/no. Use it for planned maintenance, not as a steady state.

{{/STUB_ROUTER_WARN}}
{{#ADOPTION}} {{#WRITE}} {{/WRITE}} {{/ADOPTION}} {{#WAN_CONFIRM}} {{/WAN_CONFIRM}} {{#UNAUTH_CONFIRM}} {{/UNAUTH_CONFIRM}} {{#MINIMAL_CONFIRM}} {{/MINIMAL_CONFIRM}} {{#DEMOTE_CONFIRM}} {{/DEMOTE_CONFIRM}} {{#RDOMAIN_CONFIRM}} {{/RDOMAIN_CONFIRM}} {{#WRITE}} {{/WRITE}} {{#WRITE}} {{/WRITE}}

OSPF authentication keys {{KEY_COUNT}}

MD5 (and simple) keys for OSPF interface authentication, held in the secret store. Assign a key to an interface in the Interfaces tab — the value is write-only and is never displayed here or in the rendered config.

{{OSPF_KEY_ROWS}}
{{#AUTH_WRITE}}
 

Stored under an ospf- name. A simple key must be ≤8 characters and an MD5 key ≤16; an over-long key is rejected when you apply OSPF.

{{/AUTH_WRITE}}
Live adjacency event log (ospfd)
Open to stream ospfd events.
TimeSourceProgramMessage

Scoped to the ospfd tag in /var/log/daemon. Apply a change above, then watch neighbour / SPF events here in real time. Requires the log:*:read capability.