Orin nano installation fails; chroot: failed to run command ‘dpkg’: Exec format error

Hi,

I had the same horror while using WSL2. First of all; NVidia should support WSL2 because they created a dedicated info page on it and I believe the latest sdkmanager was build to support WSL2.

I tried to debug what was going on by manually running all the scripts and found out that chroot was not working correctly; thus issues with qemu.

On my WSL I installed the qemu-system full emulation binaries packages. However, they did not pop up in binfmt_misc (as should be when running ls /proc/sys/fs/binfmt_misc/ ).

I tried the solution from H-Jay but got stuck in his same error. I then found that update-binfmts is designed to import the correct binary formats.

While these ascii formats showed up in my /usr/share/binfmts, such as qemu-aarch64, qemu-arm and qemu-armeb, I used the update-binfmts tool to properly import these formats:

sudo update-binfmts --import qemu-aarch64
sudo update-binfmts --import qemu-arm
sudo update-binfmts --import qemu-armeb

I don’t know if the last two are really needed (I suppose not) but after this action the issue mentioned by H-Jay is solved and chroot works as a charm :)
Hope this helps others too.

Regards
Henk

3 Likes