温馨提示×

温馨提示×

您好,登录后才能下订单哦!

密码登录×
登录注册×
其他方式登录
点击 登录注册 即表示同意《亿速云用户服务条款》

Redhat(03):Linux 初始化配置

发布时间:2020-08-06 17:05:40 来源:ITPUB博客 阅读:162 作者:Ryan_Bai 栏目:建站服务器

一、virbr0虚拟网卡的卸载方法

在使用双机软件过程中,如果系统是centos 5.x 默认系统安装完成后为xen内核,那么xen内核引导启动后就会有虚拟网卡(vethx、vif0.x、virbr0、xenbr1等)存在。

这就会直接导致双机软件的两台机器中都会有相同的IP地址存在(virbr0网卡的IP地址都为192.168.122.1)。所以会导致双机系统中的主机关机时,备机不会接管的现象。所以,需要将virbr0卸载掉:

  1. 执行命令:yum remove -y libvirt*,用ifconfig -a查看网卡virbr0是否卸载。

  2. 如果执行yum报错, 可以vi /etc/yum/plugincon.d/rhnplugin.conf然后将文件中的enable=1改成enable=0,目的是先禁用此功能,再执行yum remove libvirt进行卸载。

  3. 重启系统

二、卸载network manager

  1. yum remove NetworkManager –y

  2. 设置关闭图形化界面(安装图形化界面,是为了可以应用eclipse,一般应用服务器不会选择安装图形化)

    systemctl set-default multi-user.target

三、关闭不必要的服务

chkconfig nfs off
chkconfig pcmcia off
chkconfig lpd off
chkconfig autofs off
chkconfig anacron off
chkconfig portmap off
chkconfig isdn off
chkconfig nfslock off
chkconfig sendmail off
chkconfig cups off
chkconfig smartd off
chkconfig bluetooth off
chkconfig netfs off
chkconfig rpcgssd off
chkconfig rpcidmapd off
chkconfig rpcbind off
chkconfig pcscd off
chkconfig smolt off
chkconfig cups off
chkconfig isdn off
chkconfig ip6tables off
systemctl disable nfs
systemctl disable pcmcia
systemctl disable lpd
systemctl disable autofs
systemctl disable anacron
systemctl disable portmap
systemctl disable isdn
systemctl disable nfslock
systemctl disable sendmail
systemctl disable cups
systemctl disable smartd
systemctl disable bluetooth
systemctl disable netfs
systemctl disable rpcgssd
systemctl disable rpcidmapd
systemctl disable rpcbind
systemctl disable pcscd
systemctl disable smolt
systemctl disable cups
systemctl disable isdn
systemctl disable ip6tables
systemctl disable firewalld

四、常用包安装

yum -y install gcc
yum -y install gcc-c++
yum -y install net-snmp
yum -y install ntp
yum -y install unzip
yum -y install vim-enhanced
yum -y install wget
yum -y install telnet
yum -y install kernel-devel
yum -y install finger
yum -y install ssh
yum -y install nslookup
yum -y install zlib-devel
yum -y install krb5-devel
yum -y install sysstat
yum -y install lsof
yum -y install fuser
yum -y install bind-utils
yum -y install glances
yum -y install dstat
yum -y install net-tools
yum -y install vim
yum -y install wget

向AI问一下细节

免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。

AI