Confused about init.d scripts...

CrazyHelloDeli

Platinum Member
Jun 24, 2001
2,854
0
0
It was my understanding(from what ive read)that you can start and stop daemons by typing the following:
#/etc/rc.d/init.d/XXX (start, stop, restart)

My problem is, now that I know a fair amount about Linux itself and how it works, im trying to teach myself how to finally use it for somthing usefull(Apache, BIND, DHCP, etc).

Well I install Apache 1.3.24 from source and try to configure it to start at boot. My understanding was that services, when installed, create startup scripts in /etc/rc.d/init.d/XXX which I can then point to in my runlevel directories with symbolic links using the naming convention "S85httpd" for example.

What im confused about is no matter what I install(Apache, BIND, DHCP) nothing puts that all important startup script in /etc/rc.d/init.d except the services I installed when I installed Linux itself. Im obviously missing somthing. Its annoying having to execute each service manually every boot. Can anyone clear up my confusion? Thx

 

bubba

Golden Member
Oct 10, 1999
1,589
0
0

If you installed them from RPM they would put the scripts there. However, if you built them from source you need to call them yourself by either writing a script or adding a line to start the daemon to your rc.local.
 

Nothinman

Elite Member
Sep 14, 2001
30,672
0
0
Most of the time when you install things from source they don't create boot scripts, or only have examples in the tarball. You have to create your own or copy the example edit it to fit your system.

Frankly I stick to packages, compiling from source gives little gain and it's much easier to upgrade/remove packages. And Debian's packages are very well done.
 

CrazyHelloDeli

Platinum Member
Jun 24, 2001
2,854
0
0
Ok cool, never knew that tar's didnt install scripts. Im using RH 7.2 so ill just DL the RPMs instead. Thx guys:D
 

Nothinman

Elite Member
Sep 14, 2001
30,672
0
0
One thing you should realize is that tarballs aren't made for a single distribution, they're made for compiling on any number of OSes not all of which init scripts make sense.