Debian images for the Raspberry Pi

There are several different Debian distributions for the Raspberry Pi currently in circulation, and there seems to be quite a bit of confusion about the differences between them.

 

Debian “squeeze”

The distribution currently recommended by the foundation is based on Debian “squeeze”, and can be downloaded from here:

http://www.raspberrypi.org/downloads

“squeeze” is the codename of Debian 6.0 – the current official Debian release. It is a nice basic distribution and is quite stable. A useful feature of this distribution is that after writing the SD Card image on another PC, you can mount it and rename one file on the boot partition in order to make the distribution boot up with an SSH server enabled. Just find the file named “boot_enable_ssh.rc” on the “/boot” partition and rename it to “boot.rc”. That’s it – SSH enabled. This makes it easy to use this distribution even if you don’t have a display or keyboard to hook up to it. You can just connect it to the network, boot it up, and then SSH in to it from another machine.

 

Debian “wheezy” beta release

There is another distribution in widespread use, based on Debian “wheezy”, which can be downloaded from here:

http://www.raspberrypi.org/archives/1435

“wheezy” is the codename of the next release of Debian, currently in testing. As well as having more up-to-date software, it has a number of advantages over the “squeeze” distribution, including a config utility which loads on first boot, which does some set up, including expanding the image to fill your SD card, changing the RAM split, adding some swap, and allowing the toggling of an SSH server. It also comes with a few example python games to help get people started with python programming. It’s not so easy to tweak the image to boot for the first time with SSH enabled, but so long as you have a display and a keyboard to use for the first boot, this is certainly the image I would recommend for most users. It is still a bit buggy however – especially the config utility.

I couldn’t actually get the config utility to turn on an SSH server (perhaps because I didn’t have a network connection when I booted for the first time). If you have the same problem, just Ctrl-C out of the config utility, run:

# update-rc.d ssh enable

 # update-rc.d ssh start

at the root prompt to turn on the server, then

# raspi-config

to re-run the config program and “Finish” when you are done. Once you’ve got the SSH server on and configured to run on startup you can use it headless, just like the “squeeze” distro.

 

Raspbian (wheezy)

The “wheezy” image referred to above is not Raspbian, despite the fact that Raspbian is also based on “wheezy”. Both of the images discussed previously are based on a Debain ARM port for ARM chips without hardware floating point, and so floating point computations have to go through at least some software layer. However, the ARM chip in the Pi does support floating point operations in hardware, which is much faster. The Raspbian project is producing a new Debian port based on “wheezy” which properly supports floating point operations on the chip. This is much faster, and so software generally runs significantly faster on Raspbian than on releases which don’t support “hard float”. There are no official releases of Raspbian yet, but there are some images around which are fine if you are reasonably competent with Debian. I started with this image:

http://www.raspbian.org/HexxehImages

and then added other software I needed. It is very “bare bones”, but it works fine, and has an SSH server enabled, so it can be used headless from first boot. However, if you follow the instructions for installing additional software described on the above page, I noticed that at some point the SSH server gets disabled. Just reinstalling the server with

# apt-get install openssh-server

seems to fix things. If you are running headless this is something to watch out for.

I’ll talk more about speed differences in another post, but note that for a test C program I have for a floating-point intensive scientific computing problem, my code runs almost 10 times faster on Raspbian than I can get it to run on the “wheezy-beta” image discussed previously. So although Raspbian isn’t yet for beginners, I suspect it will rapidly become the favourite distribution as soon as an official release is made. Even before then, if you are interested in floating point intensive applications, it is really the only game in town…

 

 

 

Advertisements

Published by

darrenjw

I am Professor of Stochastic Modelling within the School of Mathematics & Statistics at Newcastle University, UK. I am also a computational systems biologist.

One thought on “Debian images for the Raspberry Pi”

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s