LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 05-28-2015, 05:34 AM   #1
Mathan82
LQ Newbie
 
Registered: May 2015
Posts: 11

Rep: Reputation: Disabled
Centos 7 - Yum update Failed


"yum update" command is not working.
IP information and relevant details below:

-------------------------------------------------------------------------
Here is the error message :
yum update
Loaded plugins: fastestmirror, langpacks


One of the configured repositories failed (Unknown),
and yum doesn't have enough cached data to continue. At this point the only
safe thing yum can do is fail. There are a few ways to work "fix" this:

1. Contact the upstream for the repository and get them to fix the problem.

2. Reconfigure the baseurl/etc. for the repository, to point to a working
upstream. This is most often useful if you are using a newer
distribution release than is supported by the repository (and the
packages for the previous distribution release still work).

3. Disable the repository, so yum won't use it by default. Yum will then
just ignore the repository until you permanently enable it again or use
--enablerepo for temporary usage:

yum-config-manager --disable <repoid>

4. Configure the failing repository to be skipped, if it is unavailable.
Note that yum will try to contact the repo. when it runs most commands,
so will have to try and fail each time (and thus. yum will be be much
slower). If it is a very temporary problem though, this is often a nice
compromise:

yum-config-manager --save --setopt=<repoid>.skip_if_unavailable=true

Cannot find a valid baseurl for repo: base/7/x86_64
------------------------------------------------------------------------
eno16777736: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.8.95 netmask 255.255.252.0 broadcast 192.168.11.255
inet6 fe80::20c:29ff:fe4e:58d9 prefixlen 64 scopeid 0x20<link>
ether 00:0c:29:4e:58:d9 txqueuelen 1000 (Ethernet)
RX packets 3498 bytes 356084 (347.7 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 1525 bytes 212794 (207.8 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536
inet 127.0.0.1 netmask 255.0.0.0
inet6 ::1 prefixlen 128 scopeid 0x10<host>
loop txqueuelen 0 (Local Loopback)
RX packets 22 bytes 2004 (1.9 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 22 bytes 2004 (1.9 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
---------------------------------------------------------------------------

Steps taken so far :
1. Change to google DNS -->
2. Edited the CentOS-Base.repo file -->
3. Restarted network services -->

Literally I had search all over the place, till now i could not fix the issue.
Appreciate if someone come forward and help me to rectify this issue.
 
Old 05-28-2015, 08:56 AM   #2
lazydog
Senior Member
 
Registered: Dec 2003
Location: The Key Stone State
Distribution: CentOS Sabayon and now Gentoo
Posts: 1,249
Blog Entries: 3

Rep: Reputation: 194Reputation: 194
What repos do you have install on your system?

Code:
ls -l /etc/yum.repos.d/
 
Old 05-28-2015, 01:53 PM   #3
John VV
LQ Muse
 
Registered: Aug 2005
Location: A2 area Mi.
Posts: 17,615

Rep: Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651
that command will be mostly useless
all it will show is the name of files in the folder
NOT!!! if they are turned OFF or turned ON

please use yum
Code:
su -
yum repolist all

also inform us as to what YOU did to the files in that folder

this issue is normally caused by the user manually editing the files in that folder
( some even have used MS's "notepad.exe" on windows to edit these files -- DO NOT do that)
 
Old 05-28-2015, 10:18 PM   #4
Mathan82
LQ Newbie
 
Registered: May 2015
Posts: 11

Original Poster
Rep: Reputation: Disabled
[root@localhost ~]# ls -l /etc/yum.repos.d/
total 24
-rw-r--r--. 1 root root 1664 Apr 1 06:27 CentOS-Base.repo
-rw-r--r--. 1 root root 1309 Apr 1 06:27 CentOS-CR.repo
-rw-r--r--. 1 root root 649 Apr 1 06:27 CentOS-Debuginfo.repo
-rw-r--r--. 1 root root 290 Apr 1 06:27 CentOS-fasttrack.repo
-rw-r--r--. 1 root root 1331 Apr 1 06:27 CentOS-Sources.repo
-rw-r--r--. 1 root root 1002 Apr 1 06:27 CentOS-Vault.repo
[root@localhost ~]#

--------------------------------------------------------------------------------------------------------

[root@localhost ~]# su -
Last login: Fri May 29 18:15:20 MYT 2015 on pts/0
[root@localhost ~]# yum repolist all
Loaded plugins: fastestmirror, langpacks
repo id repo name status
C7.0.1406-base/x86_64 CentOS-7.0.1406 - Base disabled
C7.0.1406-centosplus/x86_64 CentOS-7.0.1406 - CentOSPlus disabled
C7.0.1406-extras/x86_64 CentOS-7.0.1406 - Extras disabled
C7.0.1406-fasttrack/x86_64 CentOS-7.0.1406 - CentOSPlus disabled
C7.0.1406-updates/x86_64 CentOS-7.0.1406 - Updates disabled
base/7/x86_64 CentOS-7 - Base enabled: 0
base-debuginfo/x86_64 CentOS-7 - Debuginfo disabled
base-source/7 CentOS-7 - Base Sources disabled
centosplus/7/x86_64 CentOS-7 - Plus disabled
centosplus-source/7 CentOS-7 - Plus Sources disabled
cr/7/x86_64 CentOS-7 - cr disabled
extras/7/x86_64 CentOS-7 - Extras enabled: 0
extras-source/7 CentOS-7 - Extras Sources disabled
fasttrack/7/x86_64 CentOS-7 - fasttrack disabled
updates/7/x86_64 CentOS-7 - Updates enabled: 0
updates-source/7 CentOS-7 - Updates Sources disabled
repolist: 0

-------------------------------------------------------------------------------------------------------------------

I did not do any modification on the files. FYI, currently Centos 7 is running on Vmware Workstation as a virtual machine.
 
Old 05-28-2015, 11:30 PM   #5
Ztcoracat
LQ Guru
 
Registered: Dec 2011
Distribution: Slackware, MX 18
Posts: 9,484
Blog Entries: 15

Rep: Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176
Code:
[root@localhost ~]# ls -l /etc/yum.repos.d/
total 24
-rw-r--r--. 1 root root 1664 Apr 1 06:27 CentOS-Base.repo
-rw-r--r--. 1 root root 1309 Apr 1 06:27 CentOS-CR.repo
-rw-r--r--. 1 root root 649 Apr 1 06:27 CentOS-Debuginfo.repo
-rw-r--r--. 1 root root 290 Apr 1 06:27 CentOS-fasttrack.repo
-rw-r--r--. 1 root root 1331 Apr 1 06:27 CentOS-Sources.repo
-rw-r--r--. 1 root root 1002 Apr 1 06:27 CentOS-Vault.repo
[root@localhost ~]#
In the area where you type your response there is a pound sign (#) above that area.
Click on the pound sign to post your terminal output in [code][code] tags.

It's easier for us to read in code tags-
 
Old 05-28-2015, 11:40 PM   #6
Mathan82
LQ Newbie
 
Registered: May 2015
Posts: 11

Original Poster
Rep: Reputation: Disabled
I am newbie. No idea how to do that.. Guide me through please
I am using Putty.

Last edited by Mathan82; 05-28-2015 at 11:52 PM.
 
Old 05-29-2015, 12:04 AM   #7
Ztcoracat
LQ Guru
 
Registered: Dec 2011
Distribution: Slackware, MX 18
Posts: 9,484
Blog Entries: 15

Rep: Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176
Quote:
Originally Posted by Mathan82 View Post
I am newbie. No idea how to do that.. Guide me through please
I am using Putty.
When you make a post you have the general box with the white space where you write to us and above that box is a place where you can choose different fonts, a smiley face, and etc.

Click on the icon that is the pound sign (#).

Place your mouse pointer in between the code tags ([CODE]*[CODE] right click (after you've copied what you want)and than paste. Where the star (*) is; is where you place your cursor.

Last edited by Ztcoracat; 05-29-2015 at 12:06 AM.
 
Old 05-29-2015, 12:12 AM   #8
Mathan82
LQ Newbie
 
Registered: May 2015
Posts: 11

Original Poster
Rep: Reputation: Disabled
Code:
[root@localhost ~]# ls -l /etc/yum.repos.d/
total 24
-rw-r--r--. 1 root root 1664 Apr  1 06:27 CentOS-Base.repo
-rw-r--r--. 1 root root 1309 Apr  1 06:27 CentOS-CR.repo
-rw-r--r--. 1 root root  649 Apr  1 06:27 CentOS-Debuginfo.repo
-rw-r--r--. 1 root root  290 Apr  1 06:27 CentOS-fasttrack.repo
-rw-r--r--. 1 root root 1331 Apr  1 06:27 CentOS-Sources.repo
-rw-r--r--. 1 root root 1002 Apr  1 06:27 CentOS-Vault.repo
[root@localhost ~]#
Thanks , Got it.
 
Old 05-29-2015, 12:17 AM   #9
Ztcoracat
LQ Guru
 
Registered: Dec 2011
Distribution: Slackware, MX 18
Posts: 9,484
Blog Entries: 15

Rep: Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176
Quote:
Originally Posted by Mathan82 View Post
Code:
[root@localhost ~]# ls -l /etc/yum.repos.d/
total 24
-rw-r--r--. 1 root root 1664 Apr  1 06:27 CentOS-Base.repo
-rw-r--r--. 1 root root 1309 Apr  1 06:27 CentOS-CR.repo
-rw-r--r--. 1 root root  649 Apr  1 06:27 CentOS-Debuginfo.repo
-rw-r--r--. 1 root root  290 Apr  1 06:27 CentOS-fasttrack.repo
-rw-r--r--. 1 root root 1331 Apr  1 06:27 CentOS-Sources.repo
-rw-r--r--. 1 root root 1002 Apr  1 06:27 CentOS-Vault.repo
[root@localhost ~]#
Thanks , Got it.
Your Welcome-

Congrads!-

I'm running CentOS 7 too but I don't understand why your repositories are disabled.
I would imagine that the repo's need to be enabled. (guessing) Best to wait for JohnVV and follow his direction.
 
Old 05-29-2015, 12:38 AM   #10
Mathan82
LQ Newbie
 
Registered: May 2015
Posts: 11

Original Poster
Rep: Reputation: Disabled
Noted. JohnVV please guide me.

Many thanks
 
Old 05-29-2015, 02:18 AM   #11
Ztcoracat
LQ Guru
 
Registered: Dec 2011
Distribution: Slackware, MX 18
Posts: 9,484
Blog Entries: 15

Rep: Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176
https://access.redhat.com/documentat...ositories.html
 
Old 05-29-2015, 06:22 AM   #12
jpollard
Senior Member
 
Registered: Dec 2012
Location: Washington DC area
Distribution: Fedora, CentOS, Slackware
Posts: 4,912

Rep: Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513
You might check the network connectivity. If yum can't access the net for some reason it will also fail like this.
 
Old 05-29-2015, 02:27 PM   #13
John VV
LQ Muse
 
Registered: Aug 2005
Location: A2 area Mi.
Posts: 17,615

Rep: Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651
you already posted what the issue is
Quote:
repo id repo name status
C7.0.1406-base/x86_64 CentOS-7.0.1406 - Base disabled
C7.0.1406-centosplus/x86_64 CentOS-7.0.1406 - CentOSPlus disabled
C7.0.1406-extras/x86_64 CentOS-7.0.1406 - Extras disabled
C7.0.1406-fasttrack/x86_64 CentOS-7.0.1406 - CentOSPlus disabled
C7.0.1406-updates/x86_64 CentOS-7.0.1406 - Updates disabled
base/7/x86_64 CentOS-7 - Base enabled: 0
base-debuginfo/x86_64 CentOS-7 - Debuginfo disabled
base-source/7 CentOS-7 - Base Sources disabled
centosplus/7/x86_64 CentOS-7 - Plus disabled
centosplus-source/7 CentOS-7 - Plus Sources disabled
cr/7/x86_64 CentOS-7 - cr disabled
extras/7/x86_64 CentOS-7 - Extras enabled: 0
extras-source/7 CentOS-7 - Extras Sources disabled
fasttrack/7/x86_64 CentOS-7 - fasttrack disabled
updates/7/x86_64 CentOS-7 - Updates enabled: 0
updates-source/7 CentOS-7 - Updates Sources disabled
repolist: 0
YOU DISABLED the software repos


things that are NOT good!!
Base disabled
Extras disabled
Updates disabled

you manually added a file with a BAD url
base/7/x86_64 CentOS-7 - Base enabled: 0

you manually added a file with a BAD url
updates/7/x86_64 CentOS-7 - Updates enabled: 0


then who knows what else you did

as root make a folder in the folder called "backup"
and MOVE every repo file in there
( do not YET delete them just put them in a new folder as a BACK UP )
then there should OLNY be that folder in yum.repo.d folder

then
manually grab the cent release rpm
http://distro.ibiblio.org/centos/7/o...2.8.x86_64.rpm

download it
then you will need to do a FORCE!!!! reinstall ( this rpm has the repo files in it )

Code:
su -
cd To/The/Location/You/Saved/The/RPM 
rpm --force --install centos-release-7-1.1503.el7.centos.2.8.x86_64.rpm
then clean up the database
Code:
su -
yum clean all 
rpm --rebuilddb 
yum update
 
Old 05-29-2015, 02:41 PM   #14
suicidaleggroll
LQ Guru
 
Registered: Nov 2010
Location: Colorado
Distribution: OpenSUSE, CentOS
Posts: 5,573

Rep: Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142
Quote:
Originally Posted by John VV View Post
you already posted what the issue is

YOU DISABLED the software repos


things that are NOT good!!
Base disabled
Extras disabled
Updates disabled
No, that's normal. Here's the output from my operational CentOS 7 system:
Code:
repo id                       repo name                             status
C7.0.1406-base/x86_64         CentOS-7.0.1406 - Base                disabled
C7.0.1406-centosplus/x86_64   CentOS-7.0.1406 - CentOSPlus          disabled
C7.0.1406-extras/x86_64       CentOS-7.0.1406 - Extras              disabled
C7.0.1406-fasttrack/x86_64    CentOS-7.0.1406 - CentOSPlus          disabled
C7.0.1406-updates/x86_64      CentOS-7.0.1406 - Updates             disabled
!base/7/x86_64                CentOS-7 - Base                       enabled: 8,652
base-debuginfo/x86_64         CentOS-7 - Debuginfo                  disabled
base-source/7                 CentOS-7 - Base Sources               disabled
centosplus/7/x86_64           CentOS-7 - Plus                       disabled
centosplus-source/7           CentOS-7 - Plus Sources               disabled
cr/7/x86_64                   CentOS-7 - cr                         disabled
!epel/x86_64                  Extra Packages for Enterprise Linux 7 enabled: 7,969
epel-debuginfo/x86_64         Extra Packages for Enterprise Linux 7 disabled
epel-source/x86_64            Extra Packages for Enterprise Linux 7 disabled
epel-testing/x86_64           Extra Packages for Enterprise Linux 7 disabled
epel-testing-debuginfo/x86_64 Extra Packages for Enterprise Linux 7 disabled
epel-testing-source/x86_64    Extra Packages for Enterprise Linux 7 disabled
!extras/7/x86_64              CentOS-7 - Extras                     enabled:   128
extras-source/7               CentOS-7 - Extras Sources             disabled
fasttrack/7/x86_64            CentOS-7 - fasttrack                  disabled
!google-chrome                google-chrome                         enabled:     3
!updates/7/x86_64             CentOS-7 - Updates                    enabled:   601
updates-source/7              CentOS-7 - Updates Sources            disabled
!virtualbox/7/x86_64          Oracle Linux / RHEL / CentOS-7 / x86_ enabled:     6
repolist: 17,359
I believe the C7.0.1406 entries are the installation medium.

OP - are you sure the internet is working correctly on your machine? What is the output of "ping www.yahoo.com"?

Last edited by suicidaleggroll; 05-29-2015 at 02:44 PM.
 
Old 05-31-2015, 10:37 PM   #15
Mathan82
LQ Newbie
 
Registered: May 2015
Posts: 11

Original Poster
Rep: Reputation: Disabled
I didn't do any modification in those files, its fresh installation from live cd..
No idea why some updates are disabled.

Yes I am able to ping..

Last edited by Mathan82; 06-01-2015 at 03:09 AM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Yum errors after failed update through Software Update whitesleeve Fedora 1 07-24-2011 04:02 AM
how to update rhel 5 using centos yum updater without conflict with yum redhat plugin udayvikram Linux - Software 2 03-30-2010 09:15 AM
how to update rhel 5 using centos yum updater without conflict with yum redhat plugin udayvikram Linux - Newbie 1 03-29-2010 01:56 PM
yum update on CentOS 5.3 upgraded my system to CentOS 5.4 diskoe Red Hat 1 10-29-2009 05:41 PM
update centos 4 rc1 to centos 4 trou yum? maxut cAos 2 03-04-2005 03:36 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 12:50 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration