Problem flashing to R21.2

Hi everyone! I seems to have a problem and I cannot understand what’s wrong with it. Whenever I try to flash it by doing:

/Linux_for_Tegra$ sudo -S 11GiB jetson-tk1 mmcblk0p1

This always leads to this error:

Making system.img…
mapping system.img to loop device failed.

Any idea what I did wrong?

I flashed mine over the weekend from Ubuntu laptop with jetson pack to R21.3 without issues. Try downloading jetpack and install with that.

There’s something about failing loopback device in this old thread:

And if you are flashing anyway, I recommend flashing the latest release (21r3 currently). URL in the above post.

Ok thanks guys! I will try it now. Let you guys know the result again.

Hmm it’s still showing the same problem even in r21.3…

$sudo tar xpf Tegra124_Linux_R21.3.0_armhf.tbz2

$cd Linux_for_Tegra/rootfs
$sudo tar xpf …/…/Tegra_Linux_Sample-Root-Filesystem_R21.3.0_armhf.tbz2

$cd …/
$sudo ./

Fourth: Check for Nvidia Corp.

Fifth: It is there, so flash.
$sudo ./ -S 14580MiB jetson-tk1 mmcblk0p1

The same error appears,
Making system.img…
mapping system.img to loop device failed.

What is your host Linux distro?

In a terminal,

ls /dev/loop*

There should be a device called ‘loop0’, and then one called ‘loop1’ (possibly more). In your case, the script is trying to use the loop0, but it is already taken, so when the script tries to map the ‘system.img’ to it, it fails. So, we need to tell the script to use loop1 (the next loop device) which should not already be in use.

Open in a text editor. There’s a line where it defines a variable to a text string containing the name of the loop device to use. It should be set to ‘loop0’. Change it to ‘loop1’, to tell the script to use the next loop device which should not be taken. (I’m not sure what the line number is, but I believe it’s the only line in the whole script that is hard-coded to use ‘loop0’.)

Maybe in the future, this script could be changed so that the loop-device is provided via a command-line argument, and is not hard-coded to ‘loop0’.

Good luck!

Thanks a lot guys! I think it is something with the host problem. Was using 12.04 LTS and kept having this problem. Once I upgraded to 14.04.2 LTS, this problem instantly disappears.

Shouldn’t be loop issue. I think they already fixed that.

I want to confirm that this solved my loopback error on a live persistent USB version of Ubuntu 16.04 as the host, with a TK1 as the dev board. I have run into some issues with installing visionworks, but that’s an unrelated issue.

“loop0” is on line 450 of for the curious, and changing the 0 to a 1 was all that was needed to get it working.

@cn04, your advice solved my problem. I had the exact same problem as @MechanicalMan