Description

previous OS versions booted fine without any change when same build files were in internal jffs2 or on SD card or on USB stick. With 11.2.0 it look like this no longer works.

When I boot from USB or SD slot the initrd prints many lines of something similar to 'chdir to /lib/modules failed' and finally something like 'Root device not found, sleeping forever'.

When examining initrd files in /boot I found that there are actually two initial ramdisks, one initrd below 2MB size and one actrd having ~5MB. The 5MB one does have /lib/modules inside while the normal initrd does not.

When replacing initrd by actrd the chdir /lib/modules error message is gone, and I see usb modules inserted and I see mass storage module detecting the usb device but it printed another messages about "scsi_wait_scan module not found" and again root device not found.

I am using SD card with single ext3 partition with fs label "OLPCRoot" in usb card reader or directly in SD slot (just like it works with previous OS versions).

Then I extracted initrd with gzip and cpio, copied /lib/modules from actdrd, repacked and can confirm the original initrd code behaves exactly the same as actrd one.

Then I found file cmdline/20olpc-boot-cmdline.sh inside intrd that checks boot device from ofw and hardcodes root=/dev/sda2 with this code:
if [ -z "$root" ]; then

# if no root device was specified, use OFW bootpath to find root

...

/pci/usb@*) root="/dev/sda2" ;; # external USB, assume partitioned

So I changed sda2 to sda1 but it still does not boot with same message - root device not found. Sorry that I don't have exact error messages but the device does not boot so I cannot copy them directly.

I am using SD card with single ext3 partition with fs label "OLPCRoot" in usb card reader or directly in SD slot (just like it works with previous OS versions).

[...]

Then I found file cmdline/20olpc-boot-cmdline.sh inside intrd that checks boot device from ofw and hardcodes root=/dev/sda2 with this code:
if [ -z "$root" ]; then

# if no root device was specified, use OFW bootpath to find root

...

/pci/usb@*) root="/dev/sda2" ;; # external USB, assume partitioned

So I changed sda2 to sda1 but it still does not boot with same message - root device not found. Sorry that I don't have exact error messages but the device does not boot so I cannot copy them directly.

This change may work if you are booting from a USB.
If you are booting from a single partition SDcard, try changing root="/dev/disk/mmc/mmc${tmp}p2" to root="/dev/disk/mmc/mmc${tmp}p1"
Though it might be simpler to use a simple /boot/olpc.fth and point it directly to your initrd.img and vmlinuz in the SDcard.

This should work in next 12.1.0 build as USB stuff is now included in the kernel (x86-3.1 2098f73d2).

However, the requirements are that the SD card or USB disk must be partitioned in the way that is produced by the sd_card_image module of olpc-os-builder. That is, the first partition includes boot contents, and the second includes the main filesystem. For SD I would suggest just using sd_card_image.

For USB, if working from the tree tarball, the following should work:

extract the entire contents of the tarball onto the 2nd partition

look at the name of the directory in versions/pristine (e.g. "884"). This is the fs version number and will be referred to as FSVERSION below.

On the first partition (PARTITION1), create security and boot-versions toplevel directories

Another option for USB is to use olpc-os-builder sd_card_image to create an image of appropriate size.
Enable sd_card_image's keep_disk_image=1 option so that a disk image is saved. You can then dd this to a USB disk and it should work.

Assuming fixed in 12.1.0 build 2 - please reopen if this is problematic.

Some more info for the future release. Tried it on the XO-1.5 with 12.1.0/os18.
It shows the same "strictatime" error but continues to mount the ext2 and ext4 mmc0p1 and 2 partitions and then fails with