【centos系统服务】CentOS系统服务优化脚本详解

更新时间:2018-08-24    来源:CentOS    手机版     字体:

【www.bbyears.com--CentOS】

#!/bin/bash
#Author:sherwin
#Version:v1.1
#Author blog:http://blog.rocnic.com
#Email:blog@rocnic.com
#Description:这个脚本是对CentOS服务器的最大限度服务优化,并不适用于所有服务器,请根据实际情况增减。
#定义要需要停止的服务,可以根据实际服务器应用来更改。
SERVICES="acpid atd auditd avahi-daemon avahi-dnsconfd bluetooth conman cpuspeed cups dnsmasq dund firstboot hidd httpd ibmasm ip6tables irda kdump lm_sensors mcstrans messagebus microcode_ctl netconsole netfs netplugd nfs nfslock nscd ntpd oddjobd pand pcscd portmap psacct rdisc restorecond rpcgssd rpcidmapd rpcsvcgssd saslauthd sendmail setroubleshoot smb vncserver winbind wpa_supplicant xfs ypbind yum-updatesd"
for service in $SERVICES
do
#关闭所选服务随系统启动
chkconfig $SERVICES off
#停止所选的服务
service $SERVICES stop
done

本文来源:http://www.bbyears.com/caozuoxitong/43842.html

热门标签

更多>>

本类排行