Gentoo下Mentohust开机自启动脚本

#!/sbin/runscript
# Copyright (c) by Gentoo Lover <[email protected]>
#

description="Set the mentohust level for a cleaner boot"

LOG_FILE="/tmp/mentohust.log";

depend()
{
        need net;
        after *;
}

start()
{
        if [ ! -e ${LOG_FILE} ]; then
                /usr/bin/mentohust;
                echo  "Starting the mentohust...";
        fi
}

stop()
{
        if [ -e "/tmp/mentohust.log" ]; then
                /usr/bin/mentohust -k;
                echo "Stopping the mentohust...";
                rm -rf ${LOG_FILE};
        fi
}

你可能感兴趣的:(Gentoo下Mentohust开机自启动脚本)