Project

General

Profile

Bug #4587

apinger doesnt come up when wan monitoring is disabled and vpn monitoring is on on boot

Added by Bipin Chandra over 4 years ago. Updated over 3 years ago.

Status:
Resolved
Priority:
Normal
Category:
Gateway monitoring
Target version:
Start date:
04/07/2015
Due date:
% Done:

0%

Estimated time:
Affected Version:
All
Affected Architecture:

Description

on the nanobsd alix, i have one wan and one vpn connection, my wan is stable so i have disabled monitoring on it but left monitoring on on the vpn, during boot the tunnel comes up after some time so apinger just says no usable targets found so exiting.
there needs to be some code to check after a while if monitoring is set on any gateway and then start it rather than having to manually start it after boot after all gateways are online

History

#1 Updated by Chris Buechler over 4 years ago

  • Target version deleted (2.2.2)

When the VPN does connect, it'll kick off rc.newwanip, which will setup gateway monitoring. If the ovpnc interface is assigned, and configured on interfaces.php with a static IP, that would skip that process. Is that maybe the case here?

#2 Updated by Bipin Chandra over 4 years ago

well i rebooted the alix and waited like 8hrs but still monitoring didnt start.
no it isnt assigned as static, just none for ipv4/6

#3 Updated by Bipin Chandra over 4 years ago

vpn was working fine in those 8hrs after which i manually started monitoring

#4 Updated by Chris Buechler over 4 years ago

did it log for newwanip when the VPN connected? How long was it until it connected? Mostly curious if it had finished booting or not by the time the VPN connected.

#5 Updated by Bipin Chandra over 4 years ago

i didnt see any newwanip log messages but ill try that once more and let u know exactly.
once wan goes up, by the time the cron package starts, its mostly up so basically till its completely booted, vpn is up

#6 Updated by Bipin Chandra over 4 years ago

by the time its completely booted vpn is up and apinger dead even after 5mins but if i goto services and restart openvpn then apinger starts working, log attached below

Apr 7 12:18:25 kernel: Trying to mount root from ufs:/dev/ufs/pfsense1 [ro]...
Apr 7 12:18:25 check_reload_status: Linkup starting vr1
Apr 7 12:18:25 kernel:
Apr 7 12:18:25 kernel: vr1: link state changed to DOWN
Apr 7 12:18:28 sshd[7845]: Server listening on :: port 22.
Apr 7 12:18:28 sshd[7845]: Server listening on 0.0.0.0 port 22.
Apr 7 12:18:28 sshlockout[8129]: sshlockout/webConfigurator v3.0 starting up
Apr 7 12:18:28 check_reload_status: Linkup starting vr1
Apr 7 12:18:28 kernel: vr1: link state changed to UP
Apr 7 12:18:36 kernel: vr0: link state changed to DOWN
Apr 7 12:18:36 check_reload_status: Linkup starting vr0
Apr 7 12:18:36 php: rc.bootup: Resyncing OpenVPN instances.
Apr 7 12:18:36 kernel:
Apr 7 12:18:36 kernel: tun1: changing name to 'ovpnc1'
Apr 7 12:18:36 kernel: pflog0: promiscuous mode enabled
Apr 7 12:18:38 kernel: .
Apr 7 12:18:38 kernel: DUMMYNET 0 with IPv6 initialized (100409)
Apr 7 12:18:38 kernel: load_dn_sched dn_sched FIFO loaded
Apr 7 12:18:38 kernel: load_dn_sched dn_sched QFQ loaded
Apr 7 12:18:38 kernel: load_dn_sched dn_sched RR loaded
Apr 7 12:18:38 kernel: load_dn_sched dn_sched WF2Q+ loaded
Apr 7 12:18:38 kernel: load_dn_sched dn_sched PRIO loaded
Apr 7 12:18:39 kernel: ..
Apr 7 12:18:39 check_reload_status: Linkup starting vr0
Apr 7 12:18:39 kernel:
Apr 7 12:18:39 kernel: vr0: link state changed to UP
Apr 7 12:18:42 kernel: done.
Apr 7 12:18:49 kernel:
Apr 7 12:18:49 kernel: ovpnc1: link state changed to UP
Apr 7 12:18:49 check_reload_status: rc.newwanip starting ovpnc1
Apr 7 12:18:51 php-fpm[28164]: /rc.newwanip: rc.newwanip: Info: starting on ovpnc1.
Apr 7 12:18:57 php: rc.bootup: ROUTING: setting default route to 2.48.4.1
Apr 7 12:18:57 kernel: done.
Apr 7 12:19:12 kernel: done.
Apr 7 12:19:14 check_reload_status: Updating all dyndns
Apr 7 12:19:14 kernel: done.
Apr 7 12:19:15 kernel: .
Apr 7 12:19:16 kernel: .
Apr 7 12:19:16 kernel: .
Apr 7 12:19:16 kernel: .
Apr 7 12:19:17 kernel: .done.
Apr 7 12:19:18 php-fpm[47701]: /rc.dyndns.update: phpDynDNS: updating cache file /conf/dyndns_wannamecheap'firewall'1.cache: x.x.x.x
Apr 7 12:19:18 php-fpm[47701]: /rc.dyndns.update: phpDynDNS: (Success) IP Address Updated Successfully!
Apr 7 12:19:21 php: rc.bootup: miniupnpd: Starting service on interface: lan
Apr 7 12:19:21 kernel: done.
Apr 7 12:19:21 kernel: done.
Apr 7 12:19:22 syslogd: exiting on signal 15
Apr 7 12:19:22 syslogd: kernel boot file is /boot/kernel/kernel
Apr 7 12:19:28 login: login on ttyv0 as root
Apr 7 12:19:28 sshlockout[70362]: sshlockout/webConfigurator v3.0 starting up
Apr 7 12:19:28 login: login on ttyu0 as root

after restarting openvpn apinger starts, log below

Apr 7 12:21:16 syslogd: kernel boot file is /boot/kernel/kernel
Apr 7 12:22:22 syslogd: exiting on signal 15
Apr 7 12:22:22 syslogd: kernel boot file is /boot/kernel/kernel
Apr 7 12:23:48 kernel: ovpnc1: link state changed to DOWN
Apr 7 12:23:48 check_reload_status: Reloading filter
Apr 7 12:23:48 check_reload_status: Reloading filter
Apr 7 12:24:00 kernel: ovpnc1: link state changed to UP
Apr 7 12:24:00 check_reload_status: rc.newwanip starting ovpnc1
Apr 7 12:24:02 php-fpm[73878]: /rc.newwanip: rc.newwanip: Info: starting on ovpnc1.
Apr 7 12:24:02 php-fpm[73878]: /rc.newwanip: rc.newwanip: on (IP address: 10.10.0.62) (interface: VPN[opt2]) (real interface: ovpnc1).
Apr 7 12:24:02 php-fpm[73878]: /rc.newwanip: IP has changed, killing states on former IP 0.0.0.0.
Apr 7 12:24:05 php-fpm[73878]: /rc.newwanip: Removing static route for monitor x.x.x.x and adding a new route through 10.10.0.61
Apr 7 12:24:15 php-fpm[73878]: /rc.newwanip: pfSense package system has detected an IP change or dynamic WAN reconnection - 0.0.0.0 -> 10.10.0.62 - Restarting packages.
Apr 7 12:24:15 check_reload_status: Starting packages
Apr 7 12:24:17 php-fpm[41290]: /rc.start_packages: Restarting/Starting all packages.
Apr 7 12:24:34 kernel: pid 60580 (ntpd), uid 0: exited on signal 11

#7 Updated by Bipin Chandra over 4 years ago

the other thing is when booted ntp deamon is up and running but when i restarted openvpn, apinger starts but ntp daemon stops and that i have to restart also but if i goto routing and just hit save and apply for the vpn gateway then apinger starts and then ntp also remains up

#8 Updated by Chris Buechler over 4 years ago

sounds like that might be enough to replicate, will give it a shot. The NTP issue is almost certainly #4155.

#9 Updated by Chris Buechler over 3 years ago

  • Status changed from New to Confirmed
  • Affected Version changed from 2.2.1 to All

#10 Updated by Chris Buechler over 3 years ago

  • Assignee set to Chris Buechler

checking this after apinger replacement

#11 Updated by Bipin Chandra over 3 years ago

i checked it, still same. As a matter of fact, even if monitoring is enabled on wan and vpn both and u reboot then monitoring works only for the WAN and VPN says pending unless u restart dpinger

#12 Updated by Bipin Chandra over 3 years ago

any chance this will be fixed in 2.3?

#13 Updated by Chris Buechler over 3 years ago

  • Status changed from Confirmed to Feedback

this should be fixed in 2.3 as part of #5952, Bipin can you test with the first snapshot from March 11 or newer?

#14 Updated by Bipin Chandra over 3 years ago

ys its fixed, tried on a full and nanobsd install and monitoring comes up just fine on openvpn tunnel on bootup, u can mark this resolved

#15 Updated by Renato Botelho over 3 years ago

  • Status changed from Feedback to Resolved
  • Target version set to 2.3

Also available in: Atom PDF