Here’s what I do:
- install all the stuff I actually want on the Xavier, and remove all the crap (like libreoffice). Then on the host, enter the L4T:
cd jetpack/Xavier/Linux_for_Tegra
- Slurp the root file system to the local machine:
(ssh xavier sudo find / -xdev -depth -print | sudo cpio -o -H crc | gzip) > xavier-root-file-system.cpio.gz
- remove the current root file system:
mv rootfs rootfs.orig
- create new root file system:
mkdir rootfs
cd rootfs
zcat ../xavier-root-file-system.cpio.gz | sudo cpio -i -m --no-absolute-filenames -u -d
Now, when I flash the system using flash.sh, it applies the binaries on my new setup, and writes it to the xavier. This lets me get things like SSH keys, installed libraries and apps, configured hostname, and so forth, already in place.
In general, I don’t recommend treating the xavier EMMC as “durable.” Get into a habit of flashing once a week, just so you know you have a repeatable, robust process! (This is similar to “you don’t have a backup until you’ve successfully restored it once!”)