yum源配置

cd /etc/yum.repos.d
ls
cp rhel-source.repo server.repo
vim /etc/yum.repos.d/server.repo
[server] 代表容器的名字
name=CentOS-$releasever - Base - 163.com  说明容器的意义
baseurl=http://mirrors.163.com/centos/$releasever/os/$basearch/

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

本机yum clean all &&yum update

你可能感兴趣的:(yum,源配置)