Bug 1438503 - system upgrade from Fedora 25 to Rawhide fails due to rpm-gpg key missing
Summary: system upgrade from Fedora 25 to Rawhide fails due to rpm-gpg key missing
Keywords:
Status: CLOSED EOL
Alias: None
Product: Fedora
Classification: Fedora
Component: fedora-repos
Version: 26
Hardware: x86_64
OS: Linux
unspecified
high
Target Milestone: ---
Assignee: Dennis Gilmore
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-04-03 14:57 UTC by Joe Julian
Modified: 2018-05-29 12:33 UTC (History)
18 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of: 1310891
Environment:
Last Closed: 2018-05-29 12:33:05 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Joe Julian 2017-04-03 14:57:37 UTC
This is still true for upgrading any release to rawhide. 

Despite what Jaroslav Mracek stated, the fedora-repos-rawhide package only has one file:

# rpm -ql fedora-repos-rawhide
/etc/yum.repos.d/fedora-rawhide.repo

This is still a bug and still needs fixed. Either by dnf-plugin-system-upgrade, fedora-repos-rawhide, or on https://fedoraproject.org/wiki/DNF_system_upgrade

+++ This bug was initially created as a clone of Bug #1310891 +++

Description of problem:
I was attempting to upgrade my Fedora 23 system to Fedora rawhide and got these messages:

dnf -y system-upgrade download --allowerasing --releasever=rawhide

warning: /var/lib/dnf/system-upgrade/389-ds-base-1.3.4.7-1.fc24.x86_64.rpm: Header V3 RSA/SHA256 Signature, key ID 81b46521: NOKEY
Curl error (37): Couldn't read a file:// file for file:///etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-rawhide-x86_64 [Couldn't open file /etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-rawhide-x86_64]

The procedure is at: http://www.unixmen.com/fedora-23-is-out-upgrade-to-fedora-23-from-fedora-22/

Version-Release number of selected component (if applicable):

dnf-1.1.6-2.fc23.noarch
How reproducible:
always

Steps to Reproduce:
1.follow the directions but substitute "23" with "rawhide"
2.pray a lot
3.

Actual results:


Expected results:


Additional info:

--- Additional comment from Jaroslav Mracek on 2016-02-29 07:46:08 EST ---

Please, according to fedora wiki (https://fedoraproject.org/wiki/DNF_system_upgrade), it is recommended to use dnf -y system-upgrade download --allowerasing --releasever=24, but at the present time it is --releasever=25. Also you can install fedora-repos-rawhide package to get their gpg-key. Please if it doesn't help, please reopen this bug report.

--- Additional comment from Todd Warner on 2017-02-11 16:09:57 EST ---

Note. "fedora-repos-rawhide" fails to be installed if you follow these instructions. https://fedoraproject.org/wiki/DNF_system_upgrade and choose rawhide as your target.

Fedora 25 to Rawhide...

```
sudo dnf install dnf-plugin-system-upgrade

# Systemtap got in the way, so needed --allowerasing
sudo dnf system-upgrade download --refresh --releasever=rawhide --allowerasing
```

And... selected "Y" to install everything, but...

```
Curl error (37): Couldn't read a file:// file for file:///etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-rawhide-x86_64 [Couldn't open file /etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-rawhide-x86_64]
```

So, either the existing process needs to do that for you because --releasever=rawhide -- or the process instruction needs to be fixed to add that step.

Thanks. -t

--- Additional comment from Todd Warner on 2017-02-11 16:41:54 EST ---

I spoke too soon. That didn't work either.


That did not populate /etc/pki/rpm-gpg with a rawhide key. And... I can't find one anywhere on the Fedora site or anywhere else for that matter.

I had to resort to --nogpg

Comment 1 squimrel+bugzilla 2017-08-20 18:06:46 UTC
Even worse --nogpg didn't even work for me because after:

```
dnf system-upgrade reboot --nogpg
```

It'll complain anyways.

Thanks to help by robatino in #fedora-qa I was able to gather the key for the installation as follows (assuming that fedora-repos-rawhide is installed):

```
# Download rawhide package that has the key.
dnf download --disablerepo=\* --enablerepo=rawhide fedora-repos
# Copy it out of the package into the correct location.
rpm2cpio ./fedora-repos-28-0.1.noarch.rpm | cpio -iv --to-stdout ./etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-28-primary | tee /etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-28-primary
# Create the softlink that marks it as the rawhide key.
ln -s /etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-28-primary /etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-rawhide-$(uname -p)
```

Comment 2 Andre Robatino 2017-08-21 01:02:37 UTC
Since squimrel was using F26, updating the Version to 26.

Comment 3 Jaroslav Mracek 2017-08-22 18:02:06 UTC
I see your problem. I combine information from https://fedoraproject.org/wiki/Upgrading_Fedora_using_package_manager?rd=Upgrading_Fedora_using_yum#To_Rawhide and https://fedoraproject.org/wiki/DNF_system_upgrade and I have a solution:

# dnf upgrade --refresh
# dnf install dnf-plugins-core fedora-repos-rawhide
# dnf config-manager --set-disabled fedora updates updates-testing
# dnf config-manager --set-enabled rawhide
# dnf clean -q dbcache packages metadata
As a source for gpg-keys, fedora-repos can be used
# dnf download fedora-repos 
# rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-27-primary
# rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-28-primary
# dnf system-upgrade download --refresh --releasever=28
# sudo dnf system-upgrade reboot

Hope that it works.

Comment 4 Jaroslav Mracek 2017-08-22 18:08:18 UTC
Unfortunately there is a problem with gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-$releasever-$basearch in case releasever "rawhide" is used. Releasever "rawhide" for metalink is valid but not for gpgkey location. Therefore I change a component to fedora-repos to ask if they could come with solution or unification.

Comment 5 Sergio Basto 2017-11-09 22:30:19 UTC
Hi , update Fedora 27 to Rawhide fails due to rpm-gpg key missing 

Curl error (37): Couldn't read a file:// file for file:///etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-rawhide-x86_64 

rpm -q fedora-gpg-keys-27-1.noarch -l | grep rawhide
(nothing) 

I fixed with 

ln -sf /etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-28-primary /etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-rawhide-x86_64 


warning: /home/lib/system-upgrade/fedora-ebd04873699a984e/packages/bind-9.11.1-6.P3.fc27.x86_64.rpm: Header V3 RSA/SHA256 Signature, key ID 9db62fb1: NOKEY
Importing GPG key 0x9DB62FB1:
 Userid     : "Fedora 28 (28) <fedora-28>"
 Fingerprint: 128C F232 A937 1991 C8A6 5695 E08E 7E62 9DB6 2FB1
 From       : /etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-rawhide-x86_64
Key imported successfully

Comment 6 Fedora End Of Life 2018-05-03 08:14:22 UTC
This message is a reminder that Fedora 26 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 26. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as EOL if it remains open with a Fedora  'version'
of '26'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version'
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not
able to fix it before Fedora 26 is end of life. If you would still like
to see this bug fixed and are able to reproduce it against a later version
of Fedora, you are encouraged  change the 'version' to a later Fedora
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's
lifetime, sometimes those efforts are overtaken by events. Often a
more recent Fedora release includes newer upstream software that fixes
bugs or makes them obsolete.

Comment 7 Fedora End Of Life 2018-05-29 12:33:05 UTC
Fedora 26 changed to end-of-life (EOL) status on 2018-05-29. Fedora 26
is no longer maintained, which means that it will not receive any
further security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.


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