• Home
  • Help
  • Search
  • Login
  • Register
Pages: [1]
Author Topic: different distros and falling back  (Read 2330 times)
digininja
Newbie
*

Karma: 0
Posts: 13



View Profile WWW
« on: November 01, 2009, 11:29:44 AM »

I've been looking at the howtos on installing different distros on the Sheeva, especially this one http://www.cyrius.com/debian/kirkwood/sheevaplug/install.htm and they all talk about modifying the boot parameters so the device boots from either USB or SD card by default. But I was wondering, is it possible though to set it up so that when I have the SD card plugged in then it will boot the distro on there but if I remove it it will fall back to booting the distro on the flash?

If not then the flash becomes a bit redundant if you have a large SD card as there isn't much point storing things on the flash when they can be stored on a removable device which can easily be removed to be backed up and updated remotely. What are people using the flash for after installing other distros?
Logged

tbm
Full Member
***

Karma: 7
Posts: 121



View Profile WWW
« Reply #1 on: November 02, 2009, 11:05:51 AM »

I've been looking at the howtos on installing different distros on the Sheeva, especially this one http://www.cyrius.com/debian/kirkwood/sheevaplug/install.htm and they all talk about modifying the boot parameters so the device boots from either USB or SD card by default. But I was wondering, is it possible though to set it up so that when I have the SD card plugged in then it will boot the distro on there but if I remove it it will fall back to booting the distro on the flash?n

Yes, that's possible.  I don't know what the command is to booth from flash, but you could add bootcmd_flash and then set something like this:

Code:
setenv bootcmd 'setenv bootargs $(bootargs_console); run bootcmd_mmc; bootm 0x400000 0x0800000; run bootcmd_flash'

This would try to load the image from SD card and boot it; but if it fails to boot the image (e.g. because your SD card is not in the plug) it will boot from flash.


Logged

digininja
Newbie
*

Karma: 0
Posts: 13



View Profile WWW
« Reply #2 on: November 02, 2009, 11:51:49 AM »

Thanks, I'm not in a position to try it yet but I'll give it a go when I get round to dual booting and see what happens.
Logged

birdman
Sr. Member
****

Karma: 4
Posts: 443


View Profile WWW
« Reply #3 on: November 02, 2009, 02:45:34 PM »

Somewhere in this forum someone posted boot commands to try various methods (SD, USB) with NAND boot last, as that is expected to be there....
Logged

restamp
Global Moderator
Sr. Member
*****

Karma: 4
Posts: 273


View Profile
« Reply #4 on: November 02, 2009, 04:09:07 PM »

What are people using the flash for after installing other distros?

Personally, I'm using it as a backup boot device that I can use in a pinch to remedy a problem in the event that something happens to make the SDcard unbootable.  Of course, the Uboot and the Uboot environment are also stored on the flash..
Logged

knireis
Jr. Member
**

Karma: 2
Posts: 88


View Profile
« Reply #5 on: November 06, 2009, 01:32:01 AM »

[
Yes, that's possible.  I don't know what the command is to booth from flash, but you could add bootcmd_flash and then set something like this:

Code:
setenv bootcmd 'setenv bootargs $(bootargs_console); run bootcmd_mmc; bootm 0x400000 0x0800000; run bootcmd_flash'

This would try to load the image from SD card and boot it; but if it fails to boot the image (e.g. because your SD card is not in the plug) it will boot from flash.


How would the bootcmd_flash look like when you used the sheevapluginstaller 1.0 to install to nand?
Logged

tbm
Full Member
***

Karma: 7
Posts: 121



View Profile WWW
« Reply #6 on: November 19, 2009, 02:33:30 AM »

I just found the following page which might help: http://www.openplug.org/plugwiki/index.php/Multi-Boot
Logged

sanjayayogi
Newbie
*

Karma: 0
Posts: 6



View Profile WWW
« Reply #7 on: November 19, 2009, 09:45:14 AM »

I installed Debian Squeeze according to Martin Michlmayr´s  instructions to a Kingston 8 gb SD. Uneventful, booted ok, according to instructions:
http://www.cyrius.com/debian/kirkwood/sheevaplug/install.html

Used:
setenv mainlineLinux yes
setenv arcNumber 2097
saveenv
reset

then:
setenv bootargs_console console=ttyS0,115200
setenv bootcmd_mmc 'mmcinit; ext2load mmc 0 0x0800000 /uInitrd; ext2load mmc 0 0x400000 /uImage'
setenv bootcmd 'setenv bootargs $(bootargs_console); run bootcmd_mmc; bootm 0x400000 0x0800000'
saveenv

I had previously installed Ubuntu 9.04 to the NAND with the 1.0 installer. uboot v19 not 24. Left the uboot alone, did not update. It booted fine. Instructions:
http://www.openplug.org/plugwiki/index.php/SheevaPlug_Installer

I booted into the Debian Squeeze on the SD card with the mini-usb in the SheevaPlug and connected ok, then rebooted the plug, interrupted the reboot and at the Marvell prompt on the SheevaPlug entered the following with the SD card in the SheevaPlug:

setenv bootargs_nand 'console=ttyS0,115200 ubi.mtd=1 root=ubi0:rootfs rootfstype=ubifs'
setenv bootcmd_nand 'setenv bootargs $(bootargs_nand) $(mtdpartitions); nand read.e 0x00800000 0x00100000 0x00400000; bootm 0x00800000'
setenv bootargs_mmc console=ttyS0,115200
setenv bootcmd_mmc 'mmcinit; ext2load mmc 0 0x0800000 /uInitrd; ext2load mmc 0 0x400000 /uImage'
setenv bootcmd 'setenv bootargs $(bootargs_mmc); run bootcmd_mmc; bootm 0x400000 0x0800000; run bootcmd_nand'
saveenv

then booted the SheevaPlug with the SD card  Debian Squeeze. Booted fine. Rebooted, interrupted the reboot, removed the SD card, then booted and the NAND booted the Ubuntu 9.04 no problem. Rebooted reinstalled the SD card, rebooted and up came Debian Squeeze.

So at least for the  Ubuntu 9.04 on the NAND and Debian Squeeze on the SD card these environment variables seem to work for dual booting the SheevaPlug.

Comments anyone?
Logged

Pages: [1]
Print
Jump to: