*Raspberry Pi. OpenELEC on USB Setup Guide (6 easy steps).

Soldato
Joined
27 Sep 2005
Posts
5,903
Location
Burbage, Hinckley
I thought I would write some clear and easy to follow instructions for how to easily get openELEC running stable and fast on a Raspberry Pi. This will be done by getting the Pi to boot the OS from the SD card but use the USB drive for all your library information. The Pi is, unfortunately, renowned for corrupting SD cards when they are read from or wrote to too often. This makes it so that it only reads from the SD card and any writing back to it is minimal.

Most of the instructions I have found online assume you know how to SSH into your Pi or just generally over complicate things. Hopefully this short guide will help anyone who wants it broken down into basic steps.


Things you will need:-


HARDWARE

Raspberry Pi (Obviously!)
SD Card or Micro SD for Model B+ or Rpi2.
USB 3 pen drive
Note: you can use USB 2, but they vary in data transfer rates so by using even a cheap USB 3 you are maxing out the USB data transfer speed.


SOFTWARE

Latest build of OpenELEC for your model of Pi (DiskImage).
SDFormatter
MiniTool Partition Wizard
Win32 Disk Imager



INSTRUCTIONS

1). Use 'SDFormatter' to format the SD card. Make sure you are pointing to the correct drive and change the 'Format Size Adjustment' to ON - this ensures that any hidden partitions are removed from the drive.

2). Use winrar or similar software to extract your OpenELEC version so that you can see the actual Disk Image file.

3). Open 'Win32 Disk Imager' and select the OpenELEC image file, select the SD card from under Device and then Write the image to the SD card.

This will create a 256MB FAT32 partition on the SD card with the OpenELEC OS files on. It will also create an Ext4 partition for storing your library information, like fanart and settings etc. we will swap this though so your Pi stores this info on the USB stick.

4). Open 'MiniTool Partition Wizard' and ensure that both your SD card and your USB stick are visible. Then right click on the ext4 partition of the SD card and delete it. Next Right click on the FAT32 partition of the SD card and click Move/Resize. You may as well use the whole SD card as I can't see any point in leaving partitions in place! Name the FAT32 partition to "SYSTEM", make sure it's set to primary and active and hit the Apply button.

5). 'Still in MiniTool Partition Wizard' select the USB drive, format it to Ext4, set as primary and active and label as "STORAGE". Apply these actions.

6). Using windows explorer open the SD card to see the OS files. Use notepad to open the text file called cmdline.txt and replace any text with the follwoing:-


boot=/dev/mmcblk0p1 disk=LABEL=STORAGE quiet



Save the cmdline.txt file.


That's it - pop the SD card and the USB stick into the Pi and boot it up.

Now if your SD card does become corrupted or you download a newer version of OpenELEC you only have to follow the instructions above for the SD card and all of your library info and settings will still be intact on the USB stick.

You should see a noticeable performance boost while browsing through your movies etc. too.
 
Last edited:
Soldato
Joined
8 Oct 2005
Posts
2,840
Location
Herefordshire (U.K.)
Just a quick post for anyone who doesn't know already but an updated version of OpenELEC (5.0.2) which includes a few bug fixes was released yesterday.

There is a separate version for the new Raspberry Pi 2 also, so make sure you pick the right one! ;)
 
Soldato
OP
Joined
27 Sep 2005
Posts
5,903
Location
Burbage, Hinckley
Just a quick post for anyone who doesn't know already but an updated version of OpenELEC (5.0.2) which includes a few bug fixes was released yesterday.

There is a separate version for the new Raspberry Pi 2 also, so make sure you pick the right one! ;)

Excellent, thanks. My R.Pi2 should be with me in a few days so I might just wait and install on that. I'm going to see if I can just transfer my USB stick, with my library info etc., over to the Pi2 and use the method above to map to it.

I will post results back here when done.
 
Associate
Joined
25 Jan 2012
Posts
295
Thanks, set it up tonight, just to note in your instructions you said "boot=/dev/mmcblk0p1 disk=LABEL=Storage quiet" It didn't work until I changed Storage to STORAGE

I also used caps for SYSTEM

All working great now thou :D Thankyou :)
 
Soldato
OP
Joined
27 Sep 2005
Posts
5,903
Location
Burbage, Hinckley
Thanks, set it up tonight, just to note in your instructions you said "boot=/dev/mmcblk0p1 disk=LABEL=Storage quiet" It didn't work until I changed Storage to STORAGE

I also used caps for SYSTEM

All working great now thou :D Thankyou :)

Ah yes, thanks for pointing that out. I notice in my original instructions I tell you to label the USB as STORAGE but then refer to it as Storage in the config file!!!

I will amend original text now.
 
Soldato
OP
Joined
27 Sep 2005
Posts
5,903
Location
Burbage, Hinckley
*UPDATE* Transferring the USB "STORAGE" stick across to Pi2 and then installing the Quad core version of Openelec worked, but was a bit glitchy.

I did a the process from fresh for the Pi2 and it now works smoooooth.
 
Soldato
Joined
12 Feb 2009
Posts
4,359
Location
London
Bout to do this tonight on my pi2 but have a question regarding updating as I updated my pi b+ which is set up with a USB stick the same way.

I dropped the update file into the update folder to update from gotham to helix. Would this of kept the USB configuration intact or is there another. Step I had to take?
 
Associate
Joined
16 Mar 2020
Posts
2
This is really useful. I have used it to alter STORAGE after set-up. And, so far, it has cured my problem. For some like me, with limited knowledge and FUD, this is SO helpful. Many thanks.
 
Back
Top Bottom