Project

General

Profile

Bug #11142

rc.newwanip restarts VPN services when the IP matches

Added by Viktor Gurov 4 months ago. Updated 3 months ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
Interfaces
Target version:
Start date:
12/08/2020
Due date:
% Done:

100%

Estimated time:
Affected Version:
2.4.5-p1
Affected Architecture:
Release Notes:
Default

Description

If DHCP on WAN interface receives the same IP, rc.newwanip restarts all services:
https://github.com/pfsense/pfsense/blob/186ef8568345d216688e56e06ba08e02c44b1711/src/etc/rc.newwanip#L229

rc.newwanipv6 in more correct in this case and restarts VPN services only if WAN is PPP interface:
https://github.com/pfsense/pfsense/blob/186ef8568345d216688e56e06ba08e02c44b1711/src/etc/rc.newwanipv6#L156

Associated revisions

Revision 27f89b06 (diff)
Added by Viktor Gurov 4 months ago

Do not run rc.newwanip if received DHCP address has not changed. Fixes #11142

History

#2 Updated by Renato Botelho 4 months ago

  • Status changed from New to Feedback
  • Assignee set to Viktor Gurov
  • Target version set to 2.5.0

PR has been merged. Thanks!

#3 Updated by Viktor Gurov 4 months ago

  • % Done changed from 0 to 100

#4 Updated by Danilo Zrenjanin 4 months ago

Tested on:

2.5.0-DEVELOPMENT (amd64)
built on Thu Dec 10 03:02:47 EST 2020
FreeBSD 12.2-STABLE

It doesn't restart services anymore if the IP address stays the same after DHCP renewal, that's fine.

However, it still restarts services if you make any change at the WAN interface, no matter if you didn't change the IP address(even if you just hit apply at the wan interface without changes). Maybe there is room for improvement too.

#5 Updated by Alhusein Zawi 3 months ago

Danilo Zrenjanin wrote:

Tested on:
[...]

It doesn't restart services anymore if the IP address stays the same after DHCP renewal, that's fine.

However, it still restarts services if you make any change at the WAN interface, no matter if you didn't change the IP address(even if you just hit apply at the wan interface without changes). Maybe there is room for improvement too.

ipsec tunnel will be restarted if you hit apply at any interface. (log file shows Restarting ipsec tunnels)
applied the same steps on 2.4.5-p1 and it shows same results .
log file shows "Restarting ipsec tunnels" , ipsec tunnel in status>Ipsec is not interrupted.

#6 Updated by Viktor Gurov 3 months ago

  • Status changed from Feedback to Resolved

Alhusein Zawi wrote:

Danilo Zrenjanin wrote:

ipsec tunnel will be restarted if you hit apply at any interface. (log file shows Restarting ipsec tunnels)
applied the same steps on 2.4.5-p1 and it shows same results .
log file shows "Restarting ipsec tunnels" , ipsec tunnel in status>Ipsec is not interrupted.

This is another issue, please create a ticket
Original issue is resolved

Also available in: Atom PDF