Perimeter Engineering // Open Source Firewalls

Enterprise Firewall Engineering: High Availability CARP & Migration Realities

Published by Senior Systems Engineering · Axionix Systems

Both pfSense and OPNsense are mature, FreeBSD-based enterprise firewall solutions powering critical network edges worldwide. Whether an engineering team chooses to optimize an existing pfSense installation or migrate to OPNsense, production success hinges on understanding the realities of High Availability (CARP), configuration parsing, and state table behavior.

The Myth of the "1-Click" pfSense to OPNsense Migration

While both operating systems trace their lineage to m0n0wall, their codebase schemas have diverged substantially over the past decade:

  • Direct XML Restores Will Fail: Attempting to upload a pfSense config.xml into an OPNsense firewall will corrupt internal configuration hashes and trigger boot failures.
  • What Can Be Automated: High-volume objects like Firewall Aliases (IPs, CIDRs, ports) and Static DHCP Mappings can be parsed using Python or xmllint scripts and formatted cleanly into OPNsense XML structures.
  • What Must Be Re-Architected: NAT rules, complex outbound floating rules, CARP virtual IPs, and VPN interfaces (WireGuard/IPsec) should be audited and entered natively through the UI or validated API calls.

Architecting Resilient CARP High Availability Clusters

High Availability via CARP (Common Address Redundancy Protocol) ensures seamless failover between a Primary (MASTER) and Secondary (BACKUP) node:

  1. Dedicated pfsync Sync Link: Never share state synchronization traffic across general LAN interfaces. Configure a direct, dedicated physical or isolated VLAN link between node interfaces solely for pfsync and XML-RPC configuration synchronization.
  2. Skew Calibration: Assign advskew 0 to the primary node and advskew 100 to the secondary node across all virtual IPs to guarantee predictable mastership.
  3. State Table Cutover Reality: When performing a live cutover from pfSense to OPNsense hardware, existing state tables cannot sync across different operating system releases. Schedule a targeted cutover maintenance window to account for brief connection resets as new state tables populate.

Modern Interconnects: WireGuard, Tailscale, NetBird & ZeroTier

Traditional IPsec and OpenVPN configurations often suffer from brittle NAT traversal, complex key rotation, and excessive CPU overhead. Modern perimeter engineering integrates lightweight cryptographic mesh overlays:

  • Native WireGuard: Ideal for high-throughput, static site-to-site tunnels between headquarters, branches, and cloud transit hubs directly configured within pfSense or OPNsense.
  • Tailscale & NetBird Overlays: Built on WireGuard but featuring centralized zero-trust coordination servers and NAT-traversing DERP/STUN relays. Perfect for multi-cloud mesh networks, remote contractor access, and dynamic server-to-server interconnects without opening exposed inbound firewall ports.
  • ZeroTier Virtual Ethernet: Operates at Layer 2, making it an excellent choice for legacy protocols requiring broadcast domains or bridging disparate subnets without full router reconfigurations.

Our Dual-Platform Consulting Model

Axionix Systems does not mandate platform abandonment:

  • Staying on pfSense: We assist organizations with CARP cluster tuning, multi-WAN failover, Suricata IPS rule hardening, and cross-site WireGuard encrypted meshes.
  • Migrating to OPNsense: For organizations seeking OPNsense's modular architecture, automated core updates, and rich REST API, we stage new hardware out-of-band and execute seamless production cutovers.

Planning a Firewall Audit or High-Availability Overhaul?

Book a technical consultation with an enterprise network architect to review your topology and failover resilience.

Schedule Network Review