首页 > 代码库 > CentOS Minimal Install

CentOS Minimal Install

ifup eth0
chkconfig iptables off
sestatus

vi /etc/sysconfig/network-scripts/ifcfg-eth0


这样设置扣,记得重启网卡:
[root@localhost ~]# /etc/init.d/network stop
[root@localhost ~]# /etc/init.d/network start

 

于是在/etc/rc.d/rc.local文件中加入

ifup eth0

或者

ifconfig eth0 up
eth0就是要激活的网卡,我系统中的是eth0:1,所以用ifup eth0:1


DEVICE=eth0
HWADDR=00:0c:29:13:6a:ee
TYPE=Ethernet
UUID=c8a636ae-b8f2-4999-9504-19051df65d51
ONBOOT=yes
NM_CONTROLLED=yes
BOOTPROTO=none
IPV6INIT=no
USERCTL=no
IPADDR=100.100.100.100
NETMASK=255.255.255.0
GATEWAY=100.100.100.1

ifdown eth0 ; ifup eth0

selinux

yum
local.repo
[name]
name=***
baseurl=file:///media/cdrom
enable=1
gpgcheck=0

yum makecache

yum -y install vim gcc gcc-c++ automake autoconf


链接克隆:
vi /etc/udev/rules.d/70-persistent-net.rules

 

CentOS Minimal Install