在新安装的 CentOS 5.3 机器上禁用服务?

kno*_*orv 7 security centos hardening chkconfig

我最近安装了一台 CentOS 5.3 机器,我将它锁定在无头环境中用于服务器使用(机器上不会使用 GUI)。该服务器将用作组合的 Web 和数据库服务器。

我已经禁用了 xfs 和 portmap,因为机器上显然不需要这些。

下面是一个 chkconfig 日志,它显示了机器上运行的服务。

问题:除了 xfs 和 portmap - 您会考虑禁用以下哪些服务?为什么?

chkconfig --list | grep 3:on

acpid           0:off   1:off   2:on    3:on    4:on    5:on    6:off
anacron         0:off   1:off   2:on    3:on    4:on    5:on    6:off
atd             0:off   1:off   2:off   3:on    4:on    5:on    6:off
auditd          0:off   1:off   2:on    3:on    4:on    5:on    6:off
autofs          0:off   1:off   2:off   3:on    4:on    5:on    6:off
crond           0:off   1:off   2:on    3:on    4:on    5:on    6:off
haldaemon       0:off   1:off   2:off   3:on    4:on    5:on    6:off
ip6tables       0:off   1:off   2:on    3:on    4:on    5:on    6:off
iptables        0:off   1:off   2:on    3:on    4:on    5:on    6:off
irqbalance      0:off   1:off   2:on    3:on    4:on    5:on    6:off
kudzu           0:off   1:off   2:off   3:on    4:on    5:on    6:off
mcstrans        0:off   1:off   2:on    3:on    4:on    5:on    6:off
messagebus      0:off   1:off   2:off   3:on    4:on    5:on    6:off
microcode_ctl   0:off   1:off   2:on    3:on    4:on    5:on    6:off
netfs           0:off   1:off   2:off   3:on    4:on    5:on    6:off
network         0:off   1:off   2:on    3:on    4:on    5:on    6:off
readahead_early 0:off   1:off   2:on    3:on    4:on    5:on    6:off
restorecond     0:off   1:off   2:on    3:on    4:on    5:on    6:off
sshd            0:off   1:off   2:on    3:on    4:on    5:on    6:off
syslog          0:off   1:off   2:on    3:on    4:on    5:on    6:off
yum-updatesd    0:off   1:off   2:on    3:on    4:on    5:on    6:off
Run Code Online (Sandbox Code Playgroud)

Cia*_*ian 5

我唯一倾向于禁用的东西是 yum-updatesd(因为我会在需要时手动运行 yum update,并且可能在 cron 中编写脚本)、autofs、kudzu(因为我认为您的硬件不太可能改变) 和 netfs(假设您没有使用 NFS 等)。如果性能是一个大问题,那么禁用auditd 可能是值得的。大多数其他人可以禁用,但为了让管理员的生活更轻松,我通常会让它们运行。


hda*_*iel 2

我会禁用所有我通常不使用的服务,例如 anacron 和 netfs。如果服务器不需要防火墙规则,则可以禁用 iptables 和 ip6tables。