|
Posted by Ari Rankum on 10/13/17 11:25
Spare Brain wrote:
> "Spare Brain" <spare_brain@yahoo.com> wrote in message
> news:_4mQe.86820$dJ5.10313@tornado.tampabay.rr.com...
>
>>Hi,
>>
>>I recently installed SuSE 9.3 on x86, and it seems to contain scripts
>>"apache2" and "mysql" in the /etc/init.d folder. However, these two
>>(Apache
>>or MySQL) are not running when I fresh reboot the machine. I am having to
>>execute a "./apache2 start" and "./mysql start" every time I reboot.
>>
>>I am a newbie when it comes to unix admin, and I am trying to read up
>>about
>>the rc scripts and how they link into the scripts under the /etc/init.d
>>folder. Before I rush and do what appears "natural" to me (create a S??
>>and
>>K?? links in the rc?.d), I'd like to find out some basic questions it
>>raises:
>>
>>1. Why would the install place the apache2 and mysql scripts under the
>>/etc/init.d but not have any entries in any of the rc scripts?
>>2. What do I need to do (anything specific to SuSE) to make the apache and
>>mysql launch on reboot? Which rcN gets it?
>>
>>Thanks!
>>Angus
>>
>>
>>
>
>
>
> After wading through many (many) different sites, I'd need to do this, even
> though apache2 and mysql came packaged:
>
> chkconfig --add apache2
> chkconfig --add mysql
>
> And then reboot for it to take effect (or do a /etc/init.d/<program> start
> if you don't want a reboot right away).
>
> This answers #2 above, but #1 is still open.
>
> Angus
Angus has done a good job with #2. I'd add that you should follow up
the chkconfig add with
chkconfig --level 2345 apache2 on
chkconfig --level 2345 mysql on
This will have the effect of apache2 and mysql starting at each run
level, 2, 3, 4, 5.
As for #1, I have only a guess. These are packages usually run on
servers, not desktops. Did you configure for a desktop? Also, I'd
argue that SuSE leaving it to you to decide and figure out how to turn
these on results in a less vulnerable Internet, on average.
Any service you run may be subvertible. Therefore, the fewer you run,
the more secure, in general. A good exercise for you, since you're new,
is to run
chkconfig --list |grep on
For every line that comes back, prove to yourself that you know what the
service is and why you need it. If you don't recognise it, you may not
need it. Read the man page for it. If you're not sure, turn it off and
see what breaks. If nothing breaks, leave it off. To turn a service
off with chkconfig
chkconfig --level 2345 the_name_of_the_service off
Once you've done that, the service will not be started anymore for the
run levels you've turned if off for. You still will have to kill the
running instance of the process with
service the_name_of_the_service stop
Good luck.
Navigation:
[Reply to this message]
|