From 04124c6a7306b116647b2d5c40bf52c623161e60 Mon Sep 17 00:00:00 2001 From: Colin Smith Date: Mon, 21 Feb 2005 22:48:18 +0000 Subject: Fix radiusd automatic (re)starting. --- packages/freeradius.xml | 7 +++---- packages/freeradiusclients.xml | 3 +-- packages/freeradiussettings.xml | 3 +-- 3 files changed, 5 insertions(+), 8 deletions(-) (limited to 'packages') diff --git a/packages/freeradius.xml b/packages/freeradius.xml index 24f1ccb6..b7bd9229 100644 --- a/packages/freeradius.xml +++ b/packages/freeradius.xml @@ -66,12 +66,12 @@ fclose($fout); mwexec("rm /usr/local/etc/rc.d/radiusd*"); $fout = fopen("/usr/local/etc/rc.d/radiusd.sh","w"); - fwrite($fout,"#!/bin/sh\n\n/usr/local/sbin/radiusd -d /usr/local/etc/raddb\n"); + fwrite($fout,"#!/bin/sh\n\n/usr/local/sbin/radiusd -X -d /usr/local/etc/raddb\n"); fclose($fout); $fout = fopen("/usr/local/etc/radiusd.conf.dynamic","w"); fwrite($fout, "{\nipaddr = 127.0.0.1\nport = 0\ntype = auth\n}\n\n"); fclose($fout); - mwexec("chmod a+x /usr/local/etc/rc.d/radiusd.sh"); + mwexec("chmod a+x /usr/local/etc/rc.d/radiusd.sh &"); mwexec("/usr/local/etc/rc.d/radiusd.sh"); @@ -85,8 +85,7 @@ } } fclose($fout); - mwexec("/usr/bin/killall -HUP radiusd"); - mwexec("/usr/local/etc/rc.d/radiusd.sh"); + system("/usr/bin/killall -HUP radiusd"); } diff --git a/packages/freeradiusclients.xml b/packages/freeradiusclients.xml index 0d50fee2..198deaa5 100644 --- a/packages/freeradiusclients.xml +++ b/packages/freeradiusclients.xml @@ -68,8 +68,7 @@ } } fclose($fout); - mwexec("killall -HUP radiusd"); - mwexec("/usr/local/etc/rc.d/radiusd"); + system("killall -HUP radiusd"); } sync_package(); diff --git a/packages/freeradiussettings.xml b/packages/freeradiussettings.xml index 633aa66f..423332b0 100644 --- a/packages/freeradiussettings.xml +++ b/packages/freeradiussettings.xml @@ -49,8 +49,7 @@ fwrite($fout, "{\nipaddr = 127.0.0.1\nport = 0\ntype = auth\n}\n\n"); fclose($fout); } - mwexec("killall -HUP radiusd"); - mwexec("/usr/local/etc/rc.d/radiusd"); + system("killall -HUP radiusd"); sync_package(); -- cgit v1.2.3