LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   redhat packages I can safely remove (https://www.linuxquestions.org/questions/linux-newbie-8/redhat-packages-i-can-safely-remove-4175420699/)

vacantstare 08-06-2012 03:52 PM

redhat packages I can safely remove
 
Hello-

I'm mostly a Windows admin (don't hate), and I recently inherited management of a RedHat 5.x server that provides sftp and https services. I'd like to rip out everything that's not needed to support these two functions, especially things that may have vulnerabilites.

Can I remove cups, samba and nfs related packages without affecting the two services this box provides?

Got any suggestions for other superfluous packages that could/should be removed? DHCP? DNS?

thanks

spazticclown 08-06-2012 04:18 PM

You can start out by stopping the services that you wish to remove to see if anything else failes to function properly.

For instance disable cups and see if anything goes wrong, who knows, maybe some user somewhere prints through the server.

The startup scripts are in /etc/init.d and can be stopped like so
Code:

/etc/init.d/smb stop
Or disabled with:
Code:

/sbin/chkconfig smb off
smb is the samba server in the above examples.

Almost forgot, to change firewall rules from terminal
Code:

system-config-firewall-tui
or in x from graphical display
Code:

system-config-firewall

chrism01 08-06-2012 05:53 PM

As root
Code:

service <service name> stop
repeat for each candidate and let it run for a week, in case there are eg end of week special jobs.
Get the service name from chkconfig/ntsysv below.

Next
Code:

chkconfig <service name> off
permanently turns it off, even after a reboot.
http://linux.die.net/man/8/chkconfig

You can get a list of all services
Code:

chkconfig --list
For a pseudo GUI, try ntsysv http://linux.die.net/man/8/ntsysv

You'll want to bookmark this http://www.linuxtopia.org/online_boo...ion/index.html

You're going to want to understand the yum cmd http://linux.die.net/man/8/yum to keep the system updated.
Try to avoid using rpm cmd http://linux.die.net/man/8/rpm for updating, as this does NOT handle dependencies; that's what yum is for :)

PS: you might want to get a copy of Centos (a free rebuild of RHEL) at home to familiarize yourself.

Welcome to LQ :)


All times are GMT -5. The time now is 02:33 AM.