YUM stuck in beta

Rocky 9

grafana.repo:

[grafana]
name=grafana
baseurl=https://rpm.grafana.com
repo_gpgcheck=1
enabled=1
gpgcheck=1
gpgkey=https://rpm.grafana.com/gpg.key
sslverify=1
sslcacert=/etc/pki/tls/certs/ca-bundle.crt
exclude=*beta*
$ dnf list grafana
Last metadata expiration check: 0:01:16 ago on Tue 22 Nov 2022 06:27:39 PM MST.
Available Packages
grafana.aarch64                                          9.3.0~beta1-1                                           grafana
grafana.armhfp                                           9.3.0~beta1-1                                           grafana
grafana.x86_64                                           9.3.0~beta1-1                                           grafana

How do you get the NOT beta version?

I have similar situation on OracleLinux 8.6

edit
Resolved by yum install grafana-9.2.6-1
If you want to update whole OS before, use yum update --exclude=grafana

1 Like

Hi @sivan,

It is also written in the official documentation as how to exclude beta.

Let us know if this helps.

Nice. But this means you can’t update automatically, contrary to the installation docs.

See the repo file in the question. The exclude parameter is used as instructed. The issue remains. Unable to update automatically, contrary to the docs.

Thanks for the reply. Let me investigate it and will get back with an update

Hello all,

So, I was also able to reproduce it on my CentOS 9 Stream

I have reported this as a bug to the release team so that they can investigate it further:

I also found a WORKAROUND for it :slight_smile: :

Run this command:

[root@localhost ~]# dnf whatprovides grafana
and it will provide a list of packages provided in the grafana repo (already sorted by version)

Select the recent one showing just above the beta version i.e.

grafana-9.2.6-1.x86_64 : Grafana
Repo        : grafana
Matched from:
Provide    : grafana = 9.2.6-1

And install it this way:

[root@localhost ~]# dnf install grafana-9.2.6-1.x86_64
Last metadata expiration check: 0:17:57 ago on Thu 24 Nov 2022 11:48:37 AM CET.
Dependencies resolved.
===================================================================================================================================================================================================================
 Package                                                               Architecture                            Version                                            Repository                                  Size
===================================================================================================================================================================================================================
Installing:
 grafana                                                               x86_64                                  9.2.6-1                                            grafana                                     92 M

This way the user can install the latest stable release.

For this workaround, I think you’ll also want to disable the Grafana repo so that you don’t get pushed to beta when you run dnf update for normal CentOS updates.

Looks like that also fails the GPG check:

$ sudo dnf install grafana-9.2.6-1.x86_64
Last metadata expiration check: 0:00:44 ago on Thu 24 Nov 2022 10:51:28 AM MST.
Dependencies resolved.
========================================================================================================================
 Package                      Architecture              Version                        Repository                  Size
========================================================================================================================
Installing:
 grafana                      x86_64                    9.2.6-1                        grafana                     92 M
Installing dependencies:
 chkconfig                    x86_64                    1.20-2.el9                     baseos                     162 k

Transaction Summary
========================================================================================================================
Install  2 Packages

Total size: 92 M
Installed size: 309 M
Is this ok [y/N]: y
Downloading Packages:
[SKIPPED] grafana-9.2.6-1.x86_64.rpm: Already downloaded
[SKIPPED] chkconfig-1.20-2.el9.x86_64.rpm: Already downloaded
grafana                                                                                 9.4 kB/s | 1.7 kB     00:00
Importing GPG key 0x24098CB6:
 Userid     : "Grafana <info@grafana.com>"
 Fingerprint: 4E40 DDF6 D76E 284A 4A67 80E4 8C8C 34C5 2409 8CB6
 From       : https://rpm.grafana.com/gpg.key
Is this ok [y/N]: y
Key import failed (code 2). Failing package is: grafana-9.2.6-1.x86_64
 GPG Keys are configured as: https://rpm.grafana.com/gpg.key
The downloaded packages were saved in cache until the next successful transaction.
You can remove cached packages by executing 'dnf clean packages'.
Error: GPG check FAILED

Thanks a lot, @sivan for reporting this one too :+1:

Seems like there is an update to the original GitHub bug as I do not see the beta packages anymore but that may had to break the GPG keys I also tested it out and got the same problem as you have shown.

WORKAROUND

Step1

sett gpgcheck=0 in the .repo file (/etc/yum.repos.d/grafana.repo)

Step 2

then clean the package manager cache

dnf clean all and dnf clean metadata

Step 3

Build new cache

dnf makecache

Step 4

dnf install grafana
Install the grafana and this time it will not give the GPG key error

1 Like