diff options
author | Scott Ullrich <sullrich@pfsense.org> | 2008-11-09 05:43:20 +0000 |
---|---|---|
committer | Scott Ullrich <sullrich@pfsense.org> | 2008-11-09 05:43:20 +0000 |
commit | 00518840da211a2d5dcef0ccb3b242aed28b7327 (patch) | |
tree | 2b722903a0282beeb81c1a38fc1b379c91f0548b | |
parent | d271761b8c95ba945491954fded4a9981714ecc2 (diff) | |
download | pfsense-00518840da211a2d5dcef0ccb3b242aed28b7327.zip pfsense-00518840da211a2d5dcef0ccb3b242aed28b7327.tar.gz |
Sync the time on ip change and alert the logs
-rwxr-xr-x | etc/rc.newwanip | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/etc/rc.newwanip b/etc/rc.newwanip index 8045fbe..0169359 100755 --- a/etc/rc.newwanip +++ b/etc/rc.newwanip @@ -107,9 +107,13 @@ filter_configure(); enable_rrd_graphing(); /* restart packages */ -if($old_ip <> "") - if($old_ip <> $curwanip) +if($old_ip <> "") { + if($old_ip <> $curwanip) { + mwexec_bg("/usr/local/sbin/ntpdate_sync_once.sh"); exec("/etc/rc.start_packages"); + log_error("pfSense package system has detected an ip change $old_ip -> $curwanip ... Restarting packages."); + } +} /* reconfigure our gateway monitor */ setup_gateways_monitor(); |