ZPY博客

centos yum错误:cannot retrieve repository metadata repomd xml for repository gitlab_gitlab ce source please verify its path and try again

---
title: "CentOS-yum错误:Cannot retrieve repository metadata (repomd.xml) for repository: gitlab_gitlab-ce-source. Please verify its path and try again"
date: 2018-10-08 15:15:24
categories:
- git
- linux
---

在安装gitlab后再次使用yum install时总会报错,错误代码如下:

Cannot retrieve repository metadata (repomd.xml) for repository: gitlab_gitlab-ce-source. Please verify its path and try again

 解决办法如下:
    a. 打开/etc/yum.repos.d/xxxxx.repo,对于本例来说就是/etc/yum.repost.d/xxx.repo
    b. 将项[xxx]中的enabled=1改为enabled=0

  按照上面代码的提示,我的是gitlab_gitlab-ce-source报错,所以要将gitlab_gitlab-ce.repo的[gitlab_gitlab-ce-source]中的enabled=0

[root@web1 ~]# cd /etc/yum.repos.d
[root@web1 yum.repos.d]# vim gitlab_gitlab-ce.repo
 
将[gitlab_gitlab-ce-source]中的enabled=1改为enabled=0