Can`t download with yum on Linux CentOS

Issues related to applications and software problems
Post Reply
serban123
Posts: 3
Joined: 2019/08/30 10:25:54

Can`t download with yum on Linux CentOS

Post by serban123 » 2019/08/30 10:28:01

I installed Linux CentOS on a virtualbox. The internet connection is thru proxy but I understood I have to modifiy resolv.conf. I added the proxy, username and password and then I tested with the command : yum repolist and I get this :

Loaded plugins: fastesmirror
Loading mirror speeds from cached hostfile
Could not retrieve mirrorlist http://mirrorlist.centos.org/?release=7 ... nfra=stock error was
14:curl#6 - "Could not resolve host: mirrorlist.centos.org; Unknown error"
Loading mirror speed from cached hostfile
Loading mirror speed from cached hostfile
Loading mirror speed from cached hostfile
repo id repo name
base/7/x86_64 CentOS -7- base
extras/7/x86_64 CentOS -7- extras
updates/7/x86_64 CentOS -7- updates
repolist: 0

What does this error mean ? And what do I have to do to download with yum.

Thanks in advance

User avatar
TrevorH
Forum Moderator
Posts: 26940
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Can`t download with yum on Linux CentOS

Post by TrevorH » 2019/08/30 11:05:27

I installed Linux CentOS on a virtualbox. The internet connection is thru proxy but I understood I have to modifiy resolv.conf. I added the proxy, username and password and then I tested with the command : yum repolist and I get this :
No, /etc/resolv.conf is not the correct place to add proxy details. That should only contain lines starting with keyards like search/domain/nameserver.

The correct place to put proxy details for yum is in /etc/yum.conf. You can find details of what you need to add by running man yum.conf and searching it for "proxy".
CentOS 5 died in March 2017 - migrate NOW!
CentOS 6 goes EOL sooner rather than later, get upgrading!
Full time Geek, part time moderator. Use the FAQ Luke

Post Reply

Return to “CentOS 7 - Software Support”