几种下载慢的解决办法
-
Docker Compose安装
# ☆以编译好的二进制包方式安装在Linux系统中 curl -L https://get.daocloud.io/docker/compose/releases/download/1.26.2/docker-compose-`uname -s`-`uname -m` > /usr/local/bin/docker-compose # 以编译好的二进制包方式安装在Linux系统中 chmod +x /usr/local/bin/docker-compose # 查看版本信息 docker-compose -version # 二进制包方式安装的,删除二进制文件即可 rm /usr/local/bin/docker-compose
-
Docker安装
# 1、yum 包更新到最新 yum update # 2、安装需要的软件包, yum-util 提供yum-config-manager功能,另外两个是devicemapper驱动依赖的 yum install -y yum-utils device-mapper-persistent-data lvm2 # 3、☆设置阿里云的yum源 sudo yum-config-manager --add-repo https://mirrors.aliyun.com/docker-ce/linux/centos/docker-ce.repo # 4、安装docker,出现输入的界面都按 y yum install -y docker-ce # 5、查看docker版本,验证是否验证成功 docker -v
# ☆配置阿里云镜像加速器:->阿里云->容器镜像服务->镜像加速器 sudo mkdir -p /etc/docker sudo tee /etc/docker/daemon.json <<-'EOF' {"registry-mirrors": ["https://aip0wjyl.mirror.aliyuncs.com"] } EOF sudo systemctl daemon-reload sudo systemctl restart docker
-
Maven依赖下载
修改Maven的配置文件,配置阿里镜像,在
settings.xml
中的mirros标签下面添加一下内容:<!--精简版--><mirror><id>alimaven</id><name>aliyun maven</name><url>http://maven.aliyun.com/nexus/content/groups/public/</url><mirrorOf>central</mirrorOf> </mirror> <!--完整版--><mirror><id>aliyunmaven</id><mirrorOf>*</mirrorOf><name>阿里云公共仓库</name><url>https://maven.aliyun.com/repository/public</url></mirror><mirror><id>aliyunmaven</id><mirrorOf>*</mirrorOf><name>阿里云谷歌仓库</name><url>https://maven.aliyun.com/repository/google</url></mirror><mirror><id>aliyunmaven</id><mirrorOf>*</mirrorOf><name>阿里云阿帕奇仓库</name><url>https://maven.aliyun.com/repository/apache-snapshots</url></mirror><mirror><id>aliyunmaven</id><mirrorOf>*</mirrorOf><name>阿里云spring仓库</name><url>https://maven.aliyun.com/repository/spring</url></mirror><mirror><id>aliyunmaven</id><mirrorOf>*</mirrorOf><name>阿里云spring插件仓库</name><url>https://maven.aliyun.com/repository/spring-plugin</url></mirror>
-
Linux系统更换yum源镜像为国内镜像
-
阿里yum源配置
#1.备份本地yum源mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo_bak #2.清除缓存目录下的软件包及旧的headers。 yum clean all #3.获取阿里yum源配置文件wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo #4.更新cacheyum makecache #5.安装 yum -y update
-
网易yum源配置
#1.执行命令,进入yum源配置目录: cd /etc/yum.repos.d/ #2.执行命令,备份服务器原有的yum源文件: mv CentOS-Base.repo CentOS-Base.repo.bak #3.下载国内网易yum源镜像 wget http://mirrors.163.com/.help/CentOS7-Base-163.repo #4.执行命令,更换yum源配置文件: mv CentOS7-Base-163.repo CentOS-Base.repo #5.执行命令,生成yum源缓存: yum makecache #6.执行命令,更新yum源: yum -y update
-