Debian Jessie on Raspberry Pi 2

Last modified on 2015-07-22

With the move to ARMv7 I am now capable of running the official ARM port of Debian (with Pi-friendly kernel+firmware) on my Raspberry Pi 2!

Let’s go!

Debian developer Sjoerd Simons has created a Jessie minimal image with an updated 3.18 Linux kernel and firmware suitable for Pi 2.

My setup:

0. Download

Download the latest image and GPG signature


Verify the GPG signature.

1. Install to microSD

Unpack the image …

gzip -d jessie-rpi2-20150202.img.gz

In lieu of the usual (slower) dd I use bmap-tools and jessie-rpi2-*.img.bmap to write the image to microSD …

sudo apt-get install bmap-tools                                                    
sudo bmaptool copy --bmap jessie-rpi2-20150705.img.bmap jessie-rpi2-20150705.img /dev/sdX

2. Boot and resize

Login as root with password debian.

Filesystem layout 1 on the microSD card …

Filesystem      Size  Used Avail Use% Mounted on
/dev/root       2.8G  555M  2.1G  21% /
devtmpfs        459M     0  459M   0% /dev
tmpfs           463M     0  463M   0% /dev/shm
tmpfs           463M  312K  463M   1% /run
tmpfs           5.0M     0  5.0M   0% /run/lock
tmpfs           463M     0  463M   0% /sys/fs/cgroup
/dev/mmcblk0p1  121M  9.7M  112M   9% /boot/firmware 

Install image inflates into a 2.8GB partition; using only a fraction of available capacity. I use fdisk to repartition the microSD to use all storage and resize2fs to expand rootfs into its new accomodations!

Alternative: Run a Raspberry Pi from USB storage

3. Post-install


4. Package management

Modify /etc/apt/sources.list

deb jessie main contrib non-free
#deb-src jessie main contrib non-free

deb jessie/updates main contrib non-free
#deb-src jessie/updates main contrib non-free

deb jessie-updates main contrib non-free
#deb-src jessie-updates main contrib non-free

deb [trusted=yes] jessie rpi2

Install image provides a flash-kernel package customized for the Pi. Use apt-pinning to continue using this custom package vs updates from official Debian repositories. Create /etc/apt/preferences.d/flash-kernel with …

Package: flash-kernel
Pin: origin
Pin-Priority: 900

Confirm flash-kernel is pinned …

sudo apt-cache policy flash-kernel
      Installed: 3.35.co1+b1
      Candidate: 3.35.co1+b1
      Package pin: 3.35.co1+b1
      Version table:
     *** 3.35.co1+b1 900
            500 jessie/rpi2 armhf Packages
            100 /var/lib/dpkg/status
         3.35 900
            500 jessie/main armhf Packages

Now is a good time to upgrade …

sudo apt-get update
sudo apt-get dist-upgrade

5. Remote access

Generate new SSH keys on the Pi …

sudo rm /etc/ssh/ssh_host_*key* && sudo pkg-reconfigure openssh-server

Secure remote access by requiring clients to use SSH keys.

Happy hacking!


  1. /boot/config.txt has been moved to /boot/firmware/config.txt.