CentOS安装完毕后,需要进行的优化步骤。
注意:本文所述的优化,是针对于VPS环境的,桌面环境和独立服务器的CentOS请勿使用本文中的方法进行优化,否则可能导致桌面环境不正常。独立服务器也不要使用本文中的方法去优化,否则会引起异常~
1,删除不必要的软件包
[code]
yum remove Deployment_Guide-en-US finger cups-libs cups ypbind
yum remove bluez-libs desktop-file-utils ppp rp-pppoe wireless-tools irda-utils
yum remove sendmail* samba* talk-server finger-server bind* xinetd
yum remove nfs-utils nfs-utils-lib rdate fetchmail eject ksh mkbootdisk mtools
yum remove syslinux tcsh startup-notification talk apmd rmt dump setserial portmap yp-tools
yum groupremove “Mail Server” “Games and Entertainment” “X Window System” “X Software Development”
yum groupremove “Development Libraries” “Dialup Networking Support”
yum groupremove “Games and Entertainment” “Sound and Video” “Graphics” “Editors”
yum groupremove “Text-based Internet” “GNOME Desktop Environment” “GNOME Software Development”
[/code]
2,升级整个系统
[code]
yum update #更新全部更新
yum clean all #清理全部缓存的安装文件以节省空间
[/code]
3,禁用seLinux
[code]
sestatus 先执行这一句看看seLinux状态,如果不是disabled,那么执行如下步骤将其禁用
vi /etc/selinux/config
SELINUX=disabled 禁用SeLinux
SELINUX=enforcing 使用SeLinux[/code]
4,停止网卡对ipv6的支持
[code]vi /etc/modprobe.conf 添加如下行到文尾:
alias net-pf-10 off
alias ipv6 off[/code]
重启后生效。 继续阅读 →