ramdisk: Move crontab back to disk

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
This commit is contained in:
Michael Tremer
2015-12-03 14:57:30 +00:00
parent ee3dec50a3
commit 84c5f0d66d
3 changed files with 9 additions and 14 deletions

View File

@@ -21,25 +21,13 @@ case "$1" in
fi
mount_ramdisk "$RRDLOG"
evaluate_retval
#cleanup cron
if [ -e $RRDLOG.bak/cron/new.root ]; then
if [ -e $RRDLOG.bak/cron/root ]; then
rm -f $RRDLOG.bak/cron/new.root
fi
fi
#restore old values to ramdisk if exist
restore_ramdisk "$RRDLOG"
fi
else
restore_ramdisk "$RRDLOG"
fi
#
# Move /var/spool/cron to ramdisk and make a symlink
#
if [ ! -L /var/spool/cron ]; then
mv /var/spool/cron /var/log/rrd/cron
ln -s /var/log/rrd/cron /var/spool/cron
fi
# If run from init and collectd alrady started then exit silent
if [ "$(basename $0)" != "collectd" ]; then

View File

@@ -13,7 +13,6 @@
case "$1" in
start)
boot_mesg "Starting fcron..."
chown cron:cron /var/spool/cron
loadproc /usr/sbin/fcron -y
# remove -y to reenable fcron logging
;;