【IT之路】CentOS 7安装

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/mwb2001/article/details/89636299

一、CentOS 7下载

http://mirrors.aliyun.com/centos/7/isos/x86_64/

二、CentOS安装(VMware搭建):最小安装

1、创建VM

wps7D66.tmp

wps7D67.tmp

wps7D68.tmp

wps7D78.tmp

网络模式:这里使用桥接模式

wps7D8C.tmp

2、CentOS配置--安装配置

wps7DB5.tmp

wps7DC7.tmp

wps7DC7.tmp

wps7DC8.tmp

wps7DD8.tmp

wps7DD9.tmp

wps7DDA.tmp

wps7DDB.tmp

wps7DEC.tmp

网路配置:这里网路配置为自动获取,需要打开网卡的自动获取开关

wps7DED.tmp

设置root密码

wps7DEF.tmp

wps7E02.tmp

三、CentOS配置

1、修改网络为静态IP

修改/etc/sysconfig/network-scripts/ifcfg-ens32文件,输入

TYPE="Ethernet"
PROXY_METHOD="none"
BROWSER_ONLY="no"
BOOTPROTO="static"
DEFROUTE="yes"
IPV4_FAILURE_FATAL="no"
IPV6INIT="yes"
IPV6_AUTOCONF="yes"
IPV6_DEFROUTE="yes"
IPV6_FAILURE_FATAL="no"
IPV6_ADDR_GEN_MODE="stable-privacy"
NAME="ens33"
UUID="35107365-f0d1-42b3-a042-582b55de1b8b"
DEVICE="ens33"
ONBOOT="yes"
IPADDR=192.168.2.106
NETMASK=255.255.255.0
GATEWAY=192.168.2.1

重启网路

service network restart

2、配置国内yum源

系统默认的yum 源速度往往不尽人意,为了达到快速安装的目的,在这里修改yum源为国内源。

上海交通大学yum源

a. 修改/etc/yum.repos.d/CentOS-Base.repo为:

# CentOS-Base.repo

#

# The mirror system uses the connecting IP address of the client and the

# update status of each mirror to pick mirrors that are updated to and

# geographically close to the client.  You should use this for CentOS updates

# unless you are manually picking other mirrors.

#

# If the mirrorlist= does not work for you, as a fall back you can try the

# remarked out baseurl= line instead.

#

#



[base]

name=CentOS-$releasever - Base

#mirrorlist=http://mirrorlist.centos.org/?release=releasever&arch=basearch&repo=os

baseurl=http://ftp.sjtu.edu.cn/centos/releasever/os/basearch/

gpgcheck=1

gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7



#released updates

[updates]

name=CentOS-$releasever - Updates

#mirrorlist=http://mirrorlist.centos.org/?release=releasever&arch=basearch&repo=updates

baseurl=http://ftp.sjtu.edu.cn/centos/releasever/updates/basearch/

gpgcheck=1

gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7



#additional packages that may be useful

[extras]

name=CentOS-$releasever - Extras

#mirrorlist=http://mirrorlist.centos.org/?release=releasever&arch=basearch&repo=extras

baseurl=http://ftp.sjtu.edu.cn/centos/releasever/extras/basearch/

gpgcheck=1

gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7



#additional packages that extend functionality of existing packages

[centosplus]

name=CentOS-$releasever - Plus

#mirrorlist=http://mirrorlist.centos.org/?release=releasever&arch=basearch&repo=centosplus

baseurl=http://ftp.sjtu.edu.cn/centos/releasever/centosplus/basearch/

gpgcheck=1

enabled=0

gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7



#contrib - packages by Centos Users

[contrib]

name=CentOS-$releasever - Contrib

#mirrorlist=http://mirrorlist.centos.org/?release=releasever&arch=basearch&repo=contrib

baseurl=http://ftp.sjtu.edu.cn/centos/releasever/contrib/basearch/

gpgcheck=1

enabled=0

gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

猜你喜欢

转载自blog.csdn.net/mwb2001/article/details/89636299
今日推荐