Pacman troubleshooting

From ParabolaWiki
Jump to: navigation, search

1 Software Installation

Various issues relating to the download and installation of software packages from the Parabola repositories are dealt with here.

1.1 "Unrecognized archive format" Error

It has ocurred more than once, an update is issuing these messages in a seemingly never ending stream. Pacman could not open file: sync files

error: could not open file /var/lib/pacman/sync/core.db: Unrecognized archive format
error: could not open file /var/lib/pacman/sync/extra.db: Unrecognized archive format
error: could not open file /var/lib/pacman/sync/community.db: Unrecognized archive format
error: could not open file /var/lib/pacman/sync/multilib.db: Unrecognized archive format

The error relates to a mismatch in the information contained in the db files at the mentioned location and the db files at the first mirror in your mirrorlist. Pacman checks a package in the database and sees if the signature file matches the one in the database. If it does not, then pacman will say the package is corrupted.

While it sometimes is possible to fix the issue simply by deleting the files and the running a pacman update it far from every time.

1.1.1 One recipe for fixing this

It is important to ensure that your key-rings are current; in order to to maintain the chain of trust between the key-rings and the packages, so that pacman can verify the authenticity of the packages.

You can find the exact package names by browsing to the following URL

https://repomirror.parabola.nu/pool/packages/ (look for the current 'archlinux-keyring')
https://repo.parabola.nu/pool/archlinux32/    (look for the current 'archlinux32-keyring')
https://repomirror.parabola.nu/pool/parabola/ (look for the current 'parabola-keyring')

Run the commands below, replacing "YYYYMMDD" and "R" with the info found at the above repos

$ sudo pacman -U https://repomirror.parabola.nu/pool/packages/archlinux-keyring-YYYYMMDD-R-any.pkg.tar.xz
$ sudo pacman -U https://mirror.archlinux32.org/pool/archlinux32-keyring-transition-YYYYMMDD-R-any.pkg.tar.xz
$ sudo pacman -U https://repomirror.parabola.nu/pool/parabola/parabola-keyring-YYYYMMDD-R-any.pkg.tar.xz

Remove your faulty databases

$ sudo rm -f /var/lib/pacman/sync/*

Refresh the databases and run a full system update

$ sudo pacman -Syu

1.2 "Unable to lock database" Error

When downloading and installing software from the repositories, a special database lock file will be created in order to ensure that the current installation process is the only one running at that time. Otherwise, attempting to install multiple files from multiple sources simultaneously may corrupt the downloaded files, cause file conflicts - or worse still - damage your system. Once the installation has been completed, the lock file will then be automatically deleted. This error may therefore occur due to two possible reasons:

  • Another installation is still taking place and has not yet finished, or
  • A previous installation attempt had not finished properly (e.g. due to being aborted early)

It is therefore wise to first check to ensure that another installation is not (or had not been) in process at the time of the error. When satisfied that this is not the case, then the database lock file can be manually deleted. To do so, open up the terminal and enter the following command:

sudo rm /var/lib/pacman/db.lck

Once done, you should now be able to successfully re-attempt your intended installation.


1.3 Errors about Keys

This article is a candidate for merging.
It is suggested that this page or section be merged with Parabola Keyring. (Discuss)

We all have our own unique signatures which are used to authenticate who we are and to prevent fraudulent or even malicious activities by others. This is also the case with software packages available from the software repositories. They all contain encrypted codes (signature keys) unique to their developers to ensure that they are authentic and not malicious in nature.

During the installation process, once any software packages have been downloaded, your system will first check their signature keys to ensure that they are authentic prior to actually installing them. If a signature key cannot be verified for any reason, then the installation process will be aborted. This problem will usually occur due to:

  • one or more signature keys contained in your system's database being revoked, changed, corrupted, or out of date
  • one or more software packages not having been signed off properly when placed in a repository

Where a package has not been signed off properly before being placed in a repository, it will be the responsibility of the developer(s) to correct this. However, as this problem will be more than likely due to a problem with your system's verification of a signature key, this can be solved in three easy steps. Working net connection is required. Once you have opened your terminal:

Please, follow Parabola_Keyring#pacman-key --populate does not work. Then, try to run sudo pacman -Syu in your regular system to see if the errors were resolved.

1.4 "Configuration file...not recognized" Error

Parabola's package manager - pacman - uses a file called mirrorlist to tell it the internet addresses of the Parabola servers in order to download updates and software applications from them. This error will therefore occur if one or more server addresses contained in the mirrorlist file have not been listed properly, resulting in pacman being unable to connect to them. Another tell-tale sign is that this problem will also be encountered immediately after:

  • Installing Parabola and editing the mirrorlist file during installation, or
  • Editing the mirrorlist file at a later time.
    sudo pacman-mirrors --country-list
    This can also be done manually by editing /etc/pacman.d/mirrorlist. Please, read the documentation within the file.


1.5 "GPGME error: No data" Error

The most likely cause of this issue is that an error or corruption has been detected by pacman in one or more software packages being downloaded. Package signatures and checksums are used to verify the validity of downloaded software, and should they fail, the installation attempt will be aborted to protect your system until the matter is resolved.


1.5.1 Option 1: Basic Resolution

To resolve this issue, first follow the basic procedure provided below. If this does not work, then there is a more comprehensive procedure available.


  1. Resynchronise with the Parabola servers to ensure that everything is up to date by entering the command:
    sudo pacman -Syy
  2. Clear out the software packages downloaded during the aborted installation by entering the command:
    sudo pacman -Sc
  3. Re-attempt the aborted download.


1.5.2 Option 2: Comprehensive Resolution

If the basic procedure still does not resolve the matter, further steps are available:

  1. Resynchronise with the Parabola servers to ensure that everything is up to date by entering the command:
    sudo pacman -Syy
  2. Remove current keys
    sudo mv /etc/pacman.d/gnupg /tmp
  3. Initialize the keys' database
    sudo pacman-key --init
  4. Reload the signature keys by entering the command:
    sudo pacman-key --populate archlinux parabola
  5. Refresh and update the signature keys by entering the command:
    sudo pacman-key --refresh-keys
  6. Clear out the software packages downloaded during the aborted installation
    Warning: This command (optional) clears the pacman cache, and which would make it harder to downgrade to a previous version of a package if required. Instead packages that are causing signing errors can be removed individually when upgrading (see man pacman and look for the -c, --clear entry).
    sudo pacman -Sc
  7. Re-attempt the aborted download.

Another alternative is to do this in a live system

1.6 "keyserver refresh failed: No dirmngr" Error

Try running the following command:

sudo dirmngr </dev/null


2 See Also