Software⏱️ 3 min read📅 2026-06-11

How to Fix: apt-get update: An error occurred during the signature verification

apt-get update error due to missing public key for ROS repository.

Quick Answer: Update the ROS repository by adding the missing public key and then run apt-get update.

The 'apt-get update' command has encountered an error during signature verification, which affects users trying to update their system packages using the 'apt-get' package manager. This issue primarily occurs when the public key for a specific repository is not available or has expired.

This error can be frustrating as it prevents users from updating their systems and installing new packages, potentially leading to security vulnerabilities and outdated software.

💡 Why You Are Getting This Error

  • The primary reason for this error is that the public key for the specified repository (e.g., ros2.org) has not been updated or is not available. This can happen due to various reasons such as the key being expired, revoked, or not being properly configured.
  • An alternative reason could be that the system clock is not set correctly or the GPG keys are not properly configured, leading to a mismatch between the expected and actual public keys.

🛠️ Step-by-Step Verified Fixes

Update the System Clock and Add Missing Public Keys

  1. Step 1: Open the terminal and run the command 'sudo apt update' to update the package list. This will allow you to see if there are any available updates.
  2. Step 2: Next, run the command 'sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys F42ED6FBAB17C654' to add the missing public key for the ros2.org repository. This may take a few minutes to complete.
  3. Step 3: Once the key is added, try running 'apt-get update' again to see if the error persists.

Update the Package List and Ignore Unverified Signatures

  1. Step 1: Run the command 'sudo apt update --fix-missing' to update the package list with the available index files.
  2. Step 2: Next, run the command 'apt-get update' again to see if the error persists. If it does, you can ignore the unverified signatures by running 'apt-mark showmanual ' and then removing the package from your system using 'sudo apt remove '.

✨ Wrapping Up

To resolve the 'apt-get update' error during signature verification, try updating the system clock and adding any missing public keys. If that doesn't work, you can update the package list and ignore unverified signatures. By following these steps, you should be able to successfully update your system packages.

Did this fix your problem?

If not, try searching for specific error codes.

🔍 Search Error Database

❓ Frequently Asked Questions