Jetson AGX will not flash - ERROR: Flash Jetson AGX Xavier

I’m trying to get my AGX working for the first time.
It is connected by USB-C to my host computer (a laptop running Ubuntu 18.04.6 LTS). It has 120GB free disk space.
Nothing is coming out of the HDMI but I can confirm that the system is in FRM using lsusb:

...
Bus 001 Device 053: ID 0955:7019 NVidia Corp. 
...

Using SDK Manager 1.6.1.8175, the flash fails. The ERROR log shows:

11:47:39 ERROR: Flash Jetson AGX Xavier - flash: Board ID(2888) version(400) sku(0004) revision(L.0)
11:47:41 ERROR: Flash Jetson AGX Xavier - flash: 30412 blocks
11:47:46 ERROR: Flash Jetson AGX Xavier - flash: 66117 blocks
11:47:46 ERROR: Flash Jetson AGX Xavier - flash: 20+0 records in
11:48:08 ERROR: Flash Jetson AGX Xavier - flash: [error]: : [exec_command]: /bin/bash -c /tmp/tmp_NV_L4T_FLASH_JETSON_XAVIER_WITH_OS_IMAGE_COMP.sh; [error]: /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/flash.sh: line 512: 31484 Killed ./mksparse ${blblksizeoption} --fillpattern=${__fillpat} ${__localsysfile}.raw ${__localsysfile}
11:48:08 ERROR: Flash Jetson AGX Xavier - flash: command terminated with error
11:48:08 SUMMARY: Flash Jetson AGX Xavier - flash: First Error: Installation failed.

The full log is as follows:


13:15:51 INFO: Flash Jetson AGX Xavier - flash: [ 0.0054 ] tegrabct_v2 --chip 0x19 0 --ratchet_blob ratchet_blob.bin --minratchet tegra194-mb1-bct-ratchet-p2888-0000-p2822-0000.cfg
13:15:51 INFO: Flash Jetson AGX Xavier - flash: [ 0.0135 ] adding BCH for 1_kernel_tegra194-p2888-0001-p2822-0000.dtb
13:15:51 INFO: Flash Jetson AGX Xavier - flash: [ 0.0307 ] Signed file: /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/temp_user_dir/kernel_tegra194-p2888-0001-p2822-0000_sigheader.dtb.encrypt
13:15:51 INFO: Flash Jetson AGX Xavier - flash: l4t_sign_image.sh: Generate header for kernel_tegra194-p2888-0001-p2822-0000_sigheader.dtb.encrypt
13:15:51 INFO: Flash Jetson AGX Xavier - flash: l4t_sign_image.sh: chip 0x19: add 0x45651 to offset 0x8 in sig file
13:15:51 INFO: Flash Jetson AGX Xavier - flash: l4t_sign_image.sh: Generate 16-byte-size-aligned base file for kernel_tegra194-p2888-0001-p2822-0000_sigheader.dtb.encrypt
13:15:51 INFO: Flash Jetson AGX Xavier - flash: done.
13:15:51 INFO: Flash Jetson AGX Xavier - flash: populating kernel to rootfs... done.
13:15:51 INFO: Flash Jetson AGX Xavier - flash: populating initrd to rootfs... done.
13:15:51 INFO: Flash Jetson AGX Xavier - flash: Making system.img...
13:16:14 INFO: Flash Jetson AGX Xavier - flash: populating rootfs from /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/rootfs ... populating /boot/extlinux/extlinux.conf ... done.
13:16:14 INFO: Flash Jetson AGX Xavier - flash: generating sig file of Image ... /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/tegraflash.py --chip 0x19 --key --minratchet_config tegra194-mb1-bct-ratchet-p2888-0000-p2822-0000.cfg --cmd sign ./boot/Image kernel
13:16:14 INFO: Flash Jetson AGX Xavier - flash: [ 0.0057 ] tegrabct_v2 --chip 0x19 0 --ratchet_blob ratchet_blob.bin --minratchet tegra194-mb1-bct-ratchet-p2888-0000-p2822-0000.cfg
13:16:14 INFO: Flash Jetson AGX Xavier - flash: [ 0.0111 ] tegrahost_v2 --chip 0x19 --align 1_Image
13:16:14 INFO: Flash Jetson AGX Xavier - flash: [ 0.0163 ] adding BCH for 1_Image
13:16:15 INFO: Flash Jetson AGX Xavier - flash: [ 0.5867 ] Assuming zero filled SBK key : not reading
13:16:15 INFO: Flash Jetson AGX Xavier - flash: [ 0.6771 ] tegrahost_v2 --chip 0x19 0 --updatesigheader 1_Image_sigheader.encrypt 1_Image_sigheader.hash zerosbk
13:16:15 INFO: Flash Jetson AGX Xavier - flash: [ 1.0202 ] Signed file: /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/mnt/Image_sigheader.encrypt
13:16:15 INFO: Flash Jetson AGX Xavier - flash: l4t_sign_image.sh: Generate header for Image_sigheader.encrypt
13:16:15 INFO: Flash Jetson AGX Xavier - flash: l4t_sign_image.sh: Generate 16-byte-size-aligned base file for Image_sigheader.encrypt
13:16:15 INFO: Flash Jetson AGX Xavier - flash: l4t_sign_image.sh: the sign header is saved at ./boot/Image.sig
13:16:15 INFO: Flash Jetson AGX Xavier - flash: done.
13:16:15 INFO: Flash Jetson AGX Xavier - flash: generating sig file of kernel_tegra194-p2888-0001-p2822-0000.dtb ... /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/tegraflash.py --chip 0x19 --key --minratchet_config tegra194-mb1-bct-ratchet-p2888-0000-p2822-0000.cfg --cmd sign ./boot/dtb/kernel_tegra194-p2888-0001-p2822-0000.dtb kernel_dtb
13:16:15 INFO: Flash Jetson AGX Xavier - flash: [ 0.0062 ] tegrabct_v2 --chip 0x19 0 --ratchet_blob ratchet_blob.bin --minratchet tegra194-mb1-bct-ratchet-p2888-0000-p2822-0000.cfg
13:16:15 INFO: Flash Jetson AGX Xavier - flash: [ 0.0377 ] tegrahost_v2 --chip 0x19 --align 1_kernel_tegra194-p2888-0001-p2822-0000.dtb
13:16:16 INFO: Flash Jetson AGX Xavier - flash: [ 0.0557 ] adding BCH for 1_kernel_tegra194-p2888-0001-p2822-0000.dtb
13:16:16 INFO: Flash Jetson AGX Xavier - flash: [ 0.0660 ] Assuming zero filled SBK key : not reading
13:16:16 INFO: Flash Jetson AGX Xavier - flash: l4t_sign_image.sh: Generate header for kernel_tegra194-p2888-0001-p2822-0000_sigheader.dtb.encrypt
13:16:16 INFO: Flash Jetson AGX Xavier - flash: done.
13:16:16 INFO: Flash Jetson AGX Xavier - flash: generating sig file of initrd ... /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/tegraflash.py --chip 0x19 --key --cmd sign ./boot/initrd data
13:16:16 INFO: Flash Jetson AGX Xavier - flash: [ 0.0520 ] tegrahost_v2 --chip 0x19 --align 1_initrd
13:16:16 INFO: Flash Jetson AGX Xavier - flash: [ 0.0680 ] tegrahost_v2 --chip 0x19 0 --magicid DATA --appendsigheader 1_initrd zerosbk
13:16:16 INFO: Flash Jetson AGX Xavier - flash: [ 0.0698 ] adding BCH for 1_initrd
13:16:16 INFO: Flash Jetson AGX Xavier - flash: [ 0.4870 ] Assuming zero filled SBK key : not reading
13:16:16 INFO: Flash Jetson AGX Xavier - flash: [ 0.5048 ] tegrahost_v2 --chip 0x19 0 --updatesigheader 1_initrd_sigheader.encrypt 1_initrd_sigheader.hash zerosbk
13:16:16 INFO: Flash Jetson AGX Xavier - flash: [ 0.5738 ] Signed file: /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/mnt/initrd_sigheader.encrypt
13:16:16 INFO: Flash Jetson AGX Xavier - flash: l4t_sign_image.sh: Generate 16-byte-size-aligned base file for initrd_sigheader.encrypt
13:16:16 INFO: Flash Jetson AGX Xavier - flash: generating sig file of extlinux.conf ... /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/tegraflash.py --chip 0x19 --key --cmd sign ./boot/extlinux/extlinux.conf data
13:16:16 INFO: Flash Jetson AGX Xavier - flash: [ 0.0054 ] tegrahost_v2 --chip 0x19 --align 1_extlinux.conf
13:16:16 INFO: Flash Jetson AGX Xavier - flash: [ 0.0101 ] tegrahost_v2 --chip 0x19 0 --magicid DATA --appendsigheader 1_extlinux.conf zerosbk
13:16:16 INFO: Flash Jetson AGX Xavier - flash: [ 0.0152 ] Assuming zero filled SBK key : not reading
13:16:16 INFO: Flash Jetson AGX Xavier - flash: [ 0.0202 ] tegrahost_v2 --chip 0x19 0 --updatesigheader 1_extlinux_sigheader.conf.encrypt 1_extlinux_sigheader.conf.hash zerosbk
13:16:16 INFO: Flash Jetson AGX Xavier - flash: l4t_sign_image.sh: chip 0x19: add 0x360 to offset 0x8 in sig file
13:16:16 INFO: Flash Jetson AGX Xavier - flash: l4t_sign_image.sh: Generate 16-byte-size-aligned base file for extlinux_sigheader.conf.encrypt
13:16:16 INFO: Flash Jetson AGX Xavier - flash: l4t_sign_image.sh: the sign header is saved at ./boot/extlinux/extlinux.conf.sig
13:16:16 INFO: Flash Jetson AGX Xavier - flash: done.
13:16:21 INFO: Flash Jetson AGX Xavier - flash: Sync'ing system.img ... done.
13:16:22 ERROR: Flash Jetson AGX Xavier - flash: /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/flash.sh: line 512: 16726 Killed ./mksparse ${blblksizeoption} --fillpattern=${__fillpat} ${__localsysfile}.raw ${__localsysfile}
13:16:22 ERROR: Flash Jetson AGX Xavier - flash: command terminated with error
13:16:22 SUMMARY: DateTime Target Setup - target: Depends on failed component

I tried manually flashing with sudo ./flash.sh jetson-agx-xavier-devkit mmcblk0p1. Here is the whole output:

###############################################################################
# L4T BSP Information:
# R32 , REVISION: 6.1
###############################################################################
# Target Board Information:
# Name: jetson-agx-xavier-devkit, Board Family: t186ref, SoC: Tegra 194, 
# OpMode: production, Boot Authentication: NS, 
# Disk encryption: disabled ,
###############################################################################
copying soft_fuses(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/t186ref/BCT/tegra194-mb1-soft-fuses-l4t.cfg)... done.
./tegraflash.py --chip 0x19 --applet "/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/mb1_t194_prod.bin" --skipuid --soft_fuses tegra194-mb1-soft-fuses-l4t.cfg --bins "mb2_applet nvtboot_applet_t194.bin" --cmd "dump eeprom boardinfo cvm.bin;reboot recovery" 
Welcome to Tegra Flash
version 1.0.0
Type ? or help for help and q or quit to exit
Use ! to execute system commands
 
[   0.0025 ] Generating RCM messages
[   0.0038 ] tegrahost_v2 --chip 0x19 0 --magicid MB1B --appendsigheader /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/mb1_t194_prod.bin zerosbk
[   0.0048 ] Header already present for /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/mb1_t194_prod.bin
[   0.0089 ] 
[   0.0113 ] tegrasign_v3.py --getmode mode.txt --key None
[   0.0115 ] Assuming zero filled SBK key
[   0.0141 ] tegrasign_v3.py --file /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/mb1_t194_prod_sigheader.bin --key None --length 1136 --offset 2960 --pubkeyhash pub_key.key
[   0.0141 ] Assuming zero filled SBK key
[   0.0196 ] tegrahost_v2 --chip 0x19 0 --updatesigheader /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/mb1_t194_prod_sigheader.bin /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/mb1_t194_prod_sigheader.hash zerosbk
[   0.0227 ] 
[   0.0253 ] tegrabct_v2 --chip 0x19 0 --sfuse tegra194-mb1-soft-fuses-l4t.cfg.pdf sfuse.bin
[   0.0263 ] 
[   0.0283 ] tegrarcm_v2 --listrcm rcm_list.xml --chip 0x19 0 --sfuses sfuse.bin --download rcm /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/mb1_t194_prod_sigheader.bin 0 0
[   0.0291 ] RCM 0 is saved as rcm_0.rcm
[   0.0314 ] RCM 1 is saved as rcm_1.rcm
[   0.0314 ] RCM 2 is saved as rcm_2.rcm
[   0.0314 ] List of rcm files are saved in rcm_list.xml
[   0.0314 ] 
[   0.0314 ] Signing RCM messages
[   0.0338 ] tegrasign_v3.py --getmontgomeryvalues montgomery.bin --key None --list rcm_list.xml --pubkeyhash pub_key.key
[   0.0338 ] Assuming zero filled SBK key
[   0.0400 ] Copying signature to RCM mesages
[   0.0424 ] tegrarcm_v2 --chip 0x19 0 --updatesig rcm_list_signed.xml
[   0.0439 ] 
[   0.0439 ] Boot Rom communication
[   0.0459 ] tegrarcm_v2 --chip 0x19 0 --rcm rcm_list_signed.xml --skipuid
[   0.0469 ] RCM version 0X190001
[   0.4247 ] Boot Rom communication completed
[   1.4411 ] 
[   2.4452 ] tegrarcm_v2 --isapplet
[   2.4462 ] Applet version 01.00.0000
[   3.2427 ] 
[   3.2451 ] tegrarcm_v2 --ismb2
[   4.0743 ] 
[   4.0768 ] tegrahost_v2 --chip 0x19 --align nvtboot_applet_t194.bin
[   4.0777 ] 
[   4.0799 ] tegrahost_v2 --chip 0x19 0 --magicid PLDT --appendsigheader nvtboot_applet_t194.bin zerosbk
[   4.0809 ] adding BCH for nvtboot_applet_t194.bin
[   4.0887 ] 
[   4.0922 ] tegrasign_v3.py --key None --list nvtboot_applet_t194_sigheader.bin_list.xml --pubkeyhash pub_key.key
[   4.0923 ] Assuming zero filled SBK key
[   4.0975 ] tegrahost_v2 --chip 0x19 0 --updatesigheader nvtboot_applet_t194_sigheader.bin.encrypt nvtboot_applet_t194_sigheader.bin.hash zerosbk
[   4.0999 ] 
[   4.1020 ] tegrarcm_v2 --download mb2 nvtboot_applet_t194_sigheader.bin.encrypt
[   4.1029 ] Applet version 01.00.0000
[   4.9098 ] Sending mb2
[   4.9100 ] [................................................] 100%
[   4.9259 ] 
[   4.9311 ] tegrarcm_v2 --boot recovery
[   4.9346 ] Applet version 01.00.0000
[   5.7459 ] 
[   6.7529 ] tegrarcm_v2 --isapplet
[   7.5540 ] 
[   7.5565 ] tegrarcm_v2 --ismb2
[   7.5574 ] MB2 Applet version 01.00.0000
[   8.3872 ] 
[   8.3928 ] tegrarcm_v2 --ismb2
[   8.3966 ] MB2 Applet version 01.00.0000
[   9.2184 ] 
[   9.2208 ] Retrieving board information
[   9.2231 ] tegrarcm_v2 --oem platformdetails chip chip_info.bin
[   9.2240 ] MB2 Applet version 01.00.0000
[  10.0563 ] Saved platform info in chip_info.bin
[  10.0601 ] Chip minor revision: 2
[  10.0601 ] Bootrom revision: 0xf
[  10.0602 ] Ram code: 0x2
[  10.0603 ] Chip sku: 0xd0
[  10.0603 ] Chip Sample: non es
[  10.0607 ] 
[  10.0609 ] Retrieving EEPROM data
[  10.0609 ] tegrarcm_v2 --oem platformdetails eeprom cvm /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/cvm.bin
[  10.0623 ] MB2 Applet version 01.00.0000
[  10.8890 ] Saved platform info in /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/cvm.bin
[  10.9232 ] 
[  10.9234 ] Rebooting to recovery mode
[  10.9288 ] tegrarcm_v2 --ismb2
[  10.9325 ] MB2 Applet version 01.00.0000
[  11.7267 ] 
[  11.7267 ] Rebooting to recovery mode
[  11.7292 ] tegrarcm_v2 --reboot recovery
[  11.7300 ] MB2 Applet version 01.00.0000
[  12.5647 ] 
Board ID(2888) version(400) sku(0004) revision(L.0)
Copy /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/kernel/dtb/tegra194-p2888-0001-p2822-0000.dtb to /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/kernel/dtb/tegra194-p2888-0001-p2822-0000.dtb.rec
copying bctfile(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/t186ref/BCT/tegra194-mb1-bct-memcfg-p2888.cfg)... done.
copying bctfile1(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/t186ref/BCT/tegra194-memcfg-sw-override.cfg)... done.
copying uphy_config(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/t186ref/BCT/tegra194-mb1-uphy-lane-p2888-0000-p2822-0000.cfg)... done.
copying minratchet_config(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/t186ref/BCT/tegra194-mb1-bct-ratchet-p2888-0000-p2822-0000.cfg)... done.
copying device_config(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/t186ref/BCT/tegra19x-mb1-bct-device-sdmmc.cfg)... done.
copying misc_cold_boot_config(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/t186ref/BCT/tegra194-mb1-bct-misc-l4t.cfg)... done.
copying misc_config(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/t186ref/BCT/tegra194-mb1-bct-misc-flash.cfg)... done.
copying pinmux_config(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/t186ref/BCT/tegra19x-mb1-pinmux-p2888-0000-a04-p2822-0000-b01.cfg)... done.
copying gpioint_config(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/t186ref/BCT/tegra194-mb1-bct-gpioint-p2888-0000-p2822-0000.cfg)... done.
copying pmic_config(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/t186ref/BCT/tegra194-mb1-bct-pmic-p2888-0001-a04-E-0-p2822-0000.cfg)... done.
copying pmc_config(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/t186ref/BCT/tegra19x-mb1-padvoltage-p2888-0000-a00-p2822-0000-a00.cfg)... done.
copying prod_config(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/t186ref/BCT/tegra19x-mb1-prod-p2888-0000-p2822-0000.cfg)... done.
copying scr_config(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/t186ref/BCT/tegra194-mb1-bct-scr-cbb-mini.cfg)... done.
copying scr_cold_boot_config(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/t186ref/BCT/tegra194-mb1-bct-scr-cbb-mini.cfg)... done.
copying bootrom_config(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/t186ref/BCT/tegra194-mb1-bct-reset-p2888-0000-p2822-0000.cfg)... done.
copying dev_params(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/t186ref/BCT/tegra194-br-bct-sdmmc.cfg)... done.
Existing bootloader(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/nvtboot_cpu_t194.bin) reused.
copying initrd(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/l4t_initrd.img)... done.
Making Boot image... done.
/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/tegraflash.py --chip 0x19 --key  --minratchet_config tegra194-mb1-bct-ratchet-p2888-0000-p2822-0000.cfg --cmd sign boot.img kernel
Welcome to Tegra Flash
version 1.0.0
Type ? or help for help and q or quit to exit
Use ! to execute system commands
 
[   0.0003 ] Generating signature
[   0.0032 ] tegrasign_v3.py --getmode mode.txt --key 
[   0.0033 ] Assuming zero filled SBK key : not reading 
[   0.0033 ] Generating ratchet blob
[   0.0055 ] tegrabct_v2 --chip 0x19 0 --ratchet_blob ratchet_blob.bin --minratchet tegra194-mb1-bct-ratchet-p2888-0000-p2822-0000.cfg
[   0.0069 ] FwIndex: 1, MinRatchetLevel: 0
[   0.0072 ] FwIndex: 2, MinRatchetLevel: 0
[   0.0072 ] FwIndex: 3, MinRatchetLevel: 0
[   0.0072 ] FwIndex: 4, MinRatchetLevel: 0
[   0.0072 ] FwIndex: 5, MinRatchetLevel: 0
[   0.0072 ] FwIndex: 6, MinRatchetLevel: 0
[   0.0072 ] FwIndex: 7, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 11, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 12, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 13, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 14, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 15, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 16, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 17, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 18, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 19, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 30, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 31, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 32, MinRatchetLevel: 0
[   0.0073 ] 
[   0.0074 ] header_magic: 414e4452
[   0.0099 ] tegrahost_v2 --chip 0x19 --align 1_boot.img
[   0.0109 ] 
[   0.0134 ] tegrahost_v2 --chip 0x19 0 --magicid KRNL --ratchet_blob ratchet_blob.bin --appendsigheader 1_boot.img zerosbk
[   0.0142 ] adding BCH for 1_boot.img
[   0.6320 ] 
[   0.6359 ] tegrasign_v3.py --key  --list 1_boot_sigheader.img_list.xml --pubkeyhash pub_key.key
[   0.6360 ] Assuming zero filled SBK key : not reading 
[   0.7026 ] tegrahost_v2 --chip 0x19 0 --updatesigheader 1_boot_sigheader.img.encrypt 1_boot_sigheader.img.hash zerosbk
[   1.0272 ] 
[   1.0503 ] Signed file: /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/temp_user_dir/boot_sigheader.img.encrypt
l4t_sign_image.sh: Generate header for boot_sigheader.img.encrypt
l4t_sign_image.sh: chip 0x19: add 0x27cb800 to offset  0x8 in sig file
l4t_sign_image.sh: Generate 16-byte-size-aligned base file for boot_sigheader.img.encrypt
l4t_sign_image.sh: the signed file is /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/temp_user_dir/boot_sigheader.img.encrypt
done.
Making recovery ramdisk for recovery image...
Re-generating recovery ramdisk for recovery image...
~/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/ramdisk_tmp ~/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader ~/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra
30412 blocks
_BASE_KERNEL_VERSION=4.9.253-tegra
~/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/ramdisk_tmp/lib ~/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/ramdisk_tmp ~/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader ~/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra
66117 blocks
Making Recovery image...
copying recdtbfile(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/kernel/dtb/tegra194-p2888-0001-p2822-0000.dtb.rec)... done.
20+0 records in
20+0 records out
20 bytes copied, 0.000307464 s, 65.0 kB/s
Existing sosfile(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/mb1_t194_prod.bin) reused.
Existing tegraboot(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/nvtboot_t194.bin) reused.
Existing cpu_bootloader(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/nvtboot_cpu_t194.bin) reused.
Existing mb2blfile(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/nvtboot_recovery_t194.bin) reused.
Existing mtspreboot(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/preboot_c10_prod_cr.bin) reused.
Existing mcepreboot(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/mce_c10_prod_cr.bin) reused.
Existing mtsproper(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/mts_c10_prod_cr.bin) reused.
Existing mb1file(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/mb1_t194_prod.bin) reused.
Existing bpffile(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/bpmp_t194.bin) reused.
copying bpfdtbfile(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/t186ref/tegra194-a02-bpmp-p2888-a04.dtb)... done.
Existing scefile(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/camera-rtcpu-sce.img) reused.
Existing camerafw(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/camera-rtcpu-rce.img) reused.
Existing spefile(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/spe_t194.bin) reused.
Existing wb0boot(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/warmboot_t194_prod.bin) reused.
Existing tosfile(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/tos-trusty_t194.img) reused.
Existing eksfile(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/eks.img) reused.
copying soft_fuses(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/t186ref/BCT/tegra194-mb1-soft-fuses-l4t.cfg)... done.
copying dtbfile(/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/kernel/dtb/tegra194-p2888-0001-p2822-0000.dtb)... done.
Copying nv_boot_control.conf to rootfs
/home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/tegraflash.py --chip 0x19 --key  --minratchet_config tegra194-mb1-bct-ratchet-p2888-0000-p2822-0000.cfg --cmd sign kernel_tegra194-p2888-0001-p2822-0000.dtb kernel_dtb
Welcome to Tegra Flash
version 1.0.0
Type ? or help for help and q or quit to exit
Use ! to execute system commands
 
[   0.0004 ] Generating signature
[   0.0033 ] tegrasign_v3.py --getmode mode.txt --key 
[   0.0034 ] Assuming zero filled SBK key : not reading 
[   0.0033 ] Generating ratchet blob
[   0.0060 ] tegrabct_v2 --chip 0x19 0 --ratchet_blob ratchet_blob.bin --minratchet tegra194-mb1-bct-ratchet-p2888-0000-p2822-0000.cfg
[   0.0072 ] FwIndex: 1, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 2, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 3, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 4, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 5, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 6, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 7, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 11, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 12, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 13, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 14, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 15, MinRatchetLevel: 0
[   0.0073 ] FwIndex: 16, MinRatchetLevel: 0
[   0.0074 ] FwIndex: 17, MinRatchetLevel: 0
[   0.0074 ] FwIndex: 18, MinRatchetLevel: 0
[   0.0074 ] FwIndex: 19, MinRatchetLevel: 0
[   0.0074 ] FwIndex: 30, MinRatchetLevel: 0
[   0.0074 ] FwIndex: 31, MinRatchetLevel: 0
[   0.0074 ] FwIndex: 32, MinRatchetLevel: 0
[   0.0074 ] 
[   0.0074 ] header_magic: d00dfeed
[   0.0099 ] tegrahost_v2 --chip 0x19 --align 1_kernel_tegra194-p2888-0001-p2822-0000.dtb
[   0.0107 ] 
[   0.0117 ] tegrahost_v2 --chip 0x19 0 --magicid KDTB --ratchet_blob ratchet_blob.bin --appendsigheader 1_kernel_tegra194-p2888-0001-p2822-0000.dtb zerosbk
[   0.0125 ] adding BCH for 1_kernel_tegra194-p2888-0001-p2822-0000.dtb
[   0.0170 ] 
[   0.0200 ] tegrasign_v3.py --key  --list 1_kernel_tegra194-p2888-0001-p2822-0000_sigheader.dtb_list.xml --pubkeyhash pub_key.key
[   0.0200 ] Assuming zero filled SBK key : not reading 
[   0.0252 ] tegrahost_v2 --chip 0x19 0 --updatesigheader 1_kernel_tegra194-p2888-0001-p2822-0000_sigheader.dtb.encrypt 1_kernel_tegra194-p2888-0001-p2822-0000_sigheader.dtb.hash zerosbk
[   0.0285 ] 
[   0.0288 ] Signed file: /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/temp_user_dir/kernel_tegra194-p2888-0001-p2822-0000_sigheader.dtb.encrypt
l4t_sign_image.sh: Generate header for kernel_tegra194-p2888-0001-p2822-0000_sigheader.dtb.encrypt
l4t_sign_image.sh: chip 0x19: add 0x45651 to offset  0x8 in sig file
l4t_sign_image.sh: Generate 16-byte-size-aligned base file for kernel_tegra194-p2888-0001-p2822-0000_sigheader.dtb.encrypt
l4t_sign_image.sh: the signed file is /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/temp_user_dir/kernel_tegra194-p2888-0001-p2822-0000_sigheader.dtb.encrypt
done.
	populating kernel to rootfs... done.
	populating initrd to rootfs... done.
	populating kernel_tegra194-p2888-0001-p2822-0000.dtb to rootfs... done.
Making system.img... 
	populating rootfs from /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/rootfs ... 	populating /boot/extlinux/extlinux.conf ... done.
	generating sig file of Image ... /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/tegraflash.py --chip 0x19 --key  --minratchet_config tegra194-mb1-bct-ratchet-p2888-0000-p2822-0000.cfg --cmd sign ./boot/Image kernel
Welcome to Tegra Flash
version 1.0.0
Type ? or help for help and q or quit to exit
Use ! to execute system commands
 
[   0.0005 ] Generating signature
[   0.0033 ] tegrasign_v3.py --getmode mode.txt --key 
[   0.0034 ] Assuming zero filled SBK key : not reading 
[   0.0033 ] Generating ratchet blob
[   0.0059 ] tegrabct_v2 --chip 0x19 0 --ratchet_blob ratchet_blob.bin --minratchet tegra194-mb1-bct-ratchet-p2888-0000-p2822-0000.cfg
[   0.0096 ] FwIndex: 1, MinRatchetLevel: 0
[   0.0121 ] FwIndex: 2, MinRatchetLevel: 0
[   0.0121 ] FwIndex: 3, MinRatchetLevel: 0
[   0.0121 ] FwIndex: 4, MinRatchetLevel: 0
[   0.0121 ] FwIndex: 5, MinRatchetLevel: 0
[   0.0121 ] FwIndex: 6, MinRatchetLevel: 0
[   0.0121 ] FwIndex: 7, MinRatchetLevel: 0
[   0.0121 ] FwIndex: 11, MinRatchetLevel: 0
[   0.0122 ] FwIndex: 12, MinRatchetLevel: 0
[   0.0122 ] FwIndex: 13, MinRatchetLevel: 0
[   0.0122 ] FwIndex: 14, MinRatchetLevel: 0
[   0.0122 ] FwIndex: 15, MinRatchetLevel: 0
[   0.0122 ] FwIndex: 16, MinRatchetLevel: 0
[   0.0122 ] FwIndex: 17, MinRatchetLevel: 0
[   0.0122 ] FwIndex: 18, MinRatchetLevel: 0
[   0.0122 ] FwIndex: 19, MinRatchetLevel: 0
[   0.0122 ] FwIndex: 30, MinRatchetLevel: 0
[   0.0122 ] FwIndex: 31, MinRatchetLevel: 0
[   0.0122 ] FwIndex: 32, MinRatchetLevel: 0
[   0.0122 ] 
[   0.0131 ] header_magic: 405614
[   0.0192 ] tegrahost_v2 --chip 0x19 --align 1_Image
[   0.0249 ] 
[   0.0310 ] tegrahost_v2 --chip 0x19 0 --magicid KRNL --ratchet_blob ratchet_blob.bin --appendsigheader 1_Image zerosbk
[   0.0348 ] adding BCH for 1_Image
[   0.5857 ] 
[   0.5899 ] tegrasign_v3.py --key  --list 1_Image_sigheader_list.xml --pubkeyhash pub_key.key
[   0.5899 ] Assuming zero filled SBK key : not reading 
[   0.6491 ] tegrahost_v2 --chip 0x19 0 --updatesigheader 1_Image_sigheader.encrypt 1_Image_sigheader.hash zerosbk
[   0.9170 ] 
[   0.9381 ] Signed file: /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/mnt/Image_sigheader.encrypt
l4t_sign_image.sh: Generate header for Image_sigheader.encrypt
l4t_sign_image.sh: chip 0x19: add 0x20e3008 to offset  0x8 in sig file
l4t_sign_image.sh: Generate 16-byte-size-aligned base file for Image_sigheader.encrypt
l4t_sign_image.sh: the sign header is saved at ./boot/Image.sig
done.
done.
	generating sig file of kernel_tegra194-p2888-0001-p2822-0000.dtb ... /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/tegraflash.py --chip 0x19 --key  --minratchet_config tegra194-mb1-bct-ratchet-p2888-0000-p2822-0000.cfg --cmd sign ./boot/dtb/kernel_tegra194-p2888-0001-p2822-0000.dtb kernel_dtb
Welcome to Tegra Flash
version 1.0.0
Type ? or help for help and q or quit to exit
Use ! to execute system commands
 
[   0.0004 ] Generating signature
[   0.0033 ] tegrasign_v3.py --getmode mode.txt --key 
[   0.0034 ] Assuming zero filled SBK key : not reading 
[   0.0033 ] Generating ratchet blob
[   0.0061 ] tegrabct_v2 --chip 0x19 0 --ratchet_blob ratchet_blob.bin --minratchet tegra194-mb1-bct-ratchet-p2888-0000-p2822-0000.cfg
[   0.0070 ] FwIndex: 1, MinRatchetLevel: 0
[   0.0071 ] FwIndex: 2, MinRatchetLevel: 0
[   0.0071 ] FwIndex: 3, MinRatchetLevel: 0
[   0.0071 ] FwIndex: 4, MinRatchetLevel: 0
[   0.0071 ] FwIndex: 5, MinRatchetLevel: 0
[   0.0071 ] FwIndex: 6, MinRatchetLevel: 0
[   0.0071 ] FwIndex: 7, MinRatchetLevel: 0
[   0.0071 ] FwIndex: 11, MinRatchetLevel: 0
[   0.0071 ] FwIndex: 12, MinRatchetLevel: 0
[   0.0071 ] FwIndex: 13, MinRatchetLevel: 0
[   0.0071 ] FwIndex: 14, MinRatchetLevel: 0
[   0.0071 ] FwIndex: 15, MinRatchetLevel: 0
[   0.0071 ] FwIndex: 16, MinRatchetLevel: 0
[   0.0071 ] FwIndex: 17, MinRatchetLevel: 0
[   0.0071 ] FwIndex: 18, MinRatchetLevel: 0
[   0.0071 ] FwIndex: 19, MinRatchetLevel: 0
[   0.0071 ] FwIndex: 30, MinRatchetLevel: 0
[   0.0071 ] FwIndex: 31, MinRatchetLevel: 0
[   0.0071 ] FwIndex: 32, MinRatchetLevel: 0
[   0.0071 ] 
[   0.0076 ] header_magic: d00dfeed
[   0.0086 ] tegrahost_v2 --chip 0x19 --align 1_kernel_tegra194-p2888-0001-p2822-0000.dtb
[   0.0101 ] 
[   0.0123 ] tegrahost_v2 --chip 0x19 0 --magicid KDTB --ratchet_blob ratchet_blob.bin --appendsigheader 1_kernel_tegra194-p2888-0001-p2822-0000.dtb zerosbk
[   0.0132 ] adding BCH for 1_kernel_tegra194-p2888-0001-p2822-0000.dtb
[   0.0186 ] 
[   0.0217 ] tegrasign_v3.py --key  --list 1_kernel_tegra194-p2888-0001-p2822-0000_sigheader.dtb_list.xml --pubkeyhash pub_key.key
[   0.0218 ] Assuming zero filled SBK key : not reading 
[   0.0271 ] tegrahost_v2 --chip 0x19 0 --updatesigheader 1_kernel_tegra194-p2888-0001-p2822-0000_sigheader.dtb.encrypt 1_kernel_tegra194-p2888-0001-p2822-0000_sigheader.dtb.hash zerosbk
[   0.0303 ] 
[   0.0307 ] Signed file: /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/mnt/kernel_tegra194-p2888-0001-p2822-0000_sigheader.dtb.encrypt
l4t_sign_image.sh: Generate header for kernel_tegra194-p2888-0001-p2822-0000_sigheader.dtb.encrypt
l4t_sign_image.sh: chip 0x19: add 0x45651 to offset  0x8 in sig file
l4t_sign_image.sh: Generate 16-byte-size-aligned base file for kernel_tegra194-p2888-0001-p2822-0000_sigheader.dtb.encrypt
l4t_sign_image.sh: the sign header is saved at ./boot/dtb/kernel_tegra194-p2888-0001-p2822-0000.dtb.sig
done.
done.
	generating sig file of initrd ... /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/tegraflash.py --chip 0x19 --key  --cmd sign ./boot/initrd data
Welcome to Tegra Flash
version 1.0.0
Type ? or help for help and q or quit to exit
Use ! to execute system commands
 
[   0.0004 ] Generating signature
[   0.0029 ] tegrasign_v3.py --getmode mode.txt --key 
[   0.0029 ] Assuming zero filled SBK key : not reading 
[   0.0032 ] header_magic: 1f8b0800
[   0.0055 ] tegrahost_v2 --chip 0x19 --align 1_initrd
[   0.0066 ] 
[   0.0088 ] tegrahost_v2 --chip 0x19 0 --magicid DATA --appendsigheader 1_initrd zerosbk
[   0.0097 ] adding BCH for 1_initrd
[   0.1219 ] 
[   0.1254 ] tegrasign_v3.py --key  --list 1_initrd_sigheader_list.xml --pubkeyhash pub_key.key
[   0.1254 ] Assuming zero filled SBK key : not reading 
[   0.1411 ] tegrahost_v2 --chip 0x19 0 --updatesigheader 1_initrd_sigheader.encrypt 1_initrd_sigheader.hash zerosbk
[   0.1990 ] 
[   0.2033 ] Signed file: /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/mnt/initrd_sigheader.encrypt
l4t_sign_image.sh: Generate header for initrd_sigheader.encrypt
l4t_sign_image.sh: chip 0x19: add 0x6e72c8 to offset  0x8 in sig file
l4t_sign_image.sh: Generate 16-byte-size-aligned base file for initrd_sigheader.encrypt
l4t_sign_image.sh: the sign header is saved at ./boot/initrd.sig
done.
done.
	generating sig file of extlinux.conf ... /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/tegraflash.py --chip 0x19 --key  --cmd sign ./boot/extlinux/extlinux.conf data
Welcome to Tegra Flash
version 1.0.0
Type ? or help for help and q or quit to exit
Use ! to execute system commands
 
[   0.0004 ] Generating signature
[   0.0032 ] tegrasign_v3.py --getmode mode.txt --key 
[   0.0032 ] Assuming zero filled SBK key : not reading 
[   0.0032 ] header_magic: 54494d45
[   0.0054 ] tegrahost_v2 --chip 0x19 --align 1_extlinux.conf
[   0.0063 ] 
[   0.0086 ] tegrahost_v2 --chip 0x19 0 --magicid DATA --appendsigheader 1_extlinux.conf zerosbk
[   0.0096 ] adding BCH for 1_extlinux.conf
[   0.0098 ] 
[   0.0124 ] tegrasign_v3.py --key  --list 1_extlinux_sigheader.conf_list.xml --pubkeyhash pub_key.key
[   0.0125 ] Assuming zero filled SBK key : not reading 
[   0.0174 ] tegrahost_v2 --chip 0x19 0 --updatesigheader 1_extlinux_sigheader.conf.encrypt 1_extlinux_sigheader.conf.hash zerosbk
[   0.0184 ] 
[   0.0186 ] Signed file: /home/rw9535/nvidia/nvidia_sdk/JetPack_4.6_Linux_JETSON_AGX_XAVIER_TARGETS/Linux_for_Tegra/bootloader/mnt/extlinux_sigheader.conf.encrypt
l4t_sign_image.sh: Generate header for extlinux_sigheader.conf.encrypt
l4t_sign_image.sh: chip 0x19: add 0x360 to offset  0x8 in sig file
l4t_sign_image.sh: Generate 16-byte-size-aligned base file for extlinux_sigheader.conf.encrypt
l4t_sign_image.sh: the sign header is saved at ./boot/extlinux/extlinux.conf.sig
done.
done.
	Sync'ing system.img ... done.
	Converting RAW image to Sparse image... ./flash.sh: line 512: 13575 Killed                  ./mksparse ${blblksizeoption} --fillpattern=${__fillpat} ${__localsysfile}.raw ${__localsysfile}
failed.

It keeps failing at the point where it is creating a sparse file from the raw rootfs partition. When finished and failed, do you see file “Linux_for_Tegra/bootloader/system.img.raw”? If so, then perhaps you could see what happens when you manually run mksparse on that. Example from “Linux_for_Tegra/bootloader”:
sudo ./mksparse -v --fillpattern=0 system.img.raw system.img

If this works, then try flashing again. If not, then post the error. If the error is long, then you could log it like this:
sudo ./mksparse -v --fillpattern=0 system.img.raw system.img 2>&1 | tee log_mksparse.txt

Thanks very much for your suggestions.

The first time I ran the command you specified, I saw an output like this:

---- Raw to Sparse Image Converter v1.0 ----------------------------
  0: RAW:     4288512(   1047 blks) ==>          28:4288524
  1: SKP:       57344(     14 blks) ==>     4288552:12
  2: RAW:     2981888(    728 blks) ==>     4288564:2981900
  3: SKP:    30572544(   7464 blks) ==>     7270464:12
  4: RAW:     6332416(   1546 blks) ==>     7270476:6332428
  5: SKP:    89985024(  21969 blks) ==>    13602904:12
  6: RAW:       20480(      5 blks) ==>    13602916:20492
  7: SKP:     4194304(   1024 blks) ==>    13623408:12
  8: RAW:       94208(     23 blks) ==>    13623420:94220
  9: SKP:        4096(      1 blks) ==>    13717640:12
...
744: RAW:    14659584(   3579 blks) ==>   533029628:14659596
745: SKP:     2117632(    517 blks) ==>   547689224:12
Killed

I noticed that the system.img file existed, though it was quite small. I deleted the system.img file and ran the command again. This time it just shows:

---- Raw to Sparse Image Converter v1.0 ----------------------------
Killed

The exit code is 137 (“killed”).
The system.img file has been recreated and is 262,184 bytes long (system.img.raw is 30.1GB).
I have tried running the command repeatedly without deleting the system.img file, and each time, system.img gets smaller.
I still have over 100GB free space on my machine so I don’t think that’s the problem.

Can I somehow skip this stage - can I flash the raw file for example?

Thanks again for your help.

UPDATE: I think this may be our corporate anti-malware preventing mksparse from running.
Thanks a lot for your help - this enabled me to understand what was happening.

Yes, “killed” means another application (or end user) killed the process. One example which is common is if limits are set and you are reaching those limits (either RAM or disk space would be possible limits). The “quota” system is one way to do this, so you might check if any quota is being enforced. Or as you mentioned perhaps your company has something similar in custom anti-malware.