914926
#!/bin/bash
914926
914926
if [ -e /etc/sysconfig/man-db ]; then
914926
    . /etc/sysconfig/man-db
914926
fi
914926
914926
if [ "$CRON" = "no" ]; then
914926
   exit 0
914926
fi
914926
914926
renice +19 -p $$ >/dev/null 2>&1
914926
ionice -c3 -p $$ >/dev/null 2>&1
914926
914926
LOCKFILE=/var/lock/man-db.lock
914926
914926
# the lockfile is not meant to be perfect, it's just in case the
914926
# two man-db cron scripts get run close to each other to keep
914926
# them from stepping on each other's toes.  The worst that will
914926
# happen is that they will temporarily corrupt the database
914926
[[ -f $LOCKFILE ]] && exit 0
914926
914926
trap "{ rm -f $LOCKFILE ; exit 0; }" EXIT
914926
touch $LOCKFILE
914926
# create/update the mandb database
914926
mandb $OPTS
914926
914926
exit 0