Section 9.5. Turning off Nonessential Services


9.5. Turning off Nonessential Services

One step beyond using your firewall to restrict access to services is to turn off services themselves if they don't need to be running: a service can't be compromised if it isn't turned on! In this section, you'll see which network services are running in a default Fedora Core installation, and how to turn them off if you don't need to use them.

To configure the services that start automatically when the server is booted, open the Service Configuration tool (Applications > System Settings > Server Settings > Services) and make sure the tool displays the configuration for runlevels 3, 4, and 5 by selecting Edit Runlevel > Runlevel All . All the services running on the machine are displayed; note that not all of these are network services. Click on a service to see a brief description of it. Fedora Core ships with a lot of services that, for security reasons, are disabled by default, which makes your job here an easier one.

For example, if you're not using NFS to make files available over the network (if you're not sure what this means, then you're probably not using NFS!), you can safely disable the NFS services portmap, rpcgssd, rpcidmapd, and rpcsvcgssd. NFS is used to share files between Linux and other UNIX-like machines. Similarly, if you're not using Samba to share files (usually with Windows machines), you should disable Samba's smb service.

If you prefer, you can also disable and enable services from the command line using the chkconfig command . For instance, to disable the smb service, enter:

[root@swinetrek kermit]# /sbin/chkconfig smb off [root@swinetrek kermit]# 

To enable the service, use:

[root@swinetrek kermit]# /sbin/chkconfig smb on [root@swinetrek kermit]# 

The chkconfig --list command displays a list of all the services on the machine, showing whether each is enabled or disabled.




Run Your Own Web Server Using Linux & Apache
Run Your Own Web Server Using Linux & Apache
ISBN: 0975240226
EAN: 2147483647
Year: 2006
Pages: 92

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net