skip to Main Content

Problem:

I tried to create VM’s and then update it to install the azure-cli but am facing this NO_PUBKEY error.

  The following signatures couldn't be verified because the public key is not available: NO_PUBKEY EB3E94ADBE1229CF

My Ubuntu Configuration:

NAME="Ubuntu"

VERSION="18.04.5 LTS (Bionic Beaver)"

ID=ubuntu

ID_LIKE=debian

PRETTY_NAME="Ubuntu 18.04.5 LTS"


Steps to recreate:

  1. Create a Azure VM
    • Image: enter image description here
    • Size: enter image description here
    • And the rest as the default configurations
  2. curl -sL https://aka.ms/InstallAzureCLIDeb | sudo bash &
  3. sudo apt-get update

What other things I did to solve this problem:

  1. Created another VM with same configuration and got the same problem. So I think that the problem was not only to that particular VM

2

Answers


  1. Chosen as BEST ANSWER

    Okay, after much research I found out that the problem existed only on certain Nvidia Images and not on the barebone Linux images. So I figured that there must be something wrong with the trusted key itself. So, these are the steps that I did in order to fix the issue.


    sudo rm -rf /etc/apt/trusted.gpg.d/microsoft.gpg 
    sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys EB3E94ADBE1229CF
    sudo apt-get update
    curl -sL https://aka.ms/InstallAzureCLIDeb | sudo bash
    

    Now you will be able to update the instance


    Resources: [1] http://forums.debian.net/viewtopic.php?t=130558



  2. For the error message, you could add missing keys by executing the following command for each key from the log file:

    sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys EB3E94ADBE1229CF
    

    Note: the actual key server name and the key mentioned in the error message should be used in the command above.

    After adding the missing keys, you could try to install the azure-cli again.

    For more information, you could refer to this.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search