Bug 1576944 - dnf update fails with transaction check error, file conflicts
Summary: dnf update fails with transaction check error, file conflicts
Keywords:
Status: CLOSED DUPLICATE of bug 1653683
Alias: None
Product: Fedora
Classification: Fedora
Component: nss
Version: 28
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Daiki Ueno
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-05-10 19:32 UTC by Tim Elliott
Modified: 2018-12-18 08:58 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-12-18 08:58:41 UTC
Type: Bug


Attachments (Terms of Use)

Description Tim Elliott 2018-05-10 19:32:21 UTC
Description of problem:

This is a fresh install of Fedora 28. When running dnf update today, I got failures related to the nss package.

Here is the console output:


[root@localhost-live log]# dnf clean all
0 files removed
[root@localhost-live log]# dnf update -v
Loaded plugins: builddep, config-manager, copr, debug, debuginfo-install, download, generate_completion_cache, needs-restarting, playground, repoclosure, repograph, repomanage, reposync
DNF version: 2.7.5
cachedir: /var/cache/dnf
Fedora 28 - x86_64 - Updates                                     1.4 MB/s | 6.0 MB     00:04    
updates: using metadata from Wed 09 May 2018 02:11:35 PM PDT.
Fedora 28 - x86_64                                               2.0 MB/s |  60 MB     00:30    
not found deltainfo for: Fedora 28 - x86_64
not found updateinfo for: Fedora 28 - x86_64
fedora: using metadata from Thu 26 Apr 2018 04:12:28 AM PDT.
google-chrome                                                     20 kB/s | 3.8 kB     00:00    
not found deltainfo for: google-chrome
not found updateinfo for: google-chrome
google-chrome: using metadata from Wed 09 May 2018 10:45:41 AM PDT.
Last metadata expiration check: 0:00:00 ago on Thu 10 May 2018 12:28:54 PM PDT.
Missing file *modules.yaml in metadata cache dir: /var/cache/dnf/updates-8bd9ef368505a5fd
Missing file *modules.yaml in metadata cache dir: /var/cache/dnf/fedora-f21308f6293b3270
Missing file *modules.yaml in metadata cache dir: /var/cache/dnf/google-chrome-eb0d6f10ccbdafba
Completion plugin: Generating completion cache...
--> Starting dependency resolution
---> Package nss.i686 3.36.1-1.0.fc28 will be upgraded
---> Package nss.i686 3.36.1-1.1.fc28 will be an upgrade
--> Finished dependency resolution
Dependencies resolved.
=================================================================================================
 Package           Arch               Version                        Repository             Size
=================================================================================================
Upgrading:
 nss               i686               3.36.1-1.1.fc28                updates               716 k

Transaction Summary
=================================================================================================
Upgrade  1 Package

Total download size: 716 k
Is this ok [y/N]: y
Downloading Packages:
nss-3.36.1-1.0.fc28_3.36.1-1.1.fc28.i686.drpm                    156 kB/s |  87 kB     00:00    
/usr/share/man/man5/cert8.db.5.gz: read error
(tried to read 909 bytes from offset 0)
cannot reconstruct rpm from disk files
Some packages were not downloaded. Retrying.
nss-3.36.1-1.1.fc28.i686.rpm                                     619 kB/s | 716 kB     00:01    
-------------------------------------------------------------------------------------------------
Total                                                            342 kB/s | 803 kB     00:02     
Failed Delta RPMs increased 0.7 MB of updates to 0.8 MB (-12.1% wasted)
Running transaction check
Transaction check succeeded.
Running transaction test
The downloaded packages were saved in cache until the next successful transaction.
You can remove cached packages by executing 'dnf clean packages'.
Error: Transaction check error:
  file /usr/share/man/man5/cert8.db.5.gz from install of nss-3.36.1-1.1.fc28.i686 conflicts with file from package nss-3.36.1-1.0.fc28.x86_64
  file /usr/share/man/man5/cert9.db.5.gz from install of nss-3.36.1-1.1.fc28.i686 conflicts with file from package nss-3.36.1-1.0.fc28.x86_64
  file /usr/share/man/man5/key3.db.5.gz from install of nss-3.36.1-1.1.fc28.i686 conflicts with file from package nss-3.36.1-1.0.fc28.x86_64
  file /usr/share/man/man5/key4.db.5.gz from install of nss-3.36.1-1.1.fc28.i686 conflicts with file from package nss-3.36.1-1.0.fc28.x86_64
  file /usr/share/man/man5/pkcs11.txt.5.gz from install of nss-3.36.1-1.1.fc28.i686 conflicts with file from package nss-3.36.1-1.0.fc28.x86_64
  file /usr/share/man/man5/secmod.db.5.gz from install of nss-3.36.1-1.1.fc28.i686 conflicts with file from package nss-3.36.1-1.0.fc28.x86_64


How reproducible:

Not sure if this could be reproduced if done again today, but this is pretty much what I did: 

1. Install Fedora 28
2. # dnf install wine (yesterday)
3. # dnf update (today)

Actual results:

Error message above.

Expected results:

nss gets updated.

Additional Notes:

Installing wine installs a bunch of i686 packages, apparently including nss.i686.

Comment 1 Elio Maldonado Batiz 2018-05-14 15:41:44 UTC
(In reply to Tim Elliott from comment #0)

I have tried to reproduce this problem various ways and could't.

> Description of problem:
> 
> This is a fresh install of Fedora 28. When running dnf update today, I got
> failures related to the nss package.
> 
> Here is the console output:
> 
.....
> 
> ====================
> Upgrading:
>  nss               i686               3.36.1-1.1.fc28                updates
> 716 k
...
> 
> Transaction Summary
> =============================================================================
> ====================
> Upgrade  1 Package
> Total download size: 716 k
> Is this ok [y/N]: y
> Downloading Packages:
> nss-3.36.1-1.0.fc28_3.36.1-1.1.fc28.i686.drpm                    156 kB/s | 
> 87 kB     00:00    
> /usr/share/man/man5/cert8.db.5.gz: read error
> (tried to read 909 bytes from offset 0)
> cannot reconstruct rpm from disk files
> Some packages were not downloaded. Retrying.
> nss-3.36.1-1.1.fc28.i686.rpm                                     619 kB/s |
> 716 kB     00:01    
> -----------------------------------------------------------------------------
> --------------------
> Total                                                            342 kB/s |
> 803 kB     00:02     
> Failed Delta RPMs increased 0.7 MB of updates to 0.8 MB (-12.1% wasted)
> Running transaction check
> Transaction check succeeded.
> Running transaction test
> The downloaded packages were saved in cache until the next successful
> transaction.
> You can remove cached packages by executing 'dnf clean packages'.
> Error: Transaction check error:
>   file /usr/share/man/man5/cert8.db.5.gz from install of
> nss-3.36.1-1.1.fc28.i686 conflicts with file from package
> nss-3.36.1-1.0.fc28.x86_64

I notice that you have nss-3.36.1-1.0 but only the i686 is getting updated and that causes the problem. I have seen this problem before but I haven't seen it in a very long time. 

> 
> 
> How reproducible:
> 
> Not sure if this could be reproduced if done again today, but this is pretty
> much what I did: 
> 
> 1. Install Fedora 28
> 2. # dnf install wine (yesterday)
> 3. # dnf update (today)

You could you try
# dnf --refresh update

That way the cache get's clean up first and hopefully both the i686 and x86_64 will get included in the update. 

Sometimes I do
# dnf --refresh --best --allowerasing update
but I bet is not needed.

> 
> Installing wine installs a bunch of i686 packages, apparently including
> nss.i686.

Yes, wine needs to support both as in Window there a still a lot 32-bit only applications.

Comment 2 Tim Elliott 2018-05-14 16:03:55 UTC
# dnf --refresh --best --allowerasing update -y
Last metadata expiration check: 0:00:00 ago on Mon 14 May 2018 09:03:16 AM PDT.
Dependencies resolved.
================================================================================================================================================
 Package                       Arch                           Version                                   Repository                         Size
================================================================================================================================================
Upgrading:
 nss                           i686                           3.36.1-1.1.fc28                           updates                           716 k

Transaction Summary
================================================================================================================================================
Upgrade  1 Package

Total size: 716 k
Downloading Packages:
[SKIPPED] nss-3.36.1-1.1.fc28.i686.rpm: Already downloaded                                                                                     
Running transaction check
Transaction check succeeded.
Running transaction test
The downloaded packages were saved in cache until the next successful transaction.
You can remove cached packages by executing 'dnf clean packages'.
Error: Transaction check error:
  file /usr/share/man/man5/cert8.db.5.gz from install of nss-3.36.1-1.1.fc28.i686 conflicts with file from package nss-3.36.1-1.0.fc28.x86_64
  file /usr/share/man/man5/cert9.db.5.gz from install of nss-3.36.1-1.1.fc28.i686 conflicts with file from package nss-3.36.1-1.0.fc28.x86_64
  file /usr/share/man/man5/key3.db.5.gz from install of nss-3.36.1-1.1.fc28.i686 conflicts with file from package nss-3.36.1-1.0.fc28.x86_64
  file /usr/share/man/man5/key4.db.5.gz from install of nss-3.36.1-1.1.fc28.i686 conflicts with file from package nss-3.36.1-1.0.fc28.x86_64
  file /usr/share/man/man5/pkcs11.txt.5.gz from install of nss-3.36.1-1.1.fc28.i686 conflicts with file from package nss-3.36.1-1.0.fc28.x86_64
  file /usr/share/man/man5/secmod.db.5.gz from install of nss-3.36.1-1.1.fc28.i686 conflicts with file from package nss-3.36.1-1.0.fc28.x86_64

Error Summary
-------------

Comment 3 Tim Elliott 2018-05-14 16:17:25 UTC
After manually removing nss-3.36.1-1.0.fc28.x86_64, dnf update works again:

# sudo dnf remove nss-3.36.1-1.0.fc28.x86_64
Dependencies resolved.
================================================================================================================================================
 Package                          Arch                          Version                                   Repository                       Size
================================================================================================================================================
Removing:
 nss                              x86_64                        3.36.1-1.0.fc28                           @updates                        1.9 M
Removing dependent packages:
 nss-tools                        x86_64                        3.36.1-1.0.fc28                           @updates                        2.1 M

Transaction Summary
================================================================================================================================================
Remove  2 Packages

Freed space: 3.9 M
Is this ok [y/N]: y
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
  Preparing        :                                                                                                                        1/1 
  Erasing          : nss-tools-3.36.1-1.0.fc28.x86_64                                                                                       1/2 
  Erasing          : nss-3.36.1-1.0.fc28.x86_64                                                                                             2/2 
  Running scriptlet: nss-3.36.1-1.0.fc28.x86_64                                                                                             2/2 
  Verifying        : nss-tools-3.36.1-1.0.fc28.x86_64                                                                                       1/2 
  Verifying        : nss-3.36.1-1.0.fc28.x86_64                                                                                             2/2 

Removed:
  nss.x86_64 3.36.1-1.0.fc28                                          nss-tools.x86_64 3.36.1-1.0.fc28                                         

Complete!


# sudo dnf update
Last metadata expiration check: 0:12:09 ago on Mon 14 May 2018 09:03:16 AM PDT.
Dependencies resolved.
================================================================================================================================================
 Package                            Arch                          Version                                 Repository                       Size
================================================================================================================================================
Upgrading:
 nss                                i686                          3.36.1-1.1.fc28                         updates                         716 k
Removing dependent packages:
 nss-sysinit                        x86_64                        3.36.1-1.0.fc28                         @updates                         14 k

Transaction Summary
================================================================================================================================================
Upgrade  1 Package
Remove   1 Package

Total size: 716 k
Is this ok [y/N]: y
Downloading Packages:
[SKIPPED] nss-3.36.1-1.1.fc28.i686.rpm: Already downloaded                                                                                     
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
  Preparing        :                                                                                                                        1/1 
  Upgrading        : nss-3.36.1-1.1.fc28.i686                                                                                               1/3 
  Running scriptlet: nss-3.36.1-1.1.fc28.i686                                                                                               1/3 
  Cleanup          : nss-3.36.1-1.0.fc28.i686                                                                                               2/3 
  Running scriptlet: nss-3.36.1-1.0.fc28.i686                                                                                               2/3 
  Erasing          : nss-sysinit-3.36.1-1.0.fc28.x86_64                                                                                     3/3 
  Running scriptlet: nss-sysinit-3.36.1-1.0.fc28.x86_64                                                                                     3/3 
  Verifying        : nss-3.36.1-1.1.fc28.i686                                                                                               1/3 
  Verifying        : nss-3.36.1-1.0.fc28.i686                                                                                               2/3 
  Verifying        : nss-sysinit-3.36.1-1.0.fc28.x86_64                                                                                     3/3 

Removed:
  nss-sysinit.x86_64 3.36.1-1.0.fc28                                                                                                            

Upgraded:
  nss.i686 3.36.1-1.1.fc28                                                                                                                      

Complete!
[root@localhost-live ~]#

Comment 4 Elio Maldonado Batiz 2018-05-14 16:34:21 UTC
Tim, If you execute "rpm -q nss nss-softokn nss-util", what does it show?

Comment 5 Elio Maldonado Batiz 2018-05-14 17:45:15 UTC
(In reply to Elio Maldonado Batiz from comment #4)
Never mind, just did in a system similiar to yours and got
nss-3.36.1-1.1.fc28.x86_64
nss-3.36.1-1.1.fc28.i686
nss-softokn-3.36.1-1.1.fc28.x86_64
nss-softokn-3.36.1-1.1.fc28.i686
nss-util-3.36.1-1.0.fc28.x86_64
nss-util-3.36.1-1.0.fc28.i686

all at 3.36.1 which we wanted.

When doing a fresh install or a release upgrade I tend to do to an update before installing additional packages as it may help avoid such problems as having out synch packages for multi-arch stuff. Thank you Tim for reporting and trying things out.

Comment 6 Kai Engert (:kaie) (inactive account) 2018-05-24 18:29:51 UTC
To summarize:

- you had both nss*.i686 and nss*.x86_64 installed
- newer updates for both were available
- dnf update attempted to update nss*.i686, only,
  but that doesn't work, because the conflicts with duplicate files
  only are avoided if both architectures get updated at the same time.
- we don't know why dnf attempted to update i686, only

Is this correct?

Instead of removing nss.x86_64, explicitly telling dnf to upgrade all in parallel might have worked, too.

IIUC your immediate problem is solved, but there might be a general underlying bug. The bug might be either in dnf, or in incorrect dependencies in the nss* packages.

We'd have to attempt to reproduce this to solve it.

Comment 8 Daiki Ueno 2018-12-18 08:58:41 UTC
This is turning out to be a dnf issue.  Closing as a duplicate.

*** This bug has been marked as a duplicate of bug 1653683 ***


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