How to Install Fedora on a SheevaPlug and Boot Off a SD Card.




Introduction: How to Install Fedora on a SheevaPlug and Boot Off a SD Card.

About: I like to tinker with just about anything, sometimes it works out in the end. Have fun looking at the projects, try tearing something open and let me know how it goes. cheers, -Joe

I saw a post on the SheevaPlug at Slashdot and then in Popular Mechanics. It seemed like an interesting device  it runs @ 2.5w, no fans, solid state and no need for a monitor.

For years I have carried around an old CRT monitor just in case my linux box crashed, no need as this has a real serial console built in.

This instructable will detail how to build a SheevaPlug with Fedora (v12), to both run and boot off of a SD card.

I got a lot of good info from the PlugComputer Forum and a FedoraProject Wiki

Step 1: Supplies

You will need:
SheevaPlug Dev Kit (I bought mine from Global Scale) 
SD Card
SD Card Reader
A linux box to install the OS on the SD card.

Step 2: Prep the SD Card.

Add the SD Card to your linux box you are building this on and run:

dmesg | tail

The output here shows me that it has been mounted as /dev/sdc.

Step 3: Partition the SD Card

We will partition the SD card now.

fdisk /dev/sdc

Delete any existing partitions.


Step 4: Partition SD Card (cont)

Create the new partition.
accept defaults

Make it bootable

Verify it

Write the new parition table

Step 5: Create the File System

Create the filesystem.
mkfs.ext2 /dev/sdc1

Step 6: Get the Distro and Kernel

Download the Kernel and Distro

Step 7: Install OS

Create a mount point
mkdir /media/flash

Mount the SD Card
mount /dev/sdc1 /media/flash

Uncompress the filesystem
tar -jxf rootfs-f12.tar.bz2

Copy the filesystem over to the sd card
cp -r rootfs-f12/* /media/flash/

Copy the kernel over to the sd card
cp uImage-2.6.30-sheevaplug /media/flash/boot/

Step 8: Edit the Fstab

The fstab needs to be edited to point to the SD card. The Sheevaplug see's the SD card as /dev/mmcblk0pX
vi /etc/fstab
change /root to
/dev/mmcblk0p1          /                       ext2     relatime        1 0

Step 9: Reset the Root Password

I have no idea what roots password is set to. So we'll remove it.
vi /media/flash/etc/shadow

Change the remove the password:

Step 10: Edit the Network Configuration

Edit the network configuration for your network

vi /media/flash/etc/sysconfig/network


vi /media/flash/etc/sysconfig/network-scripts/ifcfg-eth0

Unmount the sd card
umount /media/flash
Put it in the SheevaPlug

Step 11: Prep Your Linux Box to Update the Kernel

The SheevaPlug ships with a firmware that can boot off of SD cards. So you need to update it over TFTP
Install a tftp server
yum install tftp-server

Get the u-boot image and make it available to the sheevaplug

cd /var/lib/tftpboot/
mv u-boot.bin-3.4.19 uboot.bin
vi /etc/xinetd.d/tftp
change "disable  = yes " to "disable = no "

Add the script to load the ftdi driver when the SheevaPlug is connected:
vi /etc/udev/rules.d/85-sheevaplug.rules

# if no driver has claimed the interface yet, load ftdi_sio
ACTION=="add", SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_interface", \
        ATTRS{idVendor}=="9e88", ATTRS{idProduct}=="9e8f", \
        DRIVER=="", \
        RUN+="/sbin/modprobe -b ftdi_sio"

# add the sheevaplug VID and PID to the list of devices supported by ftdi_sio
ACTION=="add", SUBSYSTEM=="drivers", \
        ENV{DEVPATH}=="/bus/usb-serial/drivers/ftdi_sio", \
        ATTR{new_id}="9e88 9e8f"

# optionally create a convenience symlink for the console device
ACTION=="add", KERNEL=="ttyUSB*", \
        ATTRS{interface}=="SheevaPlug JTAGKey FT2232D B", \
        ATTRS{bInterfaceNumber}=="01", \

***Plug in the serial cable from the Sheevaplug, if a /dev/ttyUSBx is not created, reboot

your linux system

Step 12: Change Boot Parms

Hook up the usb cable to the mini usb connector on the SheevaPlug to a usb port on your linux box.
screen /dev/ttyUSBX 115200

Update the firmware

Marvell>> setenv serverip # IP of your TFTP server
Marvell>> setenv ipaddr #IP of sheevaplug
Marvell>> bubt uboot.bin

If U-Boot Endiannes is going to change (LE->BE or BE->LE),
Then Env parameters should be overridden..
Override Env parameters? (y/n) n

Next you need to configure the bootloader to boot off of the SD card
setenv mainlineLinux yes
setenv arcNumber 2097
setenv bootargs_console console=ttyS0,115200
setenv bootargs_root 'rw root=/dev/mmcblk0p1 rootdelay=10 rootfstype=ext2'
setenv bootcmd_mmc 'mmcinit; ext2load mmc 0 0x800000 /boot/uImage-2.6.30-sheevaplug'
setenv bootcmd 'setenv bootargs $(bootargs_console) $(bootargs_root); run bootcmd_mmc; bootm 0x0800000'

It should boot up now.

Step 13: Post Install Notes

You need to change the  root password.
IP Tables is not loading right on my f12 install. So edit /etc/hosts.allow and hosts.deny until someone can figure it out...

I run Apache/PHP/DNSmasq/samba/etc on it and can't really notice any big performance hit.

Be the First to Share


    • Puzzles Speed Challenge

      Puzzles Speed Challenge
    • "Can't Touch This" Family Contest

      "Can't Touch This" Family Contest
    • CNC Contest 2020

      CNC Contest 2020



    10 years ago on Introduction

     Good Job! I have been keeping an eye on the sheevaplug and/or pogoplug for a few months now. It will be the perfect companion for a lot of complex projects. Plus the low energy consumption makes it really desirable.