Occurred kernel panic in tx2 board after flashing

Hi

I have a problem. I’m flashing binary using flash.sh script for the first time. below command
sudo ./flash.sh jetson-tx2 mmcblk0p1

And I could see “The target t186ref has been flashed successfully” log
But my tx2 board has kernel panic with follows logs.
What is problems. i flashed binary according to your quick start guide.
Plz tell me the reasons.

Thanks,
doohan93

[ 01:32:16 ] L4T initrd starts from here…
[ 01:32:16 ] L4T-INITRD Build DATE: Sat Jan 1 01:32:16 UTC 2000
[ 01:32:16 ] Root device found: mmcblk0p1
Rootdevice found: /dev/mmcblk0p1
[ 5.733913] EXT4-fs (mmcblk0p1): mounted filesystem with ordered data mode. O pts: (null)
[ 01:32:16 ] Rootfs mounted over mmcblk0p1
mount: mount point /mnt/proc does not exist
mount: mount point /mnt/sys does not exist
mount: mount point /mnt/dev does not exist
cp: cannot create regular file ‘etc/resolv.conf’: No such file or directory
[ 01:32:16 ] Switching from initrd to actual rootfs
chroot: failed to run command ‘/sbin/init’: No such file or directory
[ 5.780227] Kernel panic - not syncing: Attempted to kill init! exitcode=0x00 007f00
[ 5.780227]
[ 5.791874] CPU3: stopping
[ 5.795412] CPU: 3 PID: 0 Comm: swapper/3 Not tainted 4.4.15-tegra #1
[ 5.802686] Hardware name: quill (DT)
[ 5.807160] Call trace:
[ 5.810405] [] dump_backtrace+0x0/0x100
[ 5.816620] [] show_stack+0x14/0x1c
[ 5.822501] [] dump_stack+0x90/0xb4
[ 5.828372] [] handle_IPI+0x300/0x30c
[ 5.834394] [] gic_handle_irq+0x9c/0xb4
[ 5.840574] [] el1_irq+0x68/0xd8
[ 5.846142] [] cpuidle_enter+0x18/0x20
[ 5.852227] [] call_cpuidle+0x28/0x50
[ 5.858200] [] cpu_startup_entry+0x17c/0x340
[ 5.864772] [] secondary_start_kernel+0x130/0x168
[ 5.871766] [<000000008008192c>] 0x8008192c
[ 5.876650] CPU5: stopping
[ 5.880037] CPU: 5 PID: 0 Comm: swapper/5 Not tainted 4.4.15-tegra #1
[ 5.887158] Hardware name: quill (DT)
[ 5.891479] Call trace:
[ 5.894555] [] dump_backtrace+0x0/0x100
[ 5.900584] [] show_stack+0x14/0x1c
[ 5.906241] [] dump_stack+0x90/0xb4
[ 5.911867] [] handle_IPI+0x300/0x30c
[ 5.917644] [] gic_handle_irq+0x9c/0xb4
[ 5.923605] [] el1_irq+0x68/0xd8
[ 5.928962] [] cpuidle_enter+0x18/0x20
[ 5.934831] [] call_cpuidle+0x28/0x50
[ 5.940595] [] cpu_startup_entry+0x17c/0x340
[ 5.946972] [] secondary_start_kernel+0x130/0x168
[ 5.953779] [<000000008008192c>] 0x8008192c
[ 5.958501] CPU0: stopping
[ 5.961755] CPU: 0 PID: 0 Comm: swapper/0 Not tainted 4.4.15-tegra #1
[ 5.968770] Hardware name: quill (DT)
[ 5.973007] Call trace:
[ 5.976024] [] dump_backtrace+0x0/0x100
[ 5.982014] [] show_stack+0x14/0x1c
[ 5.987656] [] dump_stack+0x90/0xb4
[ 5.993288] [] handle_IPI+0x300/0x30c
[ 5.999089] [] gic_handle_irq+0x9c/0xb4
[ 6.005053] [] el1_irq+0x68/0xd8
[ 6.010407] [] cpuidle_enter+0x18/0x20
[ 6.016272] [] call_cpuidle+0x28/0x50
[ 6.022036] [] cpu_startup_entry+0x17c/0x340
[ 6.028416] [] rest_init+0x84/0x8c
[ 6.033915] [] start_kernel+0x39c/0x3b0
[ 6.039845] [<0000000080a63000>] 0x80a63000
[ 6.044574] CPU2: stopping
[ 6.047668] CPU: 2 PID: 0 Comm: swapper/2 Not tainted 4.4.15-tegra #1
[ 6.054463] Hardware name: quill (DT)
[ 6.058484] Call trace:
[ 6.061296] [] dump_backtrace+0x0/0x100
[ 6.067062] [] show_stack+0x14/0x1c
[ 6.072478] [] dump_stack+0x90/0xb4
[ 6.077885] [] handle_IPI+0x300/0x30c
[ 6.083463] [] gic_handle_irq+0x9c/0xb4
[ 6.089211] [] el1_irq+0x68/0xd8
[ 6.094343] [] cpuidle_enter+0x18/0x20
[ 6.099991] [] call_cpuidle+0x28/0x50
[ 6.105548] [] cpu_startup_entry+0x17c/0x340
[ 6.111714] [] secondary_start_kernel+0x130/0x168
[ 6.118314] [<000000008008192c>] 0x8008192c
[ 6.122837] CPU1: stopping
[ 6.125902] CPU: 1 PID: 101 Comm: kworker/u12:3 Not tainted 4.4.15-tegra #1
[ 6.133221] Hardware name: quill (DT)
[ 6.137246] Workqueue: kmmcd mmc_rescan
[ 6.141453] Call trace:
[ 6.144260] [] dump_backtrace+0x0/0x100
[ 6.150028] [] show_stack+0x14/0x1c
[ 6.155448] [] dump_stack+0x90/0xb4
[ 6.160857] [] handle_IPI+0x300/0x30c
[ 6.166435] [] gic_handle_irq+0x9c/0xb4
[ 6.172193] [] el1_irq+0x68/0xd8
[ 6.177332] [] irq_exit+0x84/0xdc
[ 6.182552] [] __handle_domain_irq+0x6c/0xb4
[ 6.188728] [] gic_handle_irq+0x5c/0xb4
[ 6.194460] [] el1_irq+0x68/0xd8
[ 6.199585] [] sdhci_execute_tuning+0x33c/0x7bc
[ 6.206021] [] mmc_execute_tuning+0x40/0xb0
[ 6.212115] [] mmc_sdio_init_card+0x740/0x9e0
[ 6.218383] [] mmc_attach_sdio+0xa0/0x358
[ 6.224308] [] mmc_rescan+0x284/0x2f4
[ 6.229881] [] process_one_work+0x154/0x434
[ 6.235978] [] worker_thread+0x134/0x40c
[ 6.241812] [] kthread+0xe0/0xf4
[ 6.246949] [] ret_from_fork+0x10/0x40
[ 6.256798] Rebooting in 5 seconds…

Duplicate thread. Answer at:
https://devtalk.nvidia.com/default/topic/1019386/jetson-tx2/occurred-kernel-panic-after-flashing/

This is the problem. The question now is: why does the system not find init on the root file system?
What commands are you using to flash? Are you sure the full file system has been flashed correctly?

See:
https://devtalk.nvidia.com/default/topic/1019386/jetson-tx2/occurred-kernel-panic-after-flashing/

If a host does not have enough space to create the system.img.raw, then flash succeeds with a truncated file system and you won’t see any obvious error message during the flash. It is somewhat random where the truncation will occur.