[beaglebone] Help on rootfs encryption for Beaglebone Green

Oh yeah we just fixed this issue too..

When your image is a single partition, the flasher will bomb when
writting a dual partition..

we've added a option to setup_sdcard.sh to fix this:


so it'll crate a dual partition base image..

For: 2016-09-04, grab the base file:


extract it

You'll want to then update the "setup_sdcard.sh" here's the master:


sudo ./setup_sdcard.sh --img-4gb bone --dtb beaglebone
--bbb-old-bootloader-in-emmc --rootfs_label rootfs --hostname
beaglebone --enable-cape-universal --enable-fat-partition

If you want it to flash the eMMC just add "--emmc-flasher" to the list
of options

Then just dd that bone-4gb.img to a microsd


Ok I’ll try this.

Thank you


+beaglebone as it was the original thread

Hi Robert,

I may be doing something wrong, but following exactly what you proposed result in a lot of “Cannot mkdir: No space left on device” and “Cannot open: No such file or directory” while the script populate_rootfs. The last displayed line is “tar: Exiting with failure status due to previous errors”

I’ll try to understand if I did something wrong, but if you find something in the script let me know.


Hi Robert,

I put some debug output in the scripts (enormous script 0_0) and it seems
that when it creates the loop device to associate with device-mapper for
the rootfs it's giving it only 2MB.

The rootfs is certainly not going to fit in it. :slight_smile:


Hi Robert,

a very big thank for your help, but it is still not working.
I’ve traced the script and generated a pastebin http://pastebin.com/h9eRtZC1
We can see that sfdisk is creating a partition layout with 96MB fat partition for boot but then create a partition of only 3MB that will be used for rootfs.

This leads to the failures described earlier.
Do you have any idea why this is happening ?


Ah yes, this is a new problem, since we increased the 1MB hole to 4MB
at the start of the drive, (for an ever increasing u-boot)..

Our dual partition sfdisk command changed from:

sudo sfdisk /dev/sde <<-__EOF__

Okay, this is now fixed:


now just to port it to all the eMMC flasher's.. :wink:


and now all the eMMC flashers have that fix too.. (along with a sync
of some of the generic stuff)