0

I followed a tutorial and now I have Homebrew tor running in the background at all times for use by an unrelated application.

But now I can't use Tor Browser.

tor connection fails

I typed tor into Terminal and I get this Is Tor already running? message. So I'm guessing only one instance of tor can run at a time.

$ tor
Mar 29 02:32:13.361 [notice] Tor 0.3.2.10 (git-31cc63deb69db819) running on Darwin with Libevent 2.1.8-stable, OpenSSL 1.0.2n, Zlib 1.2.5, Liblzma N/A, and Libzstd N/A.
Mar 29 02:32:13.362 [notice] Tor can't help you if you use it wrong! Learn how to be safe at https://www.torproject.org/download/download#warning
Mar 29 02:32:13.363 [notice] Read configuration file "/usr/local/etc/tor/torrc".
Mar 29 02:32:13.367 [notice] Scheduler type KISTLite has been enabled.
Mar 29 02:32:13.367 [notice] Opening Socks listener on 127.0.0.1:9050
Mar 29 02:32:13.367 [warn] Could not bind to 127.0.0.1:9050: Address already in use. Is Tor already running?
Mar 29 02:32:13.367 [notice] Opening Control listener on 127.0.0.1:9051
Mar 29 02:32:13.367 [warn] Could not bind to 127.0.0.1:9051: Address already in use. Is Tor already running?
Mar 29 02:32:13.367 [warn] Failed to parse/validate config: Failed to bind one of the listener ports.
Mar 29 02:32:13.367 [err] Reading config failed--see warnings above.

I want to use Tor Browser without having to disable my background service. How can I have my cake and eat it too?

1

From the provided bash output, it looks like your background tor is configured to use ports 9050 and 9051.

You were on the right track with multiple instances of tor not being able to run. But Tor Browser comes with its own tor daemon. It doesn't use the same tor as your background service.

Tor Browser's default ports are 9150 and 9151. They used to be 9050 and 9051, so if you've run Tor Browser in the past then it is probably trying to open 9050 and 9051. Those ports are in use. So Tor Browser fails to start.

To allow both tor services to run you'll have to change the port configurations (torrc) of either the Homebrew tor or the Tor Browser tor. In particular, you'll want to change the line

ControlPort 9051

to use some other port number so that the two don't conflict. (May I suggest 9151?)

For Mac,

  • the Homebrew torrc should be located at /usr/local/etc/tor/torrc, and
  • the Tor Browser torrc should be at ~/Library/Application Support/TorBrowser-Data/Tor/torrc.

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.