Is it any simple way to create working Linux system image together with u-boot and u-boot configuration and copy it on another apalis T30 board?
How to build a custom BSP image is explained in the following article on our developer website.
I saw this website, but the question is, if can I create Backup Flash Image of currently working system and copy it on another apalis T30 boards?
While this is definitely not the recommended way how to deploy Embedded Linux firmware you may of course copy the entire eMMC contents from one module to another one with whatever implications of to be unique parts thereof you may violate.
The easiest approach would be to use U-Boot’s UMS aka USB mass storage mode to make the whole eMMC accessible like a regular USB mass storage device in order to do with it as you please:
Apalis T30 # ums 0 mmc 0
You may even re-use resp. file system image(s) obtained as per the above method to flash it/them to modules again using our regular update.sh script approach by just replacing resp. image files.
After running this command USB mass storage appears, but not working correctly. In attachment you will find dmesg log and lspci -vv log. Do you have any ideas how to resolve this problem link text?
Strange, for me that works just fine:
[ 9464.296261] usb 2-188.8.131.52: new high-speed USB device number 33 using xhci_hcd [ 9464.370152] usb 2-184.108.40.206: New USB device found, idVendor=1b67, idProduct=401a [ 9464.370156] usb 2-220.127.116.11: New USB device strings: Mfr=1, Product=2, SerialNumber=3 [ 9464.370158] usb 2-18.104.22.168: Product: USB download gadget [ 9464.370159] usb 2-22.214.171.124: Manufacturer: Toradex [ 9464.398638] usb-storage 2-126.96.36.199:1.0: USB Mass Storage device detected [ 9464.399391] scsi host3: usb-storage 2-188.8.131.52:1.0 [ 9464.399504] usbcore: registered new interface driver usb-storage [ 9464.401747] usbcore: registered new interface driver uas [ 9465.402741] scsi 3:0:0:0: Direct-Access Linux UMS disk ffff PQ: 0 ANSI: 2 [ 9465.403288] sd 3:0:0:0: Attached scsi generic sg2 type 0 [ 9465.403763] sd 3:0:0:0: [sdc] 7733248 512-byte logical blocks: (3.96 GB/3.69 GiB) [ 9465.403913] sd 3:0:0:0: [sdc] Write Protect is off [ 9465.403916] sd 3:0:0:0: [sdc] Mode Sense: 0f 00 00 00 [ 9465.404030] sd 3:0:0:0: [sdc] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA [ 9465.413305] sdc: sdc1 sdc2 [ 9465.413463] sdc: p2 size 15175680 extends beyond EOD, enabling native capacity [ 9465.417485] sdc: sdc1 sdc2 [ 9465.417640] sdc: p2 size 15175680 extends beyond EOD, truncated [ 9465.418560] sd 3:0:0:0: [sdc] Attached SCSI removable disk [ 9466.313453] EXT4-fs (sdc2): mounting ext3 file system using the ext4 subsystem [ 9466.395639] EXT4-fs (sdc2): mounted filesystem with ordered data mode. Opts: (null)
Have you tried connecting it to a different USB port on your Linux development workstation?
What carrier board are you trying this with?
What exact hardware/software versions of things are we talking about?
Looks like your PC is not quite happy with the USB connection.
What carrier board did you try this with?
Have you tried any different USB ports or even on a different PC at all?
@marcel.tx The partition in which u-boot resides should be cloned as well. Then one needs to run u-boot from ram using the recovery mode, right?
I made the eMMC accessible to the host as usb mass storage device running
Apalis TK1 # ums 0 mmc 0 in the u-boot prompt. Then
rootfs have been mounted in
/media/kromer/rootfs. But no directory content was visible. I had to unmount and mount
rootfs again. Like expected
rootfs contains all the file system files.
But how can I clone/restore the whole system image information (including mbr, u-boot, etc.) in one “atomic” step? If I boot into linux on the target I should be able to use
ssh to transfer the whole eMMC content (including /dev/mmcblk0/mmcblk0boot1 and …/mmcblk0boot1) to the host over ethernet using something like
ubuntu@tegra-ubuntu:~$ dd if=/dev/mmcblk0 | ssh firstname.lastname@example.org "dd of=/home/kromer/full_backup.img" http://stackoverflow.com/questions/11681079/do-i-have-to-unmount-dev-mmcblk0-when-doing-dd-over-ssh. But my rootfs is not readonly and this could be a problem I guess… Would it make any difference to clone the eMMC by accessing it from the host side (something like
kromer@rc-019:~$ dd ssh email@example.com "dd if=/dev/mmcblk0" | dd of=home/kromer/full_backup.img)?
@Florian_K Hijacking an old thread is not really recommended. Could you please ask the same as part of a new question?
@marcel.tx I added the question https://www.toradex.com/community/questions/8356/system-image-flash-onto-emmc-via-dd.html#answer-8420 to my original question from which I was guided here…