Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
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.
I would like to know how to configure a runlevel for a deamon ( for example the rc.postgres is the script of postgreSQL and I want it start at boot time ) . How should I do ?
I would like to know about that . How to change runlevel for a deamon , not only as you show me :
Quote:
add the command you want to run to the shell script /etc/rc.d/rc.local
I think that is an old way and not so good because I can not restart it when there are more than one deamon in the rc.local . I think rc.local only for a program need to start up with machine , not for a deamon .
In Fedora you do have a nice little GUI application that interestingly enough is called services, If I remember correctly, from there you can start stop, and edit runlevels. Although it will only edit runlevel 3,4,5, I recall. Another tool for Fedora is checkconfig (I might be wrong with the name of the command); it does exactly the same as the aforementioned tool, but it also edit runlevels 1,2 and 6 and it is a command line tool.
In Slackware there's not such thing as processes staring at differetn runlevels at boot-up (that, I don't know for certain), but if you want to start a service just /etc/rc.d/nameofservices start|stop|restart, and if you want it to start the service at boot up, just make the file executable chmod +x /etc/rc.d/nameofservice and it will start next time you boot your machine
Here goes an example for Slack using rc.postgres that you mentioned.
a) To start the process /etc/rc.d/rc.postgres start
b)To start the process at boot time chmod +x /etc/rc.d/rc.postgres or
chmod 755 /etc/rc.d/rc.postgres
c) If you want to stop the process /etc/rc.d/rc.postgres start
d) if you don't want the process to start at boot time chmod 644 /etc/rc.d/rc.postgres
I hope this help you, have a nice day.
Last edited by blood_omen; 09-14-2004 at 03:56 PM.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.