Chinaunix首页 | 论坛 | 博客
  • 博客访问: 640572
  • 博文数量: 486
  • 博客积分: 10125
  • 博客等级: 上将
  • 技术积分: 5842
  • 用 户 组: 普通用户
  • 注册时间: 2008-10-27 18:34
文章分类

全部博文(486)

文章存档

2011年(52)

2010年(107)

2009年(289)

2008年(38)

我的朋友

分类: LINUX

2009-07-06 17:48:46

http://blog.chinaunix.net/u2/83656/showart.php?id=1978012
禁用系统里不需要的服务



禁用系统里不需要的服务
 
#!/bin/bash
#
# This script is used to del some service is not used on the server
# Create by kevinadmin
# Date 2009-06-23
# Mail
#
# use to the netfs or NFS
echo "Stop the Portmap service and dell it..."
service portmap stop
chkconfig --level 0123456 portmap off
# use to the netfs or NFS
echo "Stop the Nfslock service and dell it..."
service nfslock stop
chkconfig --level 0123456 nfslock off
# use to the netfs or NFS
echo "Stop the netfs service and dell it..."
service netfs stop
chkconfig --level 0123456 netfs off
# use to the netfs or NFS
echo "Stop the rpcgssd service and dell it..."
service rpcgssd stop
chkconfig --level 0123456 rpcgssd off
# use to the netfs or NFS
echo "Stop the rpcidmapd service and dell it..."
service rpcidmapd stop
chkconfig --level 0123456 rpcidmapd off
# use to the print server
echo "Stop the cups service and dell it..."
service cups stop
chkconfig --level 0123456 cups off
# the bluetooth
echo "Stop the bluetooth service and dell it..."
service bluetooth stop
chkconfig --level 0123456 bluetooth off
# use to the bluetooth
echo "Stop the hidd service and dell it..."
service hidd stop
chkconfig --level 0123456 hidd off
#
echo "Stop the avahi-daemon service and dell it..."
service avahi-daemon stop
chkconfig --level 0123456 avahi-daemon off
echo "Stop the ip6tables service and dell it..."
service ip6tables stop
chkconfig --level 0123456 ip6tables off
# at program
echo "Stop the atd service and dell it..."
service atd stop
chkconfig --level 0123456 atd off
#to monitor the lvm
echo "Stop the lvm2-monitor service and dell it..."
service lvm2-monitor stop
chkconfig --level 0123456 lvm2-monitor off
echo "Stop the firstboot service and dell it..."
service firstboot stop
chkconfig --level 0123456 firstboot off
#to find new hardware
echo "Stop the kudzu service and dell it..."
service kudzu stop
chkconfig --level 0123456 kudzu off
#used to monitor the hard ware
echo "Stop the lm_sensors service and dell it..."
service lm_sensors stop
chkconfig --level 0123456 lm_sensors off
#if you use selinux you need to enable mctrans
echo "Stop the mcstrans service and dell it..."
service mcstrans stop
chkconfig --level 0123456 mcstrans off
#if you use selinux you need to enable mctrans
echo "Stop the restorecond service and dell it..."
service restorecond stop
chkconfig --level 0123456 restorecond off
#if you use selinux you need to enable mctrans
echo "Stop the setroubleshoot service and dell it..."
service setroubleshoot stop
chkconfig --level 0123456 setroubleshoot off
# use to monitor the Soft RAID and SCSI device
echo "Stop the mdmonitor service and dell it..."
service mdmonitor stop
chkconfig --level 0123456 mdmonitor off
# use to the smart card
echo "Stop the pcscd service and dell it..."
service pcscd stop
chkconfig --level 0123456 pcscd off
echo "Stop the apmd service and dell it..."
service apmd stop
chkconfig --level 0123456 apmd off
# to update something to the kernel
echo "Stop the microcode_ctl service and dell it..."
service microcode_ctl stop
chkconfig --level 0123456 microcode_ctl off
#use to the X windows
echo "Stop the xfs service and dell it..."
service xfs stop
chkconfig --level 0123456 xfs off
#
service yum-updatesd stop
chkconfig --level 0123456 yum-updatesd off
阅读(178) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~