jetsonhacks / bootFromExternalStorage

Shell scripts to setup a NVIDIA Jetson AGX Xavier, Xavier NX, AGX Orin, or Orin Nano Developer Kit to boot from external storage.
MIT License
158 stars 72 forks source link

[BUG] ./get_jetson_files.sh fails #2

Closed ranrubin closed 3 years ago

ranrubin commented 3 years ago

Describe the issue Script fails with errors.

...
Linux_for_Tegra/odmfuse.func
tar: Linux_for_Tegra/bootloader: Cannot utime: Operation not permitted
tar: Linux_for_Tegra/bootloader: Cannot change mode to rwxrwxr-x: Operation not permitted
Linux_for_Tegra/nvmassfusegen.sh
Linux_for_Tegra/pkc/
Linux_for_Tegra/pkc/0001-warmboot-change-wb-prepare-code-for-t1x4.patch
Linux_for_Tegra/pkc/tegrafuse.sh
Linux_for_Tegra/pkc/nvsecuretool
Linux_for_Tegra/pkc/LICENSE.mkpkc
Linux_for_Tegra/pkc/mkpkc
Linux_for_Tegra/pkc/LICENSE.nvsecuretool
Linux_for_Tegra/odmfuse.sh
tar: Linux_for_Tegra: Cannot utime: Operation not permitted
tar: Linux_for_Tegra: Cannot change mode to rwxrwxr-x: Operation not permitted
tar: Exiting with failure status due to previous errors
Using rootfs directory of: /home/rrubin/bootFromExternalStorage/R32.6.1/Linux_for_Tegra/rootfs
Installing extlinux.conf into /boot/extlinux in target rootfs
/home/rrubin/bootFromExternalStorage/R32.6.1/Linux_for_Tegra/nv_tegra/nv-apply-debs.sh
Root file system directory is /home/rrubin/bootFromExternalStorage/R32.6.1/Linux_for_Tegra/rootfs
Copying public debian packages to rootfs

To Reproduce ./get_jetson_files.sh Ubuntu 20

Expected behavior Successful finish of the script

Solution Solved by adding "export LDK_ROOTFS_DIR="/home/$USER/bootFromExternalStorage/R32.6.1/Linux_for_Tegra" to the ./get_jetson_files.sh script. Linux_for_Tegra/apply_binaries.sh expects it

jetsonhacks commented 3 years ago

Thank you for this. This seems to be one of the differences between the official NVIDIA Ubuntu 16.04 and 18.04 support and Ubuntu 20.04. I added: export LDK_ROOTFS_DIR=$PWD Which should point at the current working directory.

hrshovon commented 2 years ago

Putting this here as it might be useful. I am using ubuntu 22.04 and I faced the same issue. This is how I solved it. At the end of ./get_jetson_files.sh I replaced

if [[ $(lsb_release -rs) == "20.04" ]] ; then
  export LDK_ROOTFS_DIR=$PWD
fi

with

ubuntu_version=$(lsb_release -rs)
if [[ ${ubuntu_version%%.*} -ge 20 ]] ; then
  export LDK_ROOTFS_DIR=$PWD
fi

This should work for newer versions of ubuntu as well