1、wget 命令
yum install -y wget
2、ifconfig 命令
yum install net-tools (apt install net-tools)
3、CentOS yum 配置阿里云yum源
-3.1、切换到centos的yum源:cd /etc/yum.repos.d
-3.2、备份原来的repo文件:mv CentOs-Base.repo CentOs-Base.repo.bak
-3.3、下载阿里云的repo文件:wget http://mirrors.aliyun.com/repo/Centos-7.repo
-3.4、替换原来的repo文件:mv Centos-7.repo CentOs-Base.repo
-3.5、依次执行yum源更新命令: ①yum clean all ② yum makecache ③ yum update
4、 Debian9配置阿里云源
-4.1、在Windows创建“sources.list”文件,内容为
deb http://mirrors.aliyun.com/debian stretch main contrib non-free deb-src http://mirrors.aliyun.com/debian stretch main contrib non-free deb http://mirrors.aliyun.com/debian stretch-updates main contrib non-free deb-src http://mirrors.aliyun.com/debian stretch-updates main contrib non-free deb http://mirrors.aliyun.com/debian-security stretch/updates main contrib non-free deb-src http://mirrors.aliyun.com/debian-security stretch/updates main contrib non-free
-4.2、用创建“sources.list”替换“/etc/apt/sources.list” ,命令:mv /root/sources.list /etc/apt/sources.list
-4.3、更新镜像:apt-get update
5、Debian 9 开启ssh
-5.1、更新apt资源列表:apt-get update
-5.2、安装openssh服务器:apt-get install openssh-service
-5.3、启用ssh.service:systemctl start ssh.service
-5.4、修改配置: vi /etc/ssh/sshd_config 将 #PermitRootLogin prohibit-password 改为 PermitRootLogin yes 和将 #port 22的“#”号删除
-5.5、重启ssh:/etc/init.d/ssh restart