[HOW-TO] Install in BerryBoot
reeeky2001 Offline
Reputation: 1
Reply
Intro: I wanted to use Xbian in BerryBoot on the RPi, b/c I'm new to the Pi and wanted to find out what distro I wanted to use, w/o having to constantly backup and wipe my SD card. So BerryBoot it was.

Prerequisites:
PC w/ Linux (I used ubunutu from a DVD)
Raspberry Pi w/ keyboard and mouse
Xbian img file
SD card
USB stick at least as big as your SD card

How to:
  1. Install Xbian img on SD card
  2. Put SD Card in RPi and let it resize and start up fully.
  3. Shutdown RPi, unplug mouse and use keyboard. Start the RPi again.
  4. While Xbian is starting, but before the GUI is started (b/c I can't figure out how to start a terminal instance in XBMC), press Control-C then use the command "dd bs=1M if=/dev/mmcblk0 of=/media/sda1/backup.img", sda1 being my USB stick.
  5. Wait until its done. This could take a while depending on the size of your SD card, mine was 4GB and took about 15 mins.
  6. Once its finished you'll be able to start programs/commands again. Turn off RPi and unplug USB stick.
  7. Mount USB in Linux on PC. I used Ubunutu 12.10 LiveCD, as its not my primary OS.
  8. Use the following code, obviously if loop2p2 is something else, use that.
    Code:
    $ sudo kpartx -av backup.img 
    add map loop2p1 (252:5): 0 117187 linear /dev/loop0 1
    add map loop2p2 (252:6): 0 3493888 linear /dev/loop0 118784
    $ sudo mount /dev/mapper/loop2p2 /mnt
  9. Goto /mnt/etc/ and commented out all the entries in fstab
    Code:
    $ sudo sed -i 's/^\/dev\/mmcblk/#\0/g' /mnt/etc/fstab
    This code may do that, but I did it manually. I do get a warning when starting Xbian via BerryBoot that may be the result of me not using this code, but idk.
  10. Use mksquash on the img that we mounted, make sure squashfs-tools is installed, "sudo apt-get install squashfs-tools" if its not installed.
    Code:
    $ sudo mksquashfs /mnt /media/sda1/xbian-bb.img -comp lzo -e lib/modules
    $ sudo umount /mnt
    $ sudo kpartx -d image_you_want_to_convert.img
  11. Put this img file on your USB drive, boot the BerryBoot SD card on your RPi, click edit menu, click and hold on Add OS until you get a sub-menu for adding IMG from USB.
  12. Add the XBian img and go from there. You should know what to do now


Also, you could ignore the above and install the img here http://www.mediafire.com/download.php?by1007dtub0wro4
javcarbe Offline
Reputation: 0
Reply
I restore the img in the sdcard didnt boot, i did something wrong


(20th Feb, 2013 05:56 AM)reeeky2001 Wrote:  Intro: I wanted to use Xbian in BerryBoot on the RPi, b/c I'm new to the Pi and wanted to find out what distro I wanted to use, w/o having to constantly backup and wipe my SD card. So BerryBoot it was.

Prerequisites:
PC w/ Linux (I used ubunutu from a DVD)
Raspberry Pi w/ keyboard and mouse
Xbian img file
SD card
USB stick at least as big as your SD card

How to:
  1. Install Xbian img on SD card
  2. Put SD Card in RPi and let it resize and start up fully.
  3. Shutdown RPi, unplug mouse and use keyboard. Start the RPi again.
  4. While Xbian is starting, but before the GUI is started (b/c I can't figure out how to start a terminal instance in XBMC), press Control-C then use the command "dd bs=1M if=/dev/mmcblk0 of=/media/sda1/backup.img", sda1 being my USB stick.
  5. Wait until its done. This could take a while depending on the size of your SD card, mine was 4GB and took about 15 mins.
  6. Once its finished you'll be able to start programs/commands again. Turn off RPi and unplug USB stick.
  7. Mount USB in Linux on PC. I used Ubunutu 12.10 LiveCD, as its not my primary OS.
  8. Use the following code, obviously if loop2p2 is something else, use that.
    Code:
    $ sudo kpartx -av backup.img 
    add map loop2p1 (252:5): 0 117187 linear /dev/loop0 1
    add map loop2p2 (252:6): 0 3493888 linear /dev/loop0 118784
    $ sudo mount /dev/mapper/loop2p2 /mnt
  9. Goto /mnt/etc/ and commented out all the entries in fstab
    Code:
    $ sudo sed -i 's/^\/dev\/mmcblk/#\0/g' /mnt/etc/fstab
    This code may do that, but I did it manually. I do get a warning when starting Xbian via BerryBoot that may be the result of me not using this code, but idk.
  10. Use mksquash on the img that we mounted, make sure squashfs-tools is installed, "sudo apt-get install squashfs-tools" if its not installed.
    Code:
    $ sudo mksquashfs /mnt /media/sda1/xbian-bb.img -comp lzo -e lib/modules
    $ sudo umount /mnt
    $ sudo kpartx -d image_you_want_to_convert.img
  11. Put this img file on your USB drive, boot the BerryBoot SD card on your RPi, click edit menu, click and hold on Add OS until you get a sub-menu for adding IMG from USB.
  12. Add the XBian img and go from there. You should know what to do now


Also, you could ignore the above and install the img here http://www.mediafire.com/download.php?by1007dtub0wro4
brantje Offline
Brantje Networks
Reputation: 9
Reply
What xbian version is the img?
reeeky2001 Offline
Reputation: 1
Reply
(23rd Feb, 2013 07:51 AM)brantje Wrote:  What xbian version is the img?

It WAS the latest at the time, so Alpha 4 I believe.




Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  Install Xbian in berryboot Eloy88 2 31,319 20th Feb, 2013 06:46 AM
Last Post: reeeky2001

Forum Jump: