1
20.7 Legacy Series / reproducable: gateway shown offline, rc.newwanip ROUTING not coming up
« on: August 24, 2020, 10:30:25 am »
Hi,
we have reproducable issues with the gateway shown as offline, after disconnecting the WAN interface more than once within 3 seconds. The issue is reproducable on in multiple production environments.
Versions OPNsense 20.7.1-amd64
FreeBSD 12.1-RELEASE-p8-HBSD
OpenSSL 1.1.1g 21 Apr 2020
Scenario:
1. OPNsense has WAN interface connected properly to Router, LAN interface connected to switch, routing works properly including internet access etc.
2. physically unplug WAN interface for 1sec, then reattach, wait 3sec, unplug again for 1sec, then reattach
expected behaviour:
WAN interface goes offline, after some seconds if goes online again
observed behaviour:
WAN interface goes offline, stays offline forever.
Analysis of the Logfiles in System > Logfiles > General shows these lines:
What is interesting here: The script /usr/local/etc/rc.newwanip is not executing the ROUTING subroutine. Normally, we should see these lines in the logfiles are well, be they are missing completely:
We have tried various settings from the GUI in order to get a stable behaviour including gateway monitoring etc. No configuration setting provided a valuable workaround.
known workaround:
reboot, or make a change in the configuration so that ROUTING setup routine gets executed.
Any idea, any fix?
we have reproducable issues with the gateway shown as offline, after disconnecting the WAN interface more than once within 3 seconds. The issue is reproducable on in multiple production environments.
Versions OPNsense 20.7.1-amd64
FreeBSD 12.1-RELEASE-p8-HBSD
OpenSSL 1.1.1g 21 Apr 2020
Scenario:
1. OPNsense has WAN interface connected properly to Router, LAN interface connected to switch, routing works properly including internet access etc.
2. physically unplug WAN interface for 1sec, then reattach, wait 3sec, unplug again for 1sec, then reattach
expected behaviour:
WAN interface goes offline, after some seconds if goes online again
observed behaviour:
WAN interface goes offline, stays offline forever.
Analysis of the Logfiles in System > Logfiles > General shows these lines:
Code: [Select]
2020-08-22T10:57:15 opnsense[17197] plugins_configure newwanip (execute task : webgui_configure_do(,wan))
2020-08-22T11:00:50 kernel igb0: link state changed to DOWN
2020-08-22T11:00:50 opnsense[71913] /usr/local/etc/rc.linkup: Hotplug event detected for WAN1(wan) but ignoring since interface is configured with static IP (a.b.c.d ::)
2020-08-22T11:00:56 kernel igb0: link state changed to UP
2020-08-22T11:00:56 kernel igb0: link state changed to DOWN
2020-08-22T11:00:56 opnsense[35173] /usr/local/etc/rc.linkup: Hotplug event detected for WAN1(wan) but ignoring since interface is configured with static IP (a.b.c.d ::)
2020-08-22T11:00:56 opnsense[85035] /usr/local/etc/rc.newwanip: IPv4 renewal is starting on 'igb0'
2020-08-22T11:00:57 opnsense[85035] /usr/local/etc/rc.newwanip: On (IP address: a.b.c.d) (interface: WAN1[wan]) (real interface: igb0).
2020-08-22T11:00:57 opnsense[85035] plugins_configure hosts ()
2020-08-22T11:00:57 opnsense[85035] plugins_configure hosts (execute task : dnsmasq_hosts_generate())
2020-08-22T11:00:57 opnsense[85035] plugins_configure hosts (execute task : unbound_hosts_generate())
2020-08-22T11:00:57 opnsense[57135] /usr/local/etc/rc.linkup: Hotplug event detected for WAN1(wan) but ignoring since interface is configured with static IP (a.b.c.d ::)
2020-08-22T11:01:01 kernel igb0: link state changed to UP
2020-08-22T11:01:01 opnsense[89047] /usr/local/etc/rc.linkup: Hotplug event detected for WAN1(wan) but ignoring since interface is configured with static IP (a.b.c.d ::)
2020-08-22T11:01:01 opnsense[84256] /usr/local/etc/rc.newwanip: IPv4 renewal is starting on 'igb0'
2020-08-22T11:01:01 opnsense[84256] /usr/local/etc/rc.newwanip: On (IP address: a.b.c.d) (interface: WAN1[wan]) (real interface: igb0).
2020-08-22T11:01:02 opnsense[84256] plugins_configure hosts ()
2020-08-22T11:01:02 opnsense[84256] plugins_configure hosts (execute task : dnsmasq_hosts_generate())
2020-08-22T11:01:02 opnsense[84256] plugins_configure hosts (execute task : unbound_hosts_generate())
2020-08-22T11:01:09 kernel pflog0: promiscuous mode disabled
2020-08-22T11:01:09 kernel pflog0: promiscuous mode enabled
What is interesting here: The script /usr/local/etc/rc.newwanip is not executing the ROUTING subroutine. Normally, we should see these lines in the logfiles are well, be they are missing completely:
Code: [Select]
2020-08-22T10:57:10 opnsense[17197] /usr/local/etc/rc.newwanip: ROUTING: entering configure using 'wan'
2020-08-22T10:57:10 opnsense[17197] /usr/local/etc/rc.newwanip: ROUTING: IPv4 default gateway set to wan
2020-08-22T10:57:10 opnsense[17197] /usr/local/etc/rc.newwanip: ROUTING: setting IPv4 default route to a.b.c.d
2020-08-22T10:57:10 opnsense[17197] /usr/local/etc/rc.newwanip: ROUTING: removing /tmp/igb0_defaultgw
2020-08-22T10:57:10 opnsense[17197] /usr/local/etc/rc.newwanip: ROUTING: creating /tmp/igb0_defaultgw using 'a.b.c.d'
We have tried various settings from the GUI in order to get a stable behaviour including gateway monitoring etc. No configuration setting provided a valuable workaround.
known workaround:
reboot, or make a change in the configuration so that ROUTING setup routine gets executed.
Any idea, any fix?