Leapp Upgrade of Satellite failed with error : FileNotFoundError: [Errno 2] No such file or directory: '/var/cache/dnf/metadata_lock.pid'

Solution Verified - Updated -

Issue

  • Unable to upgrade Red Hat Satellite server from RHEL-8 to RHEL-9 using leapp utility. The following error is reported during the upgrade:

    File "/usr/lib/python3.6/site-packages/dnf/base.py", line 429, in fill_sack
    self.repos.all().disable()
    File "/usr/lib/python3.6/site-packages/dnf/lock.py", line 147, in __exit__
    os.unlink(self.target)
    FileNotFoundError: [Errno 2] No such file or directory: '/var/cache/dnf/metadata_lock.pid'
    

Environment

  • Red Hat Satellite 6
  • Red Hat Enterprise Linux 8 with leapp-0.19.0-1.el8_10.noarch
  • Red Hat Enterprise Linux 9 with leapp-0.20.0-1.el9.noarch

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content