[rhelv6-beta-list] beta2 redhat-release rpm broke ?

Dennis Gregorovic dgregor at redhat.com
Fri Jul 2 18:39:15 UTC 2010


On Fri, 2010-07-02 at 14:24 -0400, Jonathan S Billings wrote:
> On 07/02/2010 02:14 PM, John W. Sopko Jr. wrote:
> > We have always used the following rpm command in scripts to get
> > the Red Hat release version:
> >
> > /bin/rpm -q --qf='%{V}\n' redhat-release
> >
> > This works in RHEL4, RHEL5 and RHEL6 beta1.
> >
> > I installed RHEL6 beta2 Workstation and there is no redhat-release rpm.
> > There is now a "redhat-release-workstation". Do you think this bug
> > and they did not mean to change the rpm Name?
> 
> I was bit by the same bug when I tried to roll the latest rhel6 beta 
> into our configuration management.
> 
> In the end, I changed the query to:
> 
> rpm --qf='%{V}\n' -q --whatprovides redhat-release
> 
> ... which works for rhel5, rhel6b2 and fedora.

The name change was intentional.  

Packages of the same name that are in multiple RHEL variants have the
same version-release.  For example, anaconda in RHEL 5 Client is the
same version-release as what's in RHEL 5 Server.  This was true for all
packages in multiple variants except for redhat-release.  In RHEL 6 I
corrected this by adding the variant name into the package name.

As an aside, this was actually the behavior back in RHEL 2.1.

Please use --whatprovides redhat-release or --file /etc/redhat-release.

Cheers
-- Dennis




More information about the rhelv6-beta-list mailing list