Solved: Error populating transaction, retrying RHEL/CentOS 7/8


Written by - Deepak Prasad

Trying to install RHEL/CentOS 7/8 using a customized repository? Now this repository can be from a customized ISO or directory. We see this error "Error populating transaction, retrying" while installing RHEL/CentOS 7/8 if necessary rpm packages are missing from the repository required for installation.

I first got this error when I was trying to create a customised RHEL/CentOS 7/8 ISO with set of custom rpms, so I thought I should put the solution here to help anyone else facing the same error.

Now I have simulated this error in my environment where I use kickstart and a custom repo for RHEL/CentOS 7 installation. You can enable serial console on your setup to collect the console logs for further debugging.

Alternatively you can also enable SSH during installation so that you can connect to the client using SSH to check the progress rather than connecting to the GUI console.

NOTE:
It is recommended that you configure network enable SSH during installation as it make troubleshooting these issues easier

 

How to debug "Error populating transaction anaconda is retrying"

After configuring storage you will see "Starting package installation process", next the package installation fails with anaconda is retrying error output which you will see on the console when RHEL/CentOS installation fails due to missing rpm dependencies in the repository.

Starting package installation process
 Error populating transaction, retrying (1/10)

<Output trimmed> 

 Error populating transaction, retrying (10/10)
================================================================================
================================================================================
Error

The following error occurred while installing.  This is a fatal error and
installation will be aborted.

 Error populating transaction after 10 retries: failure: NetworkManager-config-
server-1.8.0-11.el7_4.noarch.rpm from updates: [Errno 256] No more mirrors to
try.

 

Analysing anaconda logs from installation

In my case from this error output we can figure out the problem is somewhere related to NetworkManager-config rpm. But in some other complex environment you may not get entire details on the console so you can check anaconda logs.

  • Connect to the console of the impacted server
  • By default installation happens on the first terminal so we must connect to any other terminal to get a shell prompt. Press Alt+F2 to connect to second terminal
  • Or alternatively you can configure VSP with serial console and then you can use any SSH Client to connect to the server
  • The installation logs are available inside /tmp and the rpm installation related logs are under /tmp/packaging.log
  • In this log file you should see output like below:

From /tmp/packaging.log

09:54:27,428 DEBUG packaging: Error populating transaction, retrying (1/10)
09:54:27,428 DEBUG packaging: Member: libXext.x86_64 0:1.3.3-3.el7 - u
09:54:27,429 DEBUG packaging: Adding Package libXext-1.3.3-3.el7.x86_64 in mode u
09:54:27,429 DEBUG packaging: Member: perl-HTTP-Tiny.noarch 0:0.033-3.el7 - u
09:54:27,430 DEBUG packaging: Adding Package perl-HTTP-Tiny-0.033-3.el7.noarch in mode u
09:54:27,430 DEBUG packaging: Member: NetworkManager-config-server.noarch 1:1.8.0-11.el7_4 - u

10:02:58,676 ERR packaging:  Error populating transaction after 10 retries: failure: NetworkManager-config-server-1.8.0-11.el7_4.noarch.rpm from updates: [Errno 256] No more mirrors to try.
10:02:58,677 DEBUG packaging: file:///run/install/repo/updates/NetworkManager-config-server-1.8.0-11.el7_4.noarch.rpm: [Errno 14] curl#37 - "Couldn't open file /run/install/repo/updates/NetworkManager-config-server-1.8.0-11.el7_4.noarch.rpm"
10:02:58,677 DEBUG packaging: QUIT:

Now here we see the issue is quite straight forward i.e. NetworkManager-config-server-1.8.0-11.el7_4.noarch.rpm is not available in our repository.

 

How to solve this issue?

To fix this problem, add this missing rpm to your repository and re-execute createrepo to update the yum database. Since we know that all the installation related logs are stored under /tmp, you can get the list of repositories used during installation by checking below directory content on the server where the installation failed

# ls -l /tmp/yum.repos.d/
total 16
-rw-r--r--. 1 root root 93 Feb 21 09:11 ExtraPackages.repo
-rw-r--r--. 1 root root 69 Feb 21 09:11 anaconda.repo
-rw-r--r--. 1 root root 75 Feb 21 09:11 updates.repo

Here anaconda.repo is the default repo while updates.repo and ExtraPackages.repo is my additional repository which I am creating using my kickstart file. From the error seen in packaging.log "Couldn't open file /run/install/repo/updates/NetworkManager-config-server-1.8.0-11.el7_4.noarch.rpm" we know the missing rpm is from updates repo

After you have placed the rpm in "updates" repo path, update the yum database by executing below command

# createrepo /your/repo/path/.

This will update/create repodata directory inside /your/repo/path/

Now you can re-attempt the installation.

 

Lastly I hope the steps from the article to starting package installation process, troubleshoot error populating transaction, anaconda is retrying on RHEL/CentOS 7/8 Linux was helpful. So, let me know your suggestions and feedback using the comment section.

Views: 20

Deepak Prasad

He is the founder of GoLinuxCloud and brings over a decade of expertise in Linux, Python, Go, Laravel, DevOps, Kubernetes, Git, Shell scripting, OpenShift, AWS, Networking, and Security. With extensive experience, he excels in various domains, from development to DevOps, Networking, and Security, ensuring robust and efficient solutions for diverse projects. You can reach out to him on his LinkedIn profile or join on Facebook page.

Can't find what you're searching for? Let us assist you.

Enter your query below, and we'll provide instant results tailored to your needs.

If my articles on GoLinuxCloud has helped you, kindly consider buying me a coffee as a token of appreciation.

Buy GoLinuxCloud a Coffee

For any other feedbacks or questions you can send mail to admin@golinuxcloud.com

Thank You for your support!!

Leave a Comment