{"id":624,"date":"2020-11-23T19:32:50","date_gmt":"2020-11-23T19:32:50","guid":{"rendered":"https:\/\/dft.wiki\/?p=624"},"modified":"2026-06-09T13:26:52","modified_gmt":"2026-06-09T17:26:52","slug":"load-balancing-and-failover-on-pfsense","status":"publish","type":"post","link":"https:\/\/dft.wiki\/?p=624","title":{"rendered":"Load Balancing and Failover on pfSense"},"content":{"rendered":"<p>For load balancing and\/or failover, a minimum of 3 interfaces is required: one for LAN and two for WAN.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1622\" src=\"https:\/\/dft.wiki\/wp-content\/uploads\/sites\/15\/2020\/11\/Screenshot-from-2021-03-26-14-05-36.png\" alt=\"\" width=\"725\" height=\"138\" srcset=\"https:\/\/dft.wiki\/wp-content\/uploads\/sites\/15\/2020\/11\/Screenshot-from-2021-03-26-14-05-36.png 725w, https:\/\/dft.wiki\/wp-content\/uploads\/sites\/15\/2020\/11\/Screenshot-from-2021-03-26-14-05-36-300x57.png 300w\" sizes=\"auto, (max-width: 725px) 100vw, 725px\" \/><\/p>\n<p>On <strong>Interfaces &gt; Interface Assignments<\/strong>, all interfaces must be added:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1623\" src=\"https:\/\/dft.wiki\/wp-content\/uploads\/sites\/15\/2020\/11\/Screenshot-from-2021-03-26-14-03-02.png\" alt=\"\" width=\"737\" height=\"363\" srcset=\"https:\/\/dft.wiki\/wp-content\/uploads\/sites\/15\/2020\/11\/Screenshot-from-2021-03-26-14-03-02.png 737w, https:\/\/dft.wiki\/wp-content\/uploads\/sites\/15\/2020\/11\/Screenshot-from-2021-03-26-14-03-02-300x148.png 300w\" sizes=\"auto, (max-width: 737px) 100vw, 737px\" \/><\/p>\n<p>Each interface also needs basic configuration and a meaningful name:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1624\" src=\"https:\/\/dft.wiki\/wp-content\/uploads\/sites\/15\/2020\/11\/Screenshot-from-2021-03-26-14-02-13.png\" alt=\"\" width=\"739\" height=\"418\" srcset=\"https:\/\/dft.wiki\/wp-content\/uploads\/sites\/15\/2020\/11\/Screenshot-from-2021-03-26-14-02-13.png 739w, https:\/\/dft.wiki\/wp-content\/uploads\/sites\/15\/2020\/11\/Screenshot-from-2021-03-26-14-02-13-300x170.png 300w\" sizes=\"auto, (max-width: 739px) 100vw, 739px\" \/><\/p>\n<p>Note that the monitored IP matches the gateway for each interface. This means that if the link between pfSense and the gateway goes down, traffic will fail over to the other interface.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1626\" src=\"https:\/\/dft.wiki\/wp-content\/uploads\/sites\/15\/2020\/11\/Screenshot-from-2021-03-26-14-14-26.png\" alt=\"\" width=\"730\" height=\"366\" srcset=\"https:\/\/dft.wiki\/wp-content\/uploads\/sites\/15\/2020\/11\/Screenshot-from-2021-03-26-14-14-26.png 730w, https:\/\/dft.wiki\/wp-content\/uploads\/sites\/15\/2020\/11\/Screenshot-from-2021-03-26-14-14-26-300x150.png 300w\" sizes=\"auto, (max-width: 730px) 100vw, 730px\" \/><\/p>\n<p>There is also a scenario where the ISP router is reachable but has no internet connectivity on its WAN side. For that case, an external host can be set as the monitor IP, for example 8.8.8.8 or 8.8.4.4. Leave this for now.<\/p>\n<p>Go to <strong>System &gt; Routing &gt; Gateway Groups<\/strong> and click &#8220;+ Add&#8221; to group both gateways together.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1625\" src=\"https:\/\/dft.wiki\/wp-content\/uploads\/sites\/15\/2020\/11\/Screenshot-from-2021-03-26-14-21-03.png\" alt=\"\" width=\"728\" height=\"635\" srcset=\"https:\/\/dft.wiki\/wp-content\/uploads\/sites\/15\/2020\/11\/Screenshot-from-2021-03-26-14-21-03.png 728w, https:\/\/dft.wiki\/wp-content\/uploads\/sites\/15\/2020\/11\/Screenshot-from-2021-03-26-14-21-03-300x262.png 300w\" sizes=\"auto, (max-width: 728px) 100vw, 728px\" \/><\/p>\n<ul>\n<li>Give the group a meaningful name and description. Most importantly, define the priority and trigger level for each gateway.<\/li>\n<li>Assigning the same priority to both gateways enables load balancing.<\/li>\n<li>If one WAN connection is metered and should only be used as a backup, assign it a lower priority.<\/li>\n<li>The &#8220;Packet Loss&#8221; and &#8220;High Latency&#8221; trigger levels monitor traffic flowing through the interface and will temporarily remove it from the group if it is not performing normally.<\/li>\n<\/ul>\n<p>Remember to apply all changes.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1627\" src=\"https:\/\/dft.wiki\/wp-content\/uploads\/sites\/15\/2020\/11\/Screenshot-from-2021-03-26-14-27-11.png\" alt=\"\" width=\"730\" height=\"357\" srcset=\"https:\/\/dft.wiki\/wp-content\/uploads\/sites\/15\/2020\/11\/Screenshot-from-2021-03-26-14-27-11.png 730w, https:\/\/dft.wiki\/wp-content\/uploads\/sites\/15\/2020\/11\/Screenshot-from-2021-03-26-14-27-11-300x147.png 300w\" sizes=\"auto, (max-width: 730px) 100vw, 730px\" \/><\/p>\n<p>Done!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>For load balancing and\/or failover, a minimum of 3 interfaces is required: one for LAN [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[8],"tags":[],"class_list":["post-624","post","type-post","status-publish","format-standard","hentry","category-pfsense"],"_links":{"self":[{"href":"https:\/\/dft.wiki\/index.php?rest_route=\/wp\/v2\/posts\/624","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/dft.wiki\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/dft.wiki\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/dft.wiki\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/dft.wiki\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=624"}],"version-history":[{"count":3,"href":"https:\/\/dft.wiki\/index.php?rest_route=\/wp\/v2\/posts\/624\/revisions"}],"predecessor-version":[{"id":5809,"href":"https:\/\/dft.wiki\/index.php?rest_route=\/wp\/v2\/posts\/624\/revisions\/5809"}],"wp:attachment":[{"href":"https:\/\/dft.wiki\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=624"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/dft.wiki\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=624"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/dft.wiki\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=624"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}