centos7,debian9 系统安装

使用VMware或VirtualBox安装,具体怎么安装,请自行百度,此处不赘述。

centos7系统配置

1.系统网络配置(下面网络配置基于nat网络模式,如使用桥接模式需要路由器为其分配ip,无需以下操作)

使用ip addr名查看系统网卡,可以看到有两张网卡,lo和ens33

centos7,debian9 初始配置

使用命领cd /etc/sysconfig/network-scripts进入该目录。

centos7,debian9 初始配置

使用vi命令编辑ifcfg-ens33文件,既上面ens33网卡对应的配置文件。

修改ONBOOT=yes即可。然后重启网卡即可自动配置dhcp网络成功。(systemctl restart network重启网卡命令)

2.配置yum源

首先安装wget yum install -y wget

来到yum源目录:

cd /etc/yum.repos.d

创建repo备份目录及备份系统自带repo源

mkdir repos.bak

mv *.repo repos.bak

下载网易源及阿里yum源文件(可手动下载并导入)。

wget http://mirrors.aliyun.com/repo/Centos-7.repo

wget http://mirrors.163.com/.help/CentOS7-Base-163.repo

清理yum缓存及创建缓存

yum clean all

yum makecache

安装epel源

yum list | grep epel-release

yum install -y epel-release

使用阿里开元镜像的epel源

wget -O /etc/yum.repos.d/epel-7.repo http://mirrors.aliyun.com/repo/epel-7.repo

再次清理yum缓存并生成新的缓存

yum clean all

yum makecache

查看系统可用的yum源

yum repolist enabled

centos7,debian9 初始配置

debian9系统配置

1.debian下开启root远程访问

首先需要安装sshserver

sudo apt-get install openssh-server openssh-client

编辑ssh配置文件

vi /etc/ssh/sshd_config

添加下面的命令ssh服务即可。

PermitRootLogin yes

2.安装make

apt-get install gcc automake autoconf libtool make

相关文章: