LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 08-13-2019, 04:42 PM   #1
taylorkh
Senior Member
 
Registered: Jul 2006
Location: North Carolina
Distribution: CentOS 6, CentOS 7 (with Mate), Ubuntu 16.04 Mate
Posts: 1,902

Rep: Reputation: 158Reputation: 158
Block one package from a given repository


I think I have figured out a workaround using yum-priorities for the issue of the moment. However, I would like to know for the next time...

I am running CentOS 7.6. I had installed VirtualBox manually from the .rpm file from Oracle/VB on my prior install. When I reinstalled the OS I added the rpmfusion repos to get a couple of packages which were no longer updated in the nuxdextop repo. I found that VirtualBox was available from rpmfusion. As installed from rpmforge it is giving me issues so I have removed it and am downloading package as I did before for a local install. I do NOT want any VB updates from rpmforge.

I know I can exclude VirtualBox in /etc/yum.conf. That is not what I want to do as updates are availale in the virtualbox.repo. So the question is...

Can I exclude a given package from a given repo and if so, how?

TIA,

Ken

p.s. I think I found the source of some of my problems. It seems that from rmpforge I actually or additionally installed VirtualBox-server. Had to remove that to locally install the downloaded rpm.

Last edited by taylorkh; 08-13-2019 at 04:44 PM.
 
Old 08-13-2019, 05:39 PM   #2
scasey
Senior Member
 
Registered: Feb 2013
Location: Tucson, AZ, USA
Distribution: CentOS 7.6
Posts: 3,486

Rep: Reputation: 1168Reputation: 1168Reputation: 1168Reputation: 1168Reputation: 1168Reputation: 1168Reputation: 1168Reputation: 1168Reputation: 1168
man yum See the -x, --exclude option.
 
1 members found this post helpful.
Old 08-13-2019, 09:06 PM   #3
rknichols
Senior Member
 
Registered: Aug 2009
Distribution: CentOS
Posts: 4,248

Rep: Reputation: 1925Reputation: 1925Reputation: 1925Reputation: 1925Reputation: 1925Reputation: 1925Reputation: 1925Reputation: 1925Reputation: 1925Reputation: 1925Reputation: 1925
In the repository's .repo file in /etc/yum.repos.d, add an "exclude=..." line for the list of packages you want to exclude. You can make that for a particular version of the package if that's what you want, for example, "exclude=somepackage-2.6" if you have an earlier version installed and know that 2.6 has a nasty bug, which you hope will be fixed in version 2.7.
 
1 members found this post helpful.
Old 08-14-2019, 05:17 AM   #4
taylorkh
Senior Member
 
Registered: Jul 2006
Location: North Carolina
Distribution: CentOS 6, CentOS 7 (with Mate), Ubuntu 16.04 Mate
Posts: 1,902

Original Poster
Rep: Reputation: 158Reputation: 158
Thanks folks,

I had never tried adding an exclude to a .repo file, only the main yum.conf. Learn something every day!

Ken
 
  


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
[SOLVED] No package 'x11' found No package 'xext' found No package 'xdamage' found No package 'xfixes' found No package 'x11-xcb' found Jigsaw Linux From Scratch 12 04-25-2019 07:33 AM
i tried using this code for deleting a user given character from a user given string mecrazyme1234 Linux - Newbie 2 06-04-2011 04:59 PM
i tried using this code for deleting a user given character from a user given string mecrazyme1234 Programming 7 06-04-2011 11:47 AM
merge files, given its odd and even given timepassman Linux - Software 1 05-08-2008 01:17 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 08:24 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration