#1 delete ssh login ask
sed -i 's/^#.*StrictHostKeyChecking.*$/StrictHostKeyChecking no/' /etc/ssh/ssh_config
#2 set fonk
sed -i 's/^LANG/#LANG/' /etc/sysconfig/i18n
cat > /etc/sysconfig/i18n <LANG="en_US"
SUPPORTED="en_US.UTF-8:en_US:en:zh_CN.UTF-8"
SYSFONT="latarcyrheb-sun16"
EOF
#set inittab
sed -i 's/^id:5/id:3/' /etc/inittab
#set chkconfig off
chkconfig gpm off
chkconfig sendmail off
chkconfig xinetd off
chkconfig yum-updatesd off
chkconfig portmap off
chkconfig nfslock off
chkconfig nfs off
chkconfig isdn off
chkconfig ip6tables off
chkconfig iptables off
chkconfig cups off
chkconfig bluetooth off
chkconfig apmd off
chkconfig atd off
chkconfig autofs off
chkconfig avahi-daemon off
chkconfig avahi-dnsconfd off
chkconfig capi off
chkconfig firstboot off
chkconfig dund off
chkconfig dnsmasq off
chkconfig hidd off
chkconfig irda off
chkconfig ibmasm off
chkconfig isdn off
chkconfig mcstrans off
chkconfig pand off
chkconfig oddjobd off
chkconfig pcscd off
chkconfig restorecond off
chkconfig rpcgssd off
chkconfig rpcidmapd off
chkconfig rpcsvcgssd off
chkconfig wpa_supplicant off
#set sysctl.conf
cat >> /etc/sysctl.conf <vm.swappiness = 20
fs.file-max = 65535
net.ipv4.tcp_fin_timeout = 30
net.ipv4.tcp_keepalive_time = 300
net.ipv4.tcp_syncookies = 1
net.ipv4.tcp_tw_reuse = 1
net.ipv4.tcp_tw_recycle = 1
net.ipv4.ip_local_port_range = 5000 65000
EOF
阅读(1254) | 评论(0) | 转发(0) |