cannot install anything via apt-get. problem with apt-get update

11,612

The key for signing downloaded packages from the google Linux software repository may need to be re-imported. This can be done with the following line in a terminal

wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add -

Alternatively we can also download and save the key to then import it manually.

Source: Google

Share:
11,612

Related videos on Youtube

Pramod
Author by

Pramod

Updated on September 18, 2022

Comments

  • Pramod
    Pramod almost 2 years

    I am unable to install anything with apt-get. I think this problem is due to gpg error of some kind. I have done almost everything on the net as per my belief. This is what happens when I run apt-get update.

    mody@ubuntu:~$ sudo apt-get update
    Get:1 http:/dl.google.com stable Release.gpg                                  
    Get:2 http:/dl.google.com stable Release                                      
    Ign http:/dl.google.com stable Release                                        
    E: GPG error: http:/dl.google.com stable Release: The following signatures were invalid: NODATA 1 NODATA 2
    mody@ubuntu:~$ 
    

    I tried these

    mody@ubuntu:~$ sudo apt-get clean
    mody@ubuntu:~$ sudo apt-get update && sudo apt-get upgrade
    Get:1 http:/dl.google.com stable Release.gpg
    Get:2 http:/dl.google.com stable Release                                      
    Ign http:/dl.google.com stable Release                                        
    E: GPG error: http:/dl.google.com stable Release: The following signatures were invalid: NODATA 1 NODATA 2
    

    Didn't work

    mody@ubuntu:~$ sudo apt-get update -o Acquire::http::No-Cache=True
    Get:1 http:/dl.google.com stable Release.gpg
    Get:2 http:/dl.google.com stable Release                                      
    Ign http:/dl.google.com stable Release                                        
    E: GPG error: http:/dl.google.com stable Release: The following signatures were invalid: NODATA 1 NODATA 2
    

    Didn't work

    mody@ubuntu:~$ sudo apt-get update -o Acquire::BrokenProxy=true 
    Get:1 http:/dl.google.com stable Release.gpg
    Get:2 http:/dl.google.com stable Release                                      
    Ign http:/dl.google.com stable Release                                        
    E: GPG error: http:/dl.google.com stable Release: The following signatures were invalid: NODATA 1 NODATA 2
    mody@ubuntu:~$ 
    

    Even this

    Click System>>Administration>>Software Sources Click the Download From menu and choose Main Server Type the following in terminal.

    sudo apt-get update
    

    Run the update manager again.

    But did not work

    I also changed the sources with one available on ubuntu site. i dont know why i did that but that didn't help

    Did a force update. problem persists.

    mody@ubuntu:~$ sudo apt-get update -f
    
    [sudo] password for mody: 
    Get:1 http:/dl.google.com stable Release.gpg
    Get:2 http:/dl.google.com stable Release                                      
    Ign http:/dl.google.com stable Release                                        
    E: GPG error: http:/dl.google.com stable Release: The following signatures were invalid: NODATA 1 NODATA 2
    

    Frustrated.

    Synaptic is not installed as well as aptitude. changing download server to everything possible from anything did not help either.

    PS: link were giving me problem with posting so I delete / where // were present

    • Avinash Raj
      Avinash Raj over 10 years
      @Azker as this sudo apt-get install -f command do a force update?
    • Viktor K
      Viktor K over 10 years
      edit your question and post the output of 'cat /etc/apt/sources.list' and 'ls /etc/apt/sources.list.d/'. I'm sure there are some left entries in those directories. You can also go to System>>Administration>>Software Sources and on tab Other Software uncheck all with dl.google.com
    • AzkerM
      AzkerM over 10 years
      EDIT: Try a force update > sudo apt-get update -f .. @AvinashRaj - thank you for pointing out.
    • Avinash Raj
      Avinash Raj over 10 years
      -f, --fix-broken Fix; attempt to correct a system with broken dependencies in place.@Azker -f doesn't means for force.
    • Pramod
      Pramod over 10 years
      @arhimed that did it. thanks a ton!! System>>Administration>>Software Sources and on tab Other Software uncheck all with dl.google.com