My customer also ask for the guide. I suppose BU has a ready one, please share with us.
as customer company uses a shared Linux Server remotely, it is not convenient to access the Linux computer physically.
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
My customer also ask for the guide. I suppose BU has a ready one, please share with us.
as customer company uses a shared Linux Server remotely, it is not convenient to access the Linux computer physically.
Tony,
Here are the steps I followed on an Ubuntu 18.04 Host machine to create an image of an SD Card. I verified the card booted on a Beaglebone Black.
This process is based on this page, which provides a bit more context on what is being done and may be useful for others.
Create a File on Host Computer
fallocate -l 1G sdk.img
Create a Loop
sudo modprobe loop
sudo losetup -f
Connect the Loop to the File
sudo losetup /dev/loop10 sdk.img
*Note this loop needs to be the one created above
Partition the Loop like you want the SD Card partitioned.
This follows the SD Card Creation script in the SDK.
sudo parted -s /dev/loop10 mklabel msdos
sudo parted -s /dev/loop10 unit cyl mkpart primary fat32 -- 0 9
sudo parted -s /dev/loop10 set 1 boot on
sudo parted -s /dev/loop10 unit cyl mkpart primary ext4 -- 9 -2
Format the partitions
sudo fdisk -l /dev/loop10
sudo mkfs.vfat /dev/loop10p1
mkdir boot
sudo mount /dev/loop10p1 boot
sudo mkfs.ext4 /dev/loop10p2
mkdir rootfs
sudo mount /dev/loop10p2 rootfs/
Copy files to the partitions. The example below assumes the SDK is in TISDK.
This was tested on a beaglebone black, adjust as needed.
cd TISDK/board-support/prebuilt-images/
sudo cp am335x-boneblack.dtb /home/boot/
sudo cp MLO-am335x-evm /home/boot/MLO
sudo cp u-boot-am335x-evm.img /home/boot/u-boot.img
Untar the filesystem. This uses the base filesystem provided with the SDK.
cd ../../filesystem
sudo tar -xvf arago-base-tisdk-image-am335x-evm.tar.xz -C /home/rootfs/
sync
cd back to where boot and rootfs were created
sudo umount boot rootfs
Delete the loop
sudo losetup -d /dev/loop10
Copy the file to an SD Card. Note that /dev/sde needs to be where the SD Card
is mounted on the Host computer.
sudo dd bs=4M if=sdk.img of=/dev/sde conv=fsync
sync
sync
That's it. Unmount and eject the SD card from the host and use it to boot the target board.
The filesystem will be limited to the size of the image created above. In this case, it is 1GB. You can create the file larger to be closer to your SD Card size or resize it on the target as needed once booted.
Hope this helps.