Thursday, January 25, 2007

Gentoo configuration issues (2)




Updating configuration files in gentoo
=======
* Regenerating GNU info directory index...
* Processed 160 info files.
* IMPORTANT: 34 config files in /etc need updating.
* Type emerge --help config to learn how to update config files.
=======
In this case run the command: #etc-update


To add a service to the start up runlevel (so it will start every time the machine is reinitiated)

Adding to the run level:
# rc-update add gpm default
# rc-update add sshd default

To find a string:
Goto the applications folder, then:
grep -inr searchterm *
Ex: grep -inr localhost.localdomain *
This should show you all the files that contain that string.


3) Gentoo Method

Gentoo also uses a script to enable or disable services during boot-up. The name of the script is rc-update . Gentoo has three default runlevels. Them being: boot, default and nonetwork. Suppose I want to add the apache webserver to start in the default runlevel, then I run the command:
# rc-update add apache2 default
... and to remove the webserver, it is as simple as :
# rc-update del apache2
To see all the running applications at your runlevel and their status, similar to what is achieved by chkconfig --list, you use the rc-status command.
# rc-status --all