We recently acquired a NVIDIA Jetson nano developer's kit. It's a great, low power, single board computer with plenty of CPU and GPU performance. The default NVIDIA image is based on Ubuntu 18.04 which is not our favorite distribution. At GGLABS all our machines run debian and we started hacking at the nano to make fit our standards.
- A Jetson nano
- A SD card of at least 4GB
- A debian host system with a SD card reader
Download and uncompress the files on the host system
Download the Official NVIDIA Jetson driver package
Install qemu-debootstrap (as root)
apt-get install binfmt-support qemu qemu-user-static debootstrap
Unpack the NVIDIA files
tar xvjf l4t-jetson-driver-package-32-1-jetson-nano_BSP.tar.bz2
Make a initial image
./create-jetson-nano-sd-card-image.sh -o debian-nano.img -s 3G -r 200
Flash the preliminary image to the SD card
dd if=debian-nano.img of=/dev/sdX bs=1M status=progress oflag=sync
Run parted or gparted on the SD card. It will complain about the partition table not using the entire disk size. Allow parted to fix the issue. Then you can adjust the size of partition 1 (the root partition). You can also add more partition for home or other mount points. The important part is not to change or move any of the pre-existing partitions (except 1). Then format partition 1.
mkfs -t ext4 /dev/sdX1
Create the debian filesystem
qemu-debootstrap --arch=arm64 stretch rootfs
sed s/root:x:/root::/g rootfs/etc/passwd >rootfs/etc/passwd.tmp
mv rootfs/etc/passwd.tmp rootfs/etc/passwd
sed s/root:.*/root::::/g rootfs/etc/shadow >rootfs/etc/shadow.tmp
mv rootfs/etc/shadow.tmp rootfs/etc/shadow
echo "nano" > rootfs/etc/hostname
optionally clean up some of the unnecessary things installed by the apply_binaries script (this is currently a work in progress)
rm -rf rootfs/lib/firmware/brcm* rootfs/lib/firmware/bcm* rootfs/lib/firmware/nv-BT-Version
Create a tar file for the base debian filesystem
tar cvf ../debian-root.tar .
mount the SD card root and uncompress the root filesystem
mount /dev/sdX /mnt
tar xvf debian-root.tar -C /mnt/
Login as root with no password. Set the root password, add user(s) as necessary, configure the network and install the desired packages to complete the install.
The Xorg driver for the integrated GPU is not installed correctly. 2D acceleration is fine but OpenGL applications fail to start.
In some configuration software reboot or shutdown will take a long time. Installing the acpid package should fix the issue.
The apply_binaries script installs lots of non-essential components. We are still working on breaking it up so only necessary files are installed.