Bug 449989 - yum-versionlock doesn't work against package obsoletes?
Summary: yum-versionlock doesn't work against package obsoletes?
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: yum-utils
Version: 5.2
Hardware: All
OS: Linux
low
low
Target Milestone: rc
: ---
Assignee: James Antill
QA Contact: Jan Hutař
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2008-06-04 16:33 UTC by James Ralston
Modified: 2009-01-20 22:05 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-01-20 22:05:56 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2009:0227 0 normal SHIPPED_LIVE yum-utils bug fix update 2009-01-20 16:06:29 UTC

Description James Ralston 2008-06-04 16:33:32 UTC
I'm trying to work around bug 448772 using yum-versionlock.

$ repoquery --quiet --envra --pkgnarrow=installed '*mstflint*' '*perftest*'
'*tvflash*' 'yum*' | sort
0:openib-mstflint-1.2-6.el5_1.1.x86_64
0:openib-perftest-1.2-6.el5_1.1.x86_64
0:openib-tvflash-0.9.2-6.el5_1.1.x86_64
0:yum-3.2.8-9.el5_2.1.noarch
0:yum-metadata-parser-1.1.2-2.el5.x86_64
0:yum-rhn-plugin-0.5.3-6.el5_2.6.noarch
0:yum-skip-broken-1.1.10-9.el5.noarch
0:yum-utils-1.1.10-9.el5.noarch
0:yum-versionlock-1.1.10-9.el5.noarch
1:yum-updatesd-0.9-2.el5.noarch

$ cat /etc/yum/pluginconf.d/versionlock.conf 
[main]
enabled = 1
locklist = /etc/yum/pluginconf.d/versionlock.list

$ cat /etc/yum/pluginconf.d/versionlock.list
0:openib-mstflint-1.2-6.el5_1.1.x86_64
0:openib-perftest-1.2-6.el5_1.1.x86_64
0:openib-tvflash-0.9.2-6.el5_1.1.x86_64

But:

$ yum update
Loading "versionlock" plugin
Loading "rhnplugin" plugin
Loading "skip-broken" plugin
This system is not registered with RHN.
RHN support will be disabled.
Reading version lock configuration
Setting up Update Process
Resolving Dependencies
--> Running transaction check
---> Package mstflint.x86_64 0:1.3-1.el5 set to be updated
---> Package tvflash.x86_64 0:0.9.0-2.el5 set to be updated
---> Package perftest.x86_64 0:1.2-10.el5 set to be updated
--> Finished Dependency Resolution

Dependencies Resolved

=============================================================================
 Package                 Arch       Version          Repository        Size 
=============================================================================
Installing:
 mstflint                x86_64     1.3-1.el5        rhel              162 k
     replacing  openib-mstflint.x86_64 1.2-6.el5_1.1

 perftest                x86_64     1.2-10.el5       rhel               72 k
     replacing  openib-perftest.x86_64 1.2-6.el5_1.1

 tvflash                 x86_64     0.9.0-2.el5      rhel               42 k
     replacing  openib-tvflash.x86_64 0.9.2-6.el5_1.1


Transaction Summary
=============================================================================
Install      3 Package(s)         
Update       0 Package(s)         
Remove       0 Package(s)         

Total download size: 276 k
Is this ok [y/N]: n
Exiting on user Command
Complete!

It would appear that versionlock is ineffective against package obsoletes.

I don't know if this is a bug or a limitation of the control that versionlock
has, but if it's in any way possible, versionlock should override EVERYTHING,
include explicit packages obsoletes.

Comment 1 Tuomo Soini 2008-06-04 17:30:33 UTC
# /etc/yum/pluginconf.d/versionlock.list
#
# List of pacakge versions you want to lock
#
# Format: NAME-VERSION-RELEASE, same as outpuf of
# rpm -qa --qf '%{name}-%{version}-%{release}\n'


Comment 2 James Antill 2008-06-04 18:22:50 UTC
 It's mostly a limitation, the way versionlock works is that it finds all the
available packages matching your "versionlocked name" and then excludes all the
ones with a different version.

 Looking for obsoletes against the name, and then excluding those, would solve
this problem.

 As a workaround you should be able to exclude the obsoleting package.


Comment 3 RHEL Program Management 2008-06-04 22:43:34 UTC
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux maintenance release.  Product Management has requested
further review of this request by Red Hat Engineering, for potential
inclusion in a Red Hat Enterprise Linux Update release for currently deployed
products.  This request is not yet committed for inclusion in an Update
release.

Comment 4 James Ralston 2008-06-05 15:53:55 UTC
Ah... yum-versionlock is more like a yum-neverupdate, then.

While I can --exclude the obsoleting packages if I run yum by hand, the main
problem I am trying to solve is yum-updatesd's continual yammering.

(There's a certain irony here: RHEL 5.2 provided a much-improved yum-updatesd
(one that can actually send notifications for us now, because it no longer
requires localhost to run an SMTP server on port 25), but thanks to the circular
obsoletes chain, I'm about to turn it off again.)

If it wouldn't be a huge performance hit, I think versionlock should also look
for obsoletes against the listed packages, and exclude any packages that
obsolete the listed packages.  I think this behavior is more in line with user
expectations...


Comment 6 James Antill 2008-07-16 15:03:47 UTC
 You know you can put "exclude=blah" in your yum.conf? ... yum-updatesd will
respect that too.


Comment 7 James Antill 2008-07-28 04:44:10 UTC
 I think the latest upstream versionlock should fix this now (it has a
follow_obsoletes option) ... can you try that?

http://devel.linux.duke.edu/gitweb/?p=yum-utils.git;a=commit;h=b280cc1e1d5874d91c117549ec741f7fed9a1232

Comment 8 RHEL Program Management 2008-07-28 04:50:53 UTC
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux maintenance release.  Product Management has requested
further review of this request by Red Hat Engineering, for potential
inclusion in a Red Hat Enterprise Linux Update release for currently deployed
products.  This request is not yet committed for inclusion in an Update
release.

Comment 9 James Ralston 2008-08-07 19:32:04 UTC
Is the latest upstream yum-versionlock packaged anywhere?

The latest in Rawhide is yum-versionlock-1.1.14-4.fc10, from 2008-05-29.  The diff in comment 7 looks like it needs something pretty close to upstream to apply...

Comment 28 errata-xmlrpc 2009-01-20 22:05:56 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2009-0227.html


Note You need to log in before you can comment on or make changes to this bug.