VMware快速安装CentOS8
1、安装CentOS镜像
1.1下载镜像
镜像下载链接:点击下载
1.2安装系统
VMware安装系统不演示了,安装时候选择mini安装,最简化安装。
如果是CentOS8 安装时候碰到让选择Install Source,可以使用阿里云的镜像。
https://mirrors.aliyun.com/centos/8-stream/BaseOS/x86_64/os/
这个镜像不一定会一直存在,如果不存在了自己去网上重新找一个
2、配置网络
2.1、选择Vmware网卡连接方式
我这选择了桥接模式,勾上复制物理网络连接状态
2.2、设置VMware桥接模式绑定的网卡
2.3、 配置CentOS的网卡
执行命令: vi /etc/sysconfig/network-scripts/ifcfg-ens33
修改以下配置,IP配置为宿主机的同网段。网关和掩码设置成相同。
3、配置yum源
3.1、删除原始yum源
cd /etc/yum.repos.d
rm -rf *.repo
3.2、配置国内yum源
参考:https://developer.aliyun.com/mirror/centos?spm=a2c6h.13651102.0.0.3e221b11HvRhdj
CentOS7参考:https://blog.csdn.net/qq_33180069/article/details/113859801
3.3、安装epel
dnf -y install epel-release
dnf clean all
dnf makecache
dnf repolist
4、安装python、pip
4.1、安装python
yum install python3
alternatives --set python /usr/bin/python3
同时会安装pip3
4.2、修改pip3源、创建pip软链接
mkdir ~/.pip
touch ~/.pip/pip.conf
vi ~/.pip/pip.conf
[global]
index-url = https://pypi.tuna.tsinghua.edu.cn/simple
[install]
trusted-host = https://pypi.tuna.tsinghua.edu.cn # trusted-host
ln -s /usr/bin/pip3 /usr/bin/pip
国内镜像有以下这些 自行选择:
http://pypi.douban.com/simple/ 豆瓣
http://mirrors.aliyun.com/pypi/simple/ 阿里
http://pypi.hustunique.com/simple/ 华中理工大学
http://pypi.sdutlinux.org/simple/ 山东理工大学
http://pypi.mirrors.ustc.edu.cn/simple/ 中国科学技术大学
https://pypi.tuna.tsinghua.edu.cn/simple 清华
5、上传/下载 文件
5.1、使用SecureCRT连接CentOS
安装软件:
yum -y install lrzsz
上传文件(输入命令之后会出现选择框):
rz
下载文件(目录为CRT工具会话选项中的路径):
sz [filename]