<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>https://wiki.kitz.co.uk/index.php?action=history&amp;feed=atom&amp;title=Servicecyclev4_patch281</id>
		<title>Servicecyclev4 patch281 - Revision history</title>
		<link rel="self" type="application/atom+xml" href="https://wiki.kitz.co.uk/index.php?action=history&amp;feed=atom&amp;title=Servicecyclev4_patch281"/>
		<link rel="alternate" type="text/html" href="https://wiki.kitz.co.uk/index.php?title=Servicecyclev4_patch281&amp;action=history"/>
		<updated>2026-06-15T21:50:56Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.29.0</generator>

	<entry>
		<id>https://wiki.kitz.co.uk/index.php?title=Servicecyclev4_patch281&amp;diff=901&amp;oldid=prev</id>
		<title>Chrysalis: Created page with &quot;Default behaviour on pfSense is to cycle all services if any configured gateways go offline, this can include VPN's and tunnels not just broadband connectivity.  This can caus...&quot;</title>
		<link rel="alternate" type="text/html" href="https://wiki.kitz.co.uk/index.php?title=Servicecyclev4_patch281&amp;diff=901&amp;oldid=prev"/>
				<updated>2025-09-21T21:03:11Z</updated>
		
		<summary type="html">&lt;p&gt;Created page with &amp;quot;Default behaviour on pfSense is to cycle all services if any configured gateways go offline, this can include VPN&amp;#039;s and tunnels not just broadband connectivity.  This can caus...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;Default behaviour on pfSense is to cycle all services if any configured gateways go offline, this can include VPN's and tunnels not just broadband connectivity.&lt;br /&gt;
&lt;br /&gt;
This can cause problems e.g. if your pfSense is hosting LAN services such as a NTP server or UPS daemon.  Consider a scenario e.g. if you have a power cut, your WAN goes offline, pfSense then puts services into a cycle loop, which in turn drops connectivity to the UPS daemon so client machines are unaware of power status and battery level which might prevent automated safe shutdown/hibernation.&lt;br /&gt;
&lt;br /&gt;
This patch changes the behaviour so services will only get cycled if a external non OpenVPN interface comes back online with a different IP address, if its a cycle keeping the existing IP, then it will not cycle all services.&lt;br /&gt;
&lt;br /&gt;
This is the IPv4 version of the patch, there is also a IPv6 version.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Paste the below code into the ''Patch Contents'' box.&lt;br /&gt;
&lt;br /&gt;
Add a description such as 'Better diagnostics limiters layout' in the ''Description'' box.&lt;br /&gt;
&lt;br /&gt;
Set ''Path Strip Count'' to '0'.&lt;br /&gt;
&lt;br /&gt;
''Base Directory'' to '/'.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;--- /etc/rc.newwanip    2023-06-28 04:51:31.000000000 +0100&lt;br /&gt;
+++ /etc/rc.newwanip   2023-07-22 00:12:33.150672000 +0100&lt;br /&gt;
@@ -41,9 +41,13 @@&lt;br /&gt;
 function restart_packages() {&lt;br /&gt;
        global $oldip, $curwanip, $g;&lt;br /&gt;
 &lt;br /&gt;
-       /* restart packages */&lt;br /&gt;
-       log_error(&amp;quot;{$g['product_label']} package system has detected an IP change or dynamic WAN reconnection - $oldip -&amp;gt;  $curwanip - Restarting packages.&amp;quot;);&lt;br /&gt;
-       send_event(&amp;quot;service reload packages&amp;quot;);&lt;br /&gt;
+       if (substr($interface_real, 0, 4) != &amp;quot;ovpn&amp;quot;) {&lt;br /&gt;
+               if ($curwanip != $oldip) {&lt;br /&gt;
+                       /* restart packages */&lt;br /&gt;
+                       log_error(&amp;quot;{$g['product_label']} package system has detected an IP change or dynamic WAN reconnection - $oldip -&amp;gt;  $curwanip - Restarting packages.&amp;quot;);&lt;br /&gt;
+                       send_event(&amp;quot;service reload packages&amp;quot;);&lt;br /&gt;
+               }&lt;br /&gt;
+       }&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 /* Interface IP address has changed */&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Pfsense Patches]]&lt;/div&gt;</summary>
		<author><name>Chrysalis</name></author>	</entry>

	</feed>