summaryrefslogtreecommitdiffstats
path: root/etc/rc
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2008-03-11 02:43:55 +0000
committerScott Ullrich <sullrich@pfsense.org>2008-03-11 02:43:55 +0000
commit76d4912ea3a9e783fc5806eaca9207a621ff15ed (patch)
treee967eae0d08918cc1bec08e96b1ac2694e8b8e17 /etc/rc
parent74772f9f789c662db87c2edb4fda4a57e38ec625 (diff)
downloadpfsense-76d4912ea3a9e783fc5806eaca9207a621ff15ed.zip
pfsense-76d4912ea3a9e783fc5806eaca9207a621ff15ed.tar.gz
Touch files if clog is disabled to ensure they are created.
Diffstat (limited to 'etc/rc')
-rwxr-xr-xetc/rc26
1 files changed, 12 insertions, 14 deletions
diff --git a/etc/rc b/etc/rc
index da85d19..21696dc 100755
--- a/etc/rc
+++ b/etc/rc
@@ -157,7 +157,7 @@ rm -rf /var/run/*
echo -n "."
DISABLESYSLOGCLOG=`cat /cf/conf/config.xml | grep disablesyslogclog | wc -l | awk '{ print $1 }'`
if [ ! "$PLATFORM" = "cdrom" ]; then
- if [ "$DISABLESYSLOGCLOG" -lt "0" ]; then
+ if [ "$DISABLESYSLOGCLOG" -gt "0" ]; then
# generate circular logfiles
clog -i -s 512144 /var/log/system.log
clog -i -s 512144 /var/log/filter.log
@@ -169,20 +169,18 @@ if [ ! "$PLATFORM" = "cdrom" ]; then
clog -i -s 65535 /var/log/slbd.log
clog -i -s 65535 /var/log/lighttpd.log
clog -i -s 65535 /var/log/ntpd.log
+ else
+ touch /var/log/system.log
+ touch /var/log/filter.log
+ touch /var/log/dhcpd.log
+ touch /var/log/vpn.log
+ touch /var/log/openvpn.log
+ touch /var/log/portalauth.log
+ touch /var/log/ipsec.log
+ touch /var/log/slbd.log
+ touch /var/log/lighttpd.log
+ touch /var/log/ntpd.log
fi
-else
- if [ "$DISABLESYSLOGCLOG" -lt "1" ]; then
- # generate circular logfiles
- clog -i -s 65535 /var/log/system.log
- clog -i -s 65535 /var/log/filter.log
- clog -i -s 65535 /var/log/dhcpd.log
- clog -i -s 65535 /var/log/vpn.log
- clog -i -s 65535 /var/log/openvpn.log
- clog -i -s 65535 /var/log/portalauth.log
- clog -i -s 65535 /var/log/ipsec.log
- clog -i -s 65535 /var/log/slbd.log
- clog -i -s 65535 /var/log/ntpd.log
- fi
fi
# change permissions on newly created clog files.
OpenPOWER on IntegriCloud