SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Distribution: CentOS 5.5 x86_64 (Desktop) & Linux Mint 9 (Netbook)
Posts: 71
Rep:
Where do i get Chkconfig
Hi,
I am installing Folding@Home and it says for the last step I need Chkconfig to run this command
Code:
s u - -c "chkconfig --add folding"
. I checked SlackBuilds but the link they provide to the source is dead and i cannot find the version to use the SlackBuild script with anywhere. I tried an older version with the SlackBuild Script but it fails.
Any help would be greatly appreciated.
Last edited by coolgreen1; 05-05-2010 at 04:47 AM.
You don't need this on slackware, just add folding to your start up scripts like any other program. chkconfig is a redhat/derived thing. Basically that command tells it "Add the folding script to the allowed start up programs" and I imagine the next command is something like "chkconfig folding on".
We'd need to see the contents of the file that was placed in init.d but generally you'd add the start-up command for custon programs to /etc/rc.d/rc.local
The correct course of action would depend on how "generic" the start-up script is.
Distribution: CentOS 5.5 x86_64 (Desktop) & Linux Mint 9 (Netbook)
Posts: 71
Original Poster
Rep:
Hi,
So to start it as a service I would just enter this script into rc.local? Also, I have removed it from the rc.d folder and init.d folder and it is now in my home folder where it was first made following the F@H instructions, should I put it back?
Code:
# chkconfig: 345 93 14
# description: will start FAH client as a service
su - USERNAME -c "cd /home/USERNAME/folding; ./fah6 < /dev/null >
/dev/null 2>&1 &"
Last edited by coolgreen1; 05-03-2010 at 07:36 PM.
#
# If we're not on battery:
# Up min CPU speed
# Start folding
#
ACSTATE=`cat /sys/class/power_supply/AC/online`
if [ "$ACSTATE" == "1" ]; then
# echo "Setting min CPU speed to 800MHz..."
# echo 800000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
if [ -x /etc/rc.d/rc.fah ]; then
/etc/rc.d/rc.fah start
fi
fi
You might want to edit that if you're not on a laptop.
And the following to rc.local_shutdown:
Code:
# Stop FAH
# We really don't need to check if it's executable
# or not, really.
if [ -x /etc/rc.d/rc.fah ] ; then
/etc/rc.d/rc.fah stop
fi
Just as a general heads up... no need to put it on one line in rc.local... you can append it to the file or even put it in /usr/local/sbin or something and call it from rc.local...
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.