I run Ubuntu 16.04LTS and I'm trying to reinstall TOR because it stopped working...

Right now I'm trying to verify TOR package I downloaded and I'm having problems with the verification. When I enter this command

gpg --keyserver pool.sks-keyservers.net --recv-keys 0x4E2C6E8793298290

I get this response

gpg: requesting key 0x4E2C6E8793298290 from hkp server pool.sks-keyservers.net
?: invalid HTTP proxy (socks5-hostname:// unsupported URI
gpgkeys: HTTP fetch error 7: couldn't connect: Success
gpg: no valid OpenPGP data found.
gpg: Total number processed: 0
gpg: keyserver communications error: keyserver unreachable
gpg: keyserver communications error: public key not found
gpg: keyserver receive failed: public key not found

What to do?

  • Looks like you've misconfigured GnuPG, trying to give it a SOCKS proxy when it expects an HTTP proxy. – cacahuatl Feb 2 '18 at 19:39
  • That's helpful, thanks, but I'm a newbie at Linux and is there a way to fix it? – Jerry777 Feb 3 '18 at 2:58
  • Given that that configuration isn't default on ubuntu I can only assume it's a configuration change you've made yourself. – cacahuatl Feb 3 '18 at 3:01
  • I didn't consciously do that. The only thing I often do is update my Tor & system software via Software Updater. So since I'm not even sure I know what an http proxy is, I can only guess that this might work (from my reading): gpg --keyserver pool.sks-keyservers.net --keyserver-options http-proxy=socks5-hostname:// --recv-keys 0x4E2C6E8793298290 – Jerry777 Feb 3 '18 at 3:15
  • I tried the command gpg --keyserver-options http-proxy=socks5-hostname://,debug,verbose --keyserver pool.sks-keyservers.net --recv-keys 0x4E2C6E8793298290 – Jerry777 Feb 3 '18 at 3:32

Install Tor Browser in Ubuntu 16.04 and later

Tor Browser (torbrowser-launcher) is available in the default Ubuntu repositories in Ubuntu 16.04 and later. torbrowser-launcher handles downloading the most recent version of Tor Browser Bundle for you, in your language and for your architecture. After installing Tor Browser, it can be launched by searching for tor in the Dash and clicking the Tor Browser icon. The Tor Browser Launcher Settings app is also installed along with Tor Browser.


  1. Update the gpg key:

    gpg --homedir "$HOME/.local/share/torbrowser/gnupg_homedir/" --refresh-keys --keyserver pgp.mit.edu  
  2. Tor Browser still may not launch after updating the gpg key due to being unable to update the Tor Browser version in:


    Replace your-username with your username and replace en-US with your language in the following commands and run these commands:

    mkdir sources  
    cd sources     
    touch versions    
    gedit /home/your-username/.local/share/torbrowser/tbb/x86_64/tor-browser_en-US/Browser/TorBrowser/Docs/sources/versions
  3. A Gedit window will open up. Copy the string TORBROWSER_VERSION=7.5 into the Gedit window and save the file.

  4. Launch Tor Browser for the first time.


Now Tor Browser will launch normally by clicking its icon. If an update to Tor Browser is available, the update will be installed as usual.

enter image description here

  • Thanks for your reply. I did what you said but though I tried it a few ways, gedit opened nothing. Fortunately TOR version 7.5 doesn't need to be installed so I can run it directly. – Jerry777 Feb 3 '18 at 16:59
  • Thanks for your help but I'm OK now. Tor Browser version 7.5 runs easily on my system without installation just by unpacking it and running the launching file. In contrast Tor re-installation through Ubuntu Software I couldn't get to work no matter how I uninstalled/reinstalled or what special commands I used. I don't mind running it directly. In fact that might be better, because I verified the signature of the Tor download I unzipped, but I never verified the Ubuntu Software one. – Jerry777 Feb 3 '18 at 23:07
  • I fully understand that because in the beginning I downloaded Tor Browser from the official Tor website and ran it directly too, but that lasted only about 24 hours because I don't give up easy. I searched the internet and found nothing, so I had to figure it out for myself, because I reasoned that it must be a bug and I wanted to put the bug fix online to share it with everyone who is affected by the same bug. If you look at my profile you will see that I registered for Tor Q&A only 9 days ago, and the reason why I registered here was to share this solution. – karel Feb 3 '18 at 23:14
  • Dear karel: I appreciate your help but I hope you are not implying that I "give up" more "easily" than you. Our purposes are different. To run it directly actually serves my purposes better than installation (I realize now, for a couple of reasons I don't need to get into). And BTW it still works fine thank God. – Jerry777 Feb 4 '18 at 15:01
  • I think the way you're doing it also automatically updates itself like mine. I don't know because I haven't checked yet, but I have both Tor Browsers installed, so I'll find out soon enough. If so the advantages of using the Ubuntu repo package are that it launches the usual way from the Dash (see the screenshot in my answer) and it survives a distribution upgrade the same way. – karel Feb 4 '18 at 15:13

Maybe this isn't a proper answer, but realizing I had another laptop with Ubuntu 16.04LTS, and realizing from cacauati that by main laptop's configuration was abnormal, and not knowing how to make it normal, instead I was able to complete the TOR package verification easily by copying the files to the other laptop and running the standard TOR-website commands there.


For the benefit of other newbie users here, and as a more proper answer, I found that all I needed to do to restore keyserver download function (the step before verifing the TOR package) was to open /home/.gnupg/gpg.conf with a text editor, find the line

keyserver-options http-proxy=socks5-hostname://

and put a # in front of it to de-activate it.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.