Correct the check to what was intended
Use return rather than exit to be friendly on CGI
Make scripts able to react when called from FCGI with GET method
This tag could be present, but empty. Skip processing if the interface has no IP address.
If the interface is configured and not enabled, bail. We do not need to change settings for disabled interfaces. Fixes #3313
If rc.newwanip is run on an interface that should not have an IP address, do not take any action.
Require IPv6.inc header so that if ipv6 functions are called no surprises arise
When the v4 wan is dynamic and v6 is type dhcp and v6 information is retrieved through v4 link than trigger dhcp6c reconfiguration.
Manually revert the patch to cleanup aliases since now its propely handled in the ip assignements. Ticket #2495
Call interface_ipalias_cleanup() after $interface is initialized, and get current IP after it
Actually do this upon entering to get proper ip
Fixes #2495. On trigering of rc.newwanip remove all ipaliases from the interface since they will be readded later on. This will also make sure to have the correct address order
Do not reconfigure dhcp v6 on v4 ip address event. Only handle 6rd and 6to4 while the former is questionable if needed
Copy/pasto does well up to some point
On every ip change renew the hosts file
Run reconfiguration only for changed ip address or dynamic interface
Remove these from here
Only reload racoon when there is at least one tunnel enabled on the interface used to call rc.newwanip(v6). It fixes #2922
Fix whitespace and indent
Use get_interface_ipv6 on rc.newwanipv6 to and teach it to flush the cache on optional parameter. Also teach get_real_interface about the tedios ipv6 tunnel interfaces and return them when ipv6 family is specified
fix typo
Restart snmpd on rc.newwanip. It should fix #2756
Create link_interface_to_track6 to make code more readble and easily trackble. Also improve the generation of rules to avoid creating problems during filter reload and some optimizations with it
Fix interface variable to check against
Don't resync openvpn if rc.newwanip is being run on an openvpn interface, to avoid a loop.
Force resync of vpns and dns even if the IP doesn't change in rc.newwanip, since we could be doing failover/failback for these services.
Sync missing code from interface.inc to newwanip script
Teach mwexec and mwexec_bg how to optionally clear signal masks, and use that when launching ntp or ntpdate.
On its own, ntpd does not sync fast enough at bootup, so bring back the ntpdate sync but improve it so it can't get stuck forever.
Re-order the system routing configure after the tunneled interfaces are configured.
Correct the fieldname we need to look into so we actually configure the tunneled interfaces.
Make sure that we reconfigure the tunneled interfaces when we get a new ipv4 address.
Add logic that (re)configures the dependent interface that has interface tracking setup for a tunneled IPv6 protocol.
Use better is_array test to check if there are any gifs in the config.
Update etc/rc.newwanip
Fixes #1666. Check if the interface needs to be added to a bridge during rc.newwanip as well.
Revert "Already doing this no need to duplicate" <- no, we aren't 100% duplicating this. This commit breaks fully reconfiguring assigned gif interfaces.
This reverts commit 87f0f42c3230ad7ad15b14a8a9d63c58f8b2e379.
Already doing this no need to duplicate
Merge remote branch 'upstream/master'
Conflicts: etc/version
Add issing include to avoid PHP fatal error when calling enable_rrd_graphing()
Put resolvconf generation first since gif tunnels can use hostanmes
Add recovery code for gif/gre the same as in interface_configure. This helps gif/gre tunnels. Needed for capr? Suggested-by: jim-p
Move apinger monitor reconfigure down after gif, since gif can add gateways.
Reconfigure gif so it picks up the new wan ip.
Send correct event for reloading packages.
Conflicts: conf.default/config.xml etc/inc/filter.inc etc/inc/globals.inc etc/inc/pfsense-utils.inc etc/inc/upgrade_config.inc usr/local/www/interfaces.php
Trigger reloading of packages through check_reload_status so it can serialize the calls to not DoS the OS with processes triggered from this. Ticket #1534
Further fine tune the gif tunnel default route commands.
Run system_routing_configure() for all the gif interfaces when the parent interfaces renews.
Drop the ntpdate sync in favor of using ntpd -s, which should have the same net effect without needing the shell script that has been prone to hanging.
On interface ip change reload even igmpproxy. Reported-by: http://forum.pfsense.org/index.php/topic,34372.0.html
If the interface triggering rc.newwanip is not assigned just reload packages and the filter and exit.
Do not write the old ip to the cache file unless it changes. Might help in Ticket #943.
Ticket #1152. Call rc.newwanip even on openvpn linkup event to do the correct reloading of gateways and services. Add a safe belt to avoid a recursion in openvpn itself from rc.newwanip.
If the IP stays the same, still resync VPNs if it's a PPP type interface.
Move these back, it may not play nice with DHCP renews
Move IPsec up too, it should always resync.
OpenVPN needs resync even if the IP did not change, because the IP may have disappeared and caused it to exit.
Call a filter reload even though the ip might not have changed. This makes the gateway pools work after an interface comes up again.
Do not call rc.newwanip on bootup. Remove bogus return 0;
Correct code to reconfigure an interface for groups/gre/gif tunnels to take into account that an interface might be part of many instances of this. Also reconfigure interface groups for every newwanip trigger on interfaces to make sure dynamic interfaces retain their membership on groups.
Ticket #943. Call the update procedure directly to not do an unecessary loop.
Ticket #921. Actually reconfigure apinger in case of newip event because it might impact a previous down event.
Correct typo. Spotted by: wagnoza(IRC)
on newip event reload the static routes for that interface because on dynamic gateways the ip might have changed. While here make sure the interface argument is repsected on system_routing_configure() and use send_event to reconfigure an interface to aleviate a possible race.
Ticket #867. Flush the cache when restarting apinger and also when rc.newwanip is called. also restart apinger earlier in to be on latest address asap.
Ticket #876. Reload gateways/apinger before filter_reload so the new ip/gateway is considered up from the beginning.
Use the new events mechanisms to dispatch events.
No functional change just code reshuffle.
Ticket #449. Actually save something to read back.
Ticket #449. Bring back the check if there is really an ip change on interface event. This avoids reloading openvpn and other sevices when actually there is no change.
Improve startup time by delaying dyndns synching.
This is of no use. Disable until its writer shows up.
Ticket #449. Teach OpenVPN to reload only tunnels for the specified interface. Use this is rc.newwanip script to reload only these tunnels.
Add needed includes.
Create resolv.conf whenever a new ip comes in to have it ready for vpn reloads. Also restart packages in background.
Remove legacy code.
Fix function which should fix default gw handling for dynamic interfaces.
This is not called only for wan.
Fix logging statements to not consider this only as called from dhcp.
More fine grained update of dyndns and dnsupdate.
Touch up some comments and error messages. Teach dydns_configure to update only one interface.
fix old_ip detection, clean up white space
fix typos
Decouple filter.inc from functions.inc. There is no need to process filter functions most of the time. Include filter.inc where it is needed
Rework includes/require. This saves about 4 megabytes.Simplify get_memory(). Tested on mips/i386
Reinstate dhclient_update_gateway_groups_defaultroute() it was moved to gwlb.inc
It looks like half of my commit is missing, comment this function out for a bit.
Update gateway group gateway IP for dhcp interface wan interfaces.
Use product_name
Sync the time on ip change and alert the logs
Try to use where possible filter_configure so upcoming event modifications can be easily integrated.
NOTE: this is only half part of the changes the other half will come after
Remove configure_slbd() from rc.newwanip.Does relayd need this hook no rc.newwanip?
remove the setup_gateways_monitor() from system_routing_configure() as this causes a filter reload loop whenapinger is reloading.Change apinger to reload instead of killinguse setup_gateways_monitor() in rc.bootup and rc.newwanip
Cleanup logging line so that it is more readable.