Xubuntu 20.04 Focal Fossa L4T R32.3.1 - Custom Image for the Jetson Nano

@neduljee what wifi adapter are you using? could you just use a regular usb wifi adapter for now and setup the kvm with usb passthrough.

I was able to edit the file using a second SD card with jetpack installed, and accessing it by launching jetpack and using USB SD card reader, then accessing the files via jetpack. This, therefore, didn’t require a second Nano, but just the USB card reader and another sd card

I got the right dtb file in the /boot directory by either :
$ cat /sys/firmware/devicetree/base/compatible or $ fdtget /boot/dtb/*.dtb / compatible

cd into your /boot/extlinux/ in your sd card with XUBUNTU patched

save a copy of the original file:
$ cp extlinux.conf extlinux.conf.orig

Then edited the /boot/extlinux/extlinux.conf file in my sd card with XUBUNTU to be the following:
$ sudo gedit extlinux.conf

Then adding the line FDT /boot/tegra210-p3448-0000-p3449-0000-b00.dtb to the primary Label. you can get your dtb file with $ fdtget /boot/dtb/*.dtb / compatible and replace mine to FDT /boot/“Your own file name here.dtb”

to make

LABEL primary
MENU LABEL primary kernel
LINUX /boot/Image
INITRD /boot/initrd
APPEND ${cbootargs}
FDT /boot/tegra210-p3448-0000-p3449-0000-b00.dtb

Then I commented the KVM label part in the /boot/extlinux/extlinux.conf, as in the original jetpack.
so:
#LABEL kvm
#MENU LABEL kvm kernel
#LINUX /boot/Image_kvm
#INITRD /boot/initrd
#APPEND ${cbootargs}
#FDT /boot/tegra210-p3448-0000-p3449-0000-a02-kvm.dtb

Then saved, plugged in the SD card with Xubuntu and restarted.

This let me get through with the first, second, third and I guess therefore more boots without an issue.
Et Voila, Every boot ever since worked splendidly. Thanks much @mr.chrismitchells. Shout out for the amazing work you’ve done.
I didn’t test it with the KVM part uncommented, because I didn’t need it and didn’t really understand what it served, but If you need it, then try it out.

Good Luck.

Yes. goto GitHub - JetsonHacksNano/rootOnUSB: Set rootfs to be on a USB drive and follow those instructions.
One modification to Chris’s procedure is with regards to an editing /boot/extlinux/extlinux.conf. Don’t change to kvm otherwise the usb SSD/HHD wouldn’t become the root filesystem.

Could you please also upload kernel compiled with OC? GitHub - mrcmunir/jetson_nano_overclock: Kernel for nvidia jetson nano with some changes in dvfs for enable higher speed (CPU 2,0ghz+ and GPU 1,0ghz) This one don’t work…

If anyone has managed to get CUDA installed, please let me know how you did it

Nvidia has not seemed to release CUDA for 20.04 on arm64?

1 Like

So KVM does not work in B01 version of the board ?

@rreddy78

Here is the dtb file required for KVM support on the b01 board.

You need to modify the extlinux config file to use the KVM kernel supplied with the image as well as the dtb included in the following link.

If you don’t have access to a linux machine to modify this file prior to booting the image on your Nano there are instructions for doing it using the image Nvidia provides.

B01 KVM DTB: https://easyupload.io/m/dl6rb6

Where can I download Win 10 for ARM ? Is it from here ?
https://www.microsoft.com/en-us/software-download/windowsinsiderpreviewARM64 ?

or like this ?

How to Install Windows 10 for ARM in QEMU ?

Both kernels are working on B01. Thanks a lot. But the Firefox is having problems even after upgrade of all packages. Also disappointed that there is no Suspend option

Also I am a bit confused with various replies seen. Is it still necessary to compile qemu (with options --enable-opengl --enable-virglrenderer --enable-sdl .) from source for running AOSP and Win10 ARM ?

I see that this step “install libvirglrenderer1 and libvirglrenderer-dev before compiling qemu.” is needed. Any other packages that need to be preinstalled ?

I’ve wrote the image on the sd card and I tried to boot it. It does not work. the error is : unable to read partition table.

If you are using a HW revision other than a02, you would have to modify the extlinux.conf file in the /boot/extlinux directory.

The modification must be done with sudo on another linux system for the first time. Thereafter you can edit it after system is running normally.

Also you would need a modified DTB file for the KVM kernel for which a link was provided by @mr.chrismitchells . This DTB must be added to the /boot directory.

Here is my extlinux.conf file for booting the kvm kernel. You can switch between primary and kvm by commenting/uncommenting (as recommended in this thread)

TIMEOUT 30
DEFAULT kvm

MENU TITLE L4T boot options

#LABEL primary
#MENU LABEL primary kernel
#'LINUX /boot/Image
#INITRD /boot/initrd
#APPEND ${cbootargs}
#FDT /boot/tegra210-p3448-0000-p3449-0000-b00.dtb

LABEL kvm
MENU LABEL kvm kernel
LINUX /boot/Image_kvm
FDT /boot/tegra210-p3448-0000-p3449-0000-b00-kvm.dtb
INITRD /boot/initrd
APPEND ${cbootargs}

I’ve bought the jetson nano B01. I’ve got the two files suggested from here :

https://easyupload.io/m/dl6rb6

and I’ve copied them on the /boot folder of the xubuntu image that I’ve got from here :

https://github.com/Discombobulated88/Xubuntu-20.04-L4T-32.3.1/releases/download/v1.0/Xubuntu-20.04-l4t-r32.3.1.tar.tbz2

this is how I have edited the extlinux.conf file :

unfortunately it won’t boot. it freezes on the nvidia logo. what could be wrong ?

Hmmm. Sorry I do not know what the problem could be.
Maybe you can try the primary kernel first. If its working maybe comment out the primary and set DEFAULT kvm like I did.

Also as suggested in this thread you can use the 5V power instead of USB to power when starting for first time

I’ve just tried the kernel without kvm and also does not work. anyway what happens is different than before. now it stucks on the nvidia logo for some minutes and then the monitor turns off for a while and then again it comes back and stucks again on the nvidia logo. it goes in a forever loop. what method do u use to flash the image on the sd card ? which sd card brand do u use ? (I’m using the 5V 4A power of this : (GeeekPi DC 5V 4A power source with EU&UK&US for Raspberry Pi X820/X825 SATA Expansion Board/ X700 ups/ X720/ X735 Power Management Board/Jetson Nano/X822/X852/T300/T100/T200/X750)

I used balenaEtcher - Flash OS images to SD cards & USB drives on a Windows machine for flashing.
The sdcard is a 64GB SanDisk.

ok. after several tries,I found the configuration that works for me. is this :

DEFAULT kvm

LABEL kvm
menu label kvm kernel
linux /boot/Image_kvm
INITRD /boot/initrd
append $(cbootargs)

in xubuntu I can see that kvm is working giving this command :

kvm-ok

it says :

INFO /dev/kvm exists
KVM acceleration can be used

now,what should I do to boot windows 10 ? can u write here the full qemu + kvm command that u use ? thanks.

Running Win10 with qemu+kvm is something I am trying to figure out. Please see the links I posted. The “winaero” link provies info on running on QEMU on Windows without kvm. I am trying to modify it for linux.

I have had not much success. KVM does not work for me at all. Without kvm I am able to boot till a point where I get a BSOD with ACPI BIOS error. Its the same whether I build qemu from source or use from repository.

Another link I found might be useful:
Running Windows 10 for ARM64 in a QEMU virtual machine | Technical Blog

So now I am able to run Win10 with QEMU+KVM. The instructions in the link:
Running Windows 10 for ARM64 in a QEMU virtual machine | Technical Blog
is very helpful.

Used QEMU from repo, not one built from source.

qemu-system-aarch64 --version
QEMU emulator version 4.2.1 (Debian 1:4.2-3ubuntu6.12)

Have to use a Windows system to download the Win10 ISO using https://uup.rg-adguard.net/ .
I chose version 1903 final release.
My simplified install command was:

rreddy78@jetson-nano:~/qemu/vm_test$ qemu-system-aarch64 -M virt-2.12 -enable-kvm -cpu host -smp 2 -m 2048
-device qemu-xhci -device usb-kbd -device usb-mouse
-drive file=disk.qcow2,if=virtio \

-nic user,model=virtio
-device usb-storage,drive=install
-device usb-storage,drive=drivers
-drive file=“18362.1198.201030-1156.19H1_RELEASE_SVC_PROD1_CLIENTPRO_OEMRET_A64FRE_EN-US.ISO”,if=none,id=install,media=cdrom,readonly=on
-drive file=“virtio-win-0.1.185.iso”,if=none,media=cdrom,readonly=on,id=drivers
-bios QEMU_EFI.fd -device ramfb

After installation, for running:

rreddy78@jetson-nano:~/qemu/vm_test$ qemu-system-aarch64 -M virt-2.12 -enable-kvm -cpu host -smp 2 -m 2048 -device qemu-xhci -device usb-kbd -device usb-mouse -drive file=disk.qcow2,if=virtio -nic user,model=virtio -device usb-storage,drive=drivers -drive file=“virtio-win-0.1.185.iso”,if=none,media=cdrom,readonly=on,id=drivers -bios QEMU_EFI.fd -device ramfb

I tried to install network virtio drivers, but system crashed.

The performance is good considering that its running off an sdcard using just 2 cores no drivers for graphics. Whenever MS releases Win10 for jetson nano it would perform quite well.

1 Like

qemu-system-aarch64: -nic: invalid option. I have removed the argument “-nic user,model=virtio” and I’ve got another error :

root@ziomario-desktop:# ./startvm.sh
qemu-system-aarch64: Initialization of device arm_gic failed: KVM with user space irqchip only works when the host kernel supports KVM_CAP_ARM_USER_IRQ

Please see above in this thread. That error means the KVM kernel was not loaded.

We need the KVM DTB file for KVM kernel. I see your extconf file having no specific KVM DTB file. So might be its loading the default DTB file ? I am not sure.