✏ Installing Ubuntu Touch on the Fairphone 2

General

At the time of writing, installing Ubuntu Touch on the FP2 is somewhat tricky (as for all other phone models…). The official way to get Ubuntu Touch on the FP2 is a graphical installer available for Linux, Windows and Mac OS X.

Using the Installer

Download the installer at https://github.com/ubports/ubports-installer (older versions can be found on the releases page) and follow the instructions for your system. With luck, you’ll be fine.

Prerequisites

On the phone you have to enable USB Debugging in the developer options (those need to be unlocked once, see Dictionary Entry: Developer Options). Connect your phone with USB Debugging enabled to your PC/Mac and it should show a dialog asking for permission. Confirm that with OK and check the “Always allow from this computer” checkbox.

Linux

  • different formats of the installer exist: deb, snap and AppImage (I prefer to use the latter)
    • when using snap, run sudo snap connect ubports-installer:raw-usb before starting the installer
  • the log of the installer can be found at ~/.cache/ubports/ubports-installer.log
  • opensuse
    • it is necessary to have adb and fastboot in /usr/bin
  • ubuntu
    • the recommended way to install adb and fastboot is using the package management system: sudo apt install android-tools-adb android-tools-fastboot

Windows

  • the recommended way to install adb and fastboot is the 15 seconds ADB Installer
  • the log of the installer can be found at %APPDATA%\.cache\ubports\ubports-installer.log
  • the versions between 0.1.9 and 0.1.17 have issues on window, i.e. if you get affected by the “bootimage: incomplete or not signed” error, there is no use trying 0.1.12 on windows (try 0.1.9 on win or 0.1.12 on a linux live usb stick)

Mac OS X

  • the log of the installer can be found at ~/Library/Caches/ubports/ubports-installer.log

General hints

  • make sure adb and fastboot are in $PATH
  • make sure you have a data cable (not just one for charging)
  • try different USB cables/ports on your computer if it doesn’t work
  • it may help to just start again if you run into problems
  • if the latest version of the installer doesn’t work, versions 0.1.12 and 0.1.9 are often reported to have been successful
  • the installer uses a non-standard port 5038 for adb, so if you want to use adb commands parallel to the running installer, use adb -P 5038 ... (kill any non 5038 port adb process while the installer is running)
  • sometimes the installer claims you’re not using the latest version; just ignore this message

Troubleshooting

There are several known problems, sometimes without real solution/workaround. The following are just hints, don’t expect a single workaround to grant success.

  • phone is not detected in recovery mode
    • ensure adb is in $PATH (even /usr/bin for opensuse)
    • ensure no second adb server with a port other than 5038 is running
    • try to disconnect the phone from USB, shut it down completely, boot it again to recovery mode, connect via USB; all while the installer is still running
    • on linux
  • phone is not detected in bootloader (fastboot) mode
    • ensure fastboot is in $PATH (even /usr/bin for opensuse)
    • try to disconnect the phone from USB, shut it down completely, boot it again to bootloader (fastboot) mode, connect via USB; all while the installer is still running
    • on linux
  • the phone model is supposed to be detected automatically but sometimes that doesn’t work
    • just select the Fairphone 2 manually
    • this sometimes leads to the list of available channels to contain duplicates; that is not a problem, just select one of the entries for your desired channel
  • error message FAILED (remote: bootimage: incomplete or not signed)
    • supposedly an issue with running commands asychronously, i.e. reboot is initiated before file transfer has finished
    • no real solution at the moment (mayby trying the older installers or the manual method below)
  • error message FAILED (data transfer failure (Protocol error))
    • on the first occurrence use the “Try again” button and start over the installation procedure
    • if it happens multiple times, try some of the other hints
  • In case you encounter problems and the current OS on your FP2 is encrypted, try a factory reset first to remove encryption

In case you’re willing to help debugging problems, there is a pre-release version available that contains more logging for Linux and Windows.

And when you need direct help, please contact the Ubports WelcomePlus group on Telegram.

Manual method

This is not officially supported!

Files and a script (for linux) can be found at State of the UBports installer, or command line which imitate what the installer does internally (if it works).
If you want to use this method from windows, follow these hints what to change wrt. the linux script.

10 Likes