Page 1 of 1

[Solved] Neo2 boot from usb

Posted: Fri Dec 14, 2018 5:46 pm
by Mrserii
Hey everyone,

Bought neo2 board. Unlike banana h3, i cant find what exact file to edit (to put the ssd path in boot partition) after i dd the sd card to usb ssd.

"dd if=/dev/mmcblk0 of=/dev/sda bs=1M"

Then what file edit to put the ssd uuid ?

Any suggestions?

Re: Neo2 boot from usb

Posted: Fri Dec 21, 2018 4:26 pm
by MichaIng
I am setting up a NanoPi T1 Plus later for testing reasons and will check where to find the bootloader cmd line. I hope it is possible without the need to recompile some bootloader/initramfs parts or something, but perhaps there is a reason why DietPi-Drive_Manager currently only supports userdata moving for RPi and Odroids.

Re: Neo2 boot from usb

Posted: Sun Dec 30, 2018 10:43 pm
by Mrserii
I will wait :D

Re: Neo2 boot from usb

Posted: Mon Dec 31, 2018 12:46 am
by MichaIng
Okay just checked, although not fully tested. Please create a full backup of the SDcard first, so you can recover from external system, if it does not boot up.

Boot arguments can be adjusted within /boot/boot.cmd.

In the line setenv bootargs edit root=/dev/mmcblk0p2 to the new root partition.

Then run mkimage -C none -A arm -T script -d /boot/boot.cmd /boot/boot.scr to convert to uboot readable config.

mkimage might need to be installed first: apt-get install -y u-boot-tools

Also adjust /etc/fstab to mount the new root partition.

Note that the boot partition itself needs to stay on the SDcard, since this is AFAIK the hardcoded place where SBCs are trying to initially boot from (start bootloader).
So instead of dd if=/dev/mmcblk0 of=/dev/sda bs=1M, only copy the root partition, e.g.: dd if=/dev/mmcblk0p2 of=/dev/sda1 bs=1M (with target partition already created)

This seems to be consistent across NanoPi. So if this works well, we could implement into dietpi-drive_manager, as we already support it for RPi and Odroids. Only difference here is the mkimage command, since bootloader seems to not read /boot/boot.cmd directly, similar to x86 grub devices, where update-grub is required after editing the cmd line arguments.

Re: Neo2 boot from usb

Posted: Sat Jan 05, 2019 12:49 pm
by Mrserii
it's work with neo2, smsung evo 850 256g !!!

will post more info when finish install my server need's !

tnx !

Re: Neo2 boot from usb

Posted: Mon Jan 14, 2019 5:16 pm
by MichaIng
Thanks for the reply, I opened an issue on GitHub to implement this natively into DietPi-Drive_Manager: