?
Solved

Gentoo: Adding services to be run after a boot

Posted on 2006-04-25
3
Medium Priority
?
325 Views
Last Modified: 2013-12-16
Hi,

How do I set non /etc/init.d services to be started after a boot in Gentoo linux?  I have used the rc-update command to add services which have a script in /etc/init.d such as "rc-update add mysql default" which is working fine.

I have built the following services from source but is there any way to get them started automatically?

Apache:  /usr/local/apache2/bin/apachectl start
Webmin: /usr/local/webmin/webmin-init start

Many thanks.
0
Comment
Question by:jonbutler_uk
3 Comments
 
LVL 35

Accepted Solution

by:
Duncan Roe earned 2000 total points
ID: 16539775
You could make symbolic links in /etc/init.d to these programs e.g:
  # cd /etc/init.d
  # ln -s /usr/local/apache2/bin/apachectl .
Now you must ensure /usr/local is mounted before the scripts are obeyed - only a problem if you have it on other than the root partition.
What priority did rc-update allocate to mysql? As long as you are happy with it, you can now use it on the created symlinks.
0
 
LVL 43

Expert Comment

by:ravenpl
ID: 16541626
or simply use /etc/conf.d/local.start /etc/conf.d/local.stop
0
 
LVL 14

Expert Comment

by:cjl7
ID: 16560367
> I have built the following services from source but is there any way to get them started automatically?

Why on earth do you build stuff from source when you are running Gentoo?

Both webmin and Apache are included in gentoos portage system, and any tweeking you need done can be made by editing the /etc/make.conf...


Cheers

Jonas
0

Featured Post

How to Use the Help Bell

Need to boost the visibility of your question for solutions? Use the Experts Exchange Help Bell to confirm priority levels and contact subject-matter experts for question attention.  Check out this how-to article for more information.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In the first part of this tutorial we will cover the prerequisites for installing SQL Server vNext on Linux.
Often times it's very very easy to extend a volume on a Linux instance in AWS, but impossible to shrink it. I wanted to contribute to the experts-exchange community a way of providing a procedure that works on an AWS instance. It can also be used on…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial
Suggested Courses
Course of the Month13 days, 10 hours left to enroll

749 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question