View previous topic :: View next topic |
Author |
Message |
soldstatic Guru
Joined: 02 Jun 2006 Posts: 305
|
Posted: Sat Jul 01, 2006 4:18 pm Post subject: services at startup |
|
|
i know i could do this with cron jobs or something, but how do i run commands at start up
ie
/etc/apache2 start
so that way i can have the server running w/o someone needing to log on? |
|
Back to top |
|
|
Jogie214 Apprentice
Joined: 15 Aug 2004 Posts: 159 Location: Cologne / Germany
|
Posted: Sat Jul 01, 2006 4:21 pm Post subject: |
|
|
Hi!
With apache2 it's realy simple:
Code: |
rc-update add apache2 default
|
Anything else can be added to /etc/conf.d/local.start, everything in this file is executed after any other boot services are started, you should of course add local (same command as above) to your default run level.
Sebastian _________________ Desktop: Ryzen7 1700x / x370 / Radeon RX 550 / Gentoo amd64 |
|
Back to top |
|
|
soldstatic Guru
Joined: 02 Jun 2006 Posts: 305
|
Posted: Sat Jul 01, 2006 4:24 pm Post subject: |
|
|
ok, well to be specific i need apache1,mysql, and sshd....
is it the same?
and where do i go to see whats already in rc-update? |
|
Back to top |
|
|
soldstatic Guru
Joined: 02 Jun 2006 Posts: 305
|
Posted: Sat Jul 01, 2006 4:27 pm Post subject: |
|
|
if i do rc-update show, i get:
Code: | andy # rc-update show
alsasound |
apache2 |
bootmisc | boot
checkfs | boot
checkroot | boot
clock | boot
coldplug | boot
consolefont | boot
crypto-loop |
cupsd |
domainname | boot
esound |
gkrellmd |
gpm |
hdparm |
hostname | boot
hotplug |
keymaps | boot
lisa |
local | default nonetwork
localmount | boot
modules | boot
mysql |
net.eth0 | default
net.lo | boot
netmount | default
nscd |
numlock |
portsentry |
pwcheck |
reslisa |
rmnologin | boot
rsyncd |
saslauthd |
spamd |
sshd |
svnserve |
syslog-ng | default
urandom | boot
vixie-cron | default
xdm | default
|
And I can see sshd and apache2 and mysql already in there i think... does that mean its already working? |
|
Back to top |
|
|
po0f Apprentice
Joined: 08 Apr 2004 Posts: 162
|
Posted: Sat Jul 01, 2006 4:41 pm Post subject: |
|
|
All of those startup scripts can be added to the default runlevel. You would want to do:
Code: | # rc-update add mysql default
# rc-update add apache2 default |
Any of the startup scripts in /etc/init.d/ can be started this way automatically at boot. The configuration for how they start up is stored in /etc/conf.d/. You might want to add:
Code: | # rc-update add alsasound default |
if you plan on hearing anything coming out of your speakers. |
|
Back to top |
|
|
soldstatic Guru
Joined: 02 Jun 2006 Posts: 305
|
Posted: Sat Jul 01, 2006 5:31 pm Post subject: |
|
|
and
Code: | rc-update add sshd default |
for ssh right? |
|
Back to top |
|
|
frenkel Veteran
Joined: 13 May 2003 Posts: 1034 Location: .nl
|
Posted: Sat Jul 01, 2006 5:34 pm Post subject: |
|
|
soldstatic wrote: | and
Code: | rc-update add sshd default |
for ssh right? |
Yes. |
|
Back to top |
|
|
soldstatic Guru
Joined: 02 Jun 2006 Posts: 305
|
Posted: Sat Jul 01, 2006 5:46 pm Post subject: |
|
|
Thank you VERY mucH!!!!!!!!! |
|
Back to top |
|
|
nixnut Bodhisattva
Joined: 09 Apr 2004 Posts: 10974 Location: the dutch mountains
|
Posted: Sat Jul 01, 2006 6:24 pm Post subject: |
|
|
Moved from Installing Gentoo to Duplicate Threads.
See here please: https://forums.gentoo.org/viewtopic-t-306915.html _________________ Please add [solved] to the initial post's subject line if you feel your problem is resolved. Help answer the unanswered
talk is cheap. supply exceeds demand |
|
Back to top |
|
|
|