How to burn recovery.img to the specified partition

How can I use flash.sh to burn recovery.img to the specified partition or how can I use flash.sh to burn recovery.img only?

according to Topic 230718, you’re using Jetson TX2 NX and BSP version 32.7.2

may I know what’s the actual use-case?
there’s “recovery” partition to contains recovery image, you may try following commands to flash specific partition.
for example, $ sudo ./flash.sh -r -k recovery jetson-xavier-nx-devkit-tx2-nx mmcblk0p1

1.Which partition will this operation burn the recovery.img to and where to find it ?
2.Now, I found the recovery.img,how can i direct mount it by linux command ?

hello 17679339172,

you may check xml file for partition layout,
for example, $OUT/Linux_for_Tegra/bootloader/t186ref/cfg/flash_l4t_t186.xml

        <partition name="RECNAME" type="data" oem_sign="true">
            <allocation_policy> sequential </allocation_policy>
            <filesystem_type> basic </filesystem_type>
            <size> RECSIZE </size>
            <file_system_attribute> 0 </file_system_attribute>
            <allocation_attribute> 8 </allocation_attribute>
            <percent_reserved> 0 </percent_reserved>
            <filename> RECFILE </filename>
            <description> **Required.** Contains recovery image. </description>

may I know what’s the actual use-case?


This should be the 24th partition(/dev/mmcblk0p23), How do I mount it?
I use "mount /dev/mmcblk0p23 /xxx " , but failed

please check $ ls -la /dev/disk/by-partlabel/. let me ask you again, may I know what’s the actual use-case?

root@tegra-ubuntu:/home/nv# ls -la /dev/disk/by-partlabel/
total 0
drwxr-xr-x 2 root root 700 Dec 10 09:15 .
drwxr-xr-x 8 root root 160 Dec 10 09:15 …
lrwxrwxrwx 1 root root 16 Dec 10 09:15 adsp-fw → …/…/mmcblk0p11
lrwxrwxrwx 1 root root 16 Dec 10 09:15 adsp-fw_b → …/…/mmcblk0p12
lrwxrwxrwx 1 root root 15 Dec 10 09:15 APP → …/…/mmcblk0p1
lrwxrwxrwx 1 root root 16 Dec 10 09:15 BMP → …/…/mmcblk0p22
lrwxrwxrwx 1 root root 16 Dec 10 09:15 BMP_b → …/…/mmcblk0p23
lrwxrwxrwx 1 root root 15 Dec 10 09:15 bootloader-dtb → …/…/mmcblk0p6
lrwxrwxrwx 1 root root 15 Dec 10 09:15 bootloader-dtb_b → …/…/mmcblk0p7
lrwxrwxrwx 1 root root 16 Dec 10 09:15 bpmp-fw → …/…/mmcblk0p13
lrwxrwxrwx 1 root root 16 Dec 10 09:15 bpmp-fw_b → …/…/mmcblk0p14
lrwxrwxrwx 1 root root 16 Dec 10 09:15 bpmp-fw-dtb → …/…/mmcblk0p15
lrwxrwxrwx 1 root root 16 Dec 10 09:15 bpmp-fw-dtb_b → …/…/mmcblk0p16
lrwxrwxrwx 1 root root 15 Dec 10 09:15 cpu-bootloader → …/…/mmcblk0p4
lrwxrwxrwx 1 root root 15 Dec 10 09:15 cpu-bootloader_b → …/…/mmcblk0p5
lrwxrwxrwx 1 root root 16 Dec 10 09:15 eks → …/…/mmcblk0p10
lrwxrwxrwx 1 root root 16 Dec 10 09:15 FBNAME → …/…/mmcblk0p21
lrwxrwxrwx 1 root root 16 Dec 10 09:15 kernel → …/…/mmcblk0p28
lrwxrwxrwx 1 root root 16 Dec 10 09:15 kernel_b → …/…/mmcblk0p29
lrwxrwxrwx 1 root root 16 Dec 10 09:15 kernel-bootctrl → …/…/mmcblk0p26
lrwxrwxrwx 1 root root 16 Dec 10 09:15 kernel-bootctrl_b → …/…/mmcblk0p27
lrwxrwxrwx 1 root root 16 Dec 10 09:15 kernel-dtb → …/…/mmcblk0p30
lrwxrwxrwx 1 root root 16 Dec 10 09:15 kernel-dtb_b → …/…/mmcblk0p31
lrwxrwxrwx 1 root root 15 Dec 10 09:15 mts-bootpack → …/…/mmcblk0p2
lrwxrwxrwx 1 root root 15 Dec 10 09:15 mts-bootpack_b → …/…/mmcblk0p3
lrwxrwxrwx 1 root root 16 Dec 10 09:15 recovery → …/…/mmcblk0p24
lrwxrwxrwx 1 root root 16 Dec 10 09:15 recovery-dtb → …/…/mmcblk0p25
lrwxrwxrwx 1 root root 16 Dec 10 09:15 RECROOTFS → …/…/mmcblk0p32
lrwxrwxrwx 1 root root 16 Dec 10 09:15 sc7 → …/…/mmcblk0p19
lrwxrwxrwx 1 root root 16 Dec 10 09:15 sc7_b → …/…/mmcblk0p20
lrwxrwxrwx 1 root root 16 Dec 10 09:15 sce-fw → …/…/mmcblk0p17
lrwxrwxrwx 1 root root 16 Dec 10 09:15 sce-fw_b → …/…/mmcblk0p18
lrwxrwxrwx 1 root root 15 Dec 10 09:15 secure-os → …/…/mmcblk0p8
lrwxrwxrwx 1 root root 15 Dec 10 09:15 secure-os_b → …/…/mmcblk0p9
lrwxrwxrwx 1 root root 16 Dec 10 09:15 UDA → …/…/mmcblk0p33

recovery is In the /dev/mmcblk0p24,but i can not mount it.

root@tegra-ubuntu:/# mount /dev/mmcblk0p24 /test/
NTFS signature is missing.
Failed to mount ‘/dev/mmcblk0p24’: Invalid argument
The device ‘/dev/mmcblk0p24’ doesn’t seem to have a valid NTFS.
Maybe the wrong device is used? Or the whole disk instead of a
partition (e.g. /dev/sda, not /dev/sda1)? Or the other way around?

how do I mount it?

Partitions would normally also have an ID associated with them, one which is consistent with the filesystem type. Likely this is what it is complaining about if it was set up for Linux, but then formatted as NTFS. If you run “sudo gdisk -l /dev/mmcblk0p23” what do you see? What do you see for an ext4 partition type, e.g., “sudo gdisk -l /dev/mmcblk0p1”? It could be some other issue, but I’d start by looking at the partition ID.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.