diff options
Diffstat (limited to 'config')
-rw-r--r-- | config/squid/squid.inc | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/config/squid/squid.inc b/config/squid/squid.inc index 752d8376..54150805 100644 --- a/config/squid/squid.inc +++ b/config/squid/squid.inc @@ -1120,14 +1120,17 @@ function squid_resync() { if (!is_service_running('squid')) { log_error("Starting Squid"); - mwexec_bg("/usr/local/sbin/squid -D"); + mwexec("/usr/local/sbin/squid -D"); } else { log_error("Reloading Squid for configuration sync"); mwexec("/usr/local/sbin/squid -k reconfigure"); } // Sleep for a couple seconds to give squid a chance to fire up fully. - sleep(5); + for ($i=0; $i < 10; $i++) { + if (!is_service_running('squid')) + sleep(1); + } filter_configure(); conf_mount_ro(); } |