Take the 2-minute tour ×
Tor Stack Exchange is a question and answer site for researchers, developers, and users of Tor. It's 100% free, no registration required.

The Debian/Ubuntu packages from deb.torproject.org[docs] do not work on the Raspberry Pi when running Raspbian:

    $ tor --version
    Illegal instruction

Why, and how can I still run Tor versions newer than what ships with Raspbian?

share|improve this question
add comment

4 Answers 4

up vote 12 down vote accepted

The issue

The packages we build for deb.tpo are compiled for various Debian and Ubuntu architectures. These currently are amd64, i386 (x86-64 and x86), and two arm ports: armel and armhf.

Arm CPUs come in different versions, and newer versions generally have more features. The arm ports of Debian differ in what kind of CPU they need as a minimum. In particular, the armhf port needs at least ARMv7.

The arm CPU shipped in the Raspberry Pi is an ARMv6 CPU. As such, packages built for Debian's armhf port do not, in general, work on Raspberry Pi systems. Packages compiled for Debian's older arm port, armel, would work on the Raspberry Pi.

Unfortunately however, Raspbian, a system based on Debian but built for the Raspberry Pi, still decided to call their architecture armhf, even if they can't run Debian armhf binaries. This means two things if you run Raspbian:

  • You can't install the packages we built for armel and that would work on your hardware, at least not easily[1].
  • The packages we built for Debian's armhf will install cleanly -- after all, they say they are for the same architecture as the host -- but then they will not work.

Solution

If you want to run newer Tor versions than are available from the Raspbian folks, you will have to build them yourself.

You can either build it from the source tarball like a lot of other Unix/Linux software and install it locally.

The better option might be to build your own binary Debian packages using the source packages that we put up on deb.tpo. This means you will end up with nice Debian packages that you can install using dpkg and that integrate well in your current system.

To build such packages, follow the documentation on Tor's page about Debian packages. It's a few easy steps, good luck!


[1]: While the binaries built for armel would work on your hardware, they would need all the libraries they depend on built for armel as well. That is, you probably would need an all-armel system or a chroot. Hence "not easily".

share|improve this answer
add comment

This info seems obsolete. On the 'Pi:

sudo apt-get install tor

...now results in a working install. (Of course, you must appropriately edit torrc and then restart the service.)

share|improve this answer
    
OP is trying to run a more recent version than in the repos. –  Cammy_the_block Jun 10 at 23:43
add comment

For those looking for binary downloads, see https://github.com/gordon-morehouse/cipollini/tree/master/raspbian_packages with the appropriate caveat emptor about installing binary software from a dude you don't know (me) on the Internet.

I don't have deterministic builds going for Raspbian packages yet, so these are hand-built straight from the source packages using the method described on the Tor Project web site, then I sign them with my GPG key. I'm fairly active on the mailing lists, so, that's what you have to work on for trust. :)

Otherwise, yep, you're gonna be compiling 'em yourself - takes about 40 min on my 900MHz Pis.

share|improve this answer
add comment

I found a complete tutorial for Raspbian with prebuilt binaries for the latest version. Also, full instructions for building from source are provided. You can catch them here: http://unsuspectingbit.com/tutorial-private-anonymizing-proxy-raspberry-pi-tor-based/

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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