I saw an xorg update, so I thought I’d check out if this is what has been troubling people. It is!
This packages is at fault for overwriting nVidia’s version:
xserver-xorg-core
Before upgrading those two packages (comes with xserver-common), deselect xserver-xorg-core.
For nVidia:
L4T contains file Linux_for_Tegra/nv_tegra/config.tbz2. This is for apply_binaries.sh, and this is where L4T should be modified to safeguard
/usr/lib/xorg/modules/extensions/libglx.so
…I’m not sure what the dpkg setup would be to keep nVidia’s file and not overwrite it.
EDIT: For those who lost graphics/X11 login, remember that serial port and ethernet still work. You should be able to use scp to copy files from another machine to Jetson even when graphics fail. You can also copy files to a USB thumb drive or SD card (typically auto mounts under /media).
--------------------------------------------------------------------------------------
NOTE: The start page for downloading various L4T versions is here…if you need the replacement of libglx.so and do not have it this might be where you will find it (original R19.2 is not available and R19.3 can’t be mixed with R19.2):
https://developer.nvidia.com/linux-tegra
EDIT: People should keep their Jetson systems up to date, and it may be that a simplification of remotely restoring the libglx.so file is in order. I sense a fear in “apt-get upgrade”. So here is a way to remotely reinstall nVidia files with less hassle.
NOTE: ssh option “-t” allows for answering questions from the remote system, e.g., password when using sudo; also, this assumes your Jetson has address “tk1” (adjust to your taste, replace “tk1” with whatever you use).
Preparation BEFORE any failure:
Copy the master tar of all nVidia files to “/” of tk1. This exists in your host’s nVidia L4T release in subdirectory “nv_tegra” as nvidia_drivers.tbz2. Use scp or any method you might use to place this as root ownership in “/” (e.g., use sudo scp from tk1 to pull from host, or copy as ubuntu ownership and later use “sudo chown root.root nvidia_drivers.tbz2”). E.G., initially copy this to ubuntu@tk1’s home directory and then use sudo to move and change ownership to “/nvidia_drivers.tbz2”. This file contains all of nVidia’s files which may need re-installation if some part of Ubuntu were to overwrite the files. libglx.so is one of those files. Unpacking this file as root (or sudo) is the same as running “apply_binaries.sh” on the sample rootfs.
Validate this file is in place and that you have ssh access. From remote host this should list the file (asking twice for password…once for ssh, once for sudo) on tk1:
ssh -t ubuntu@tk1 'sudo ls /nvidia_drivers.tbz2'
This should list files within the tar archive from host as executed on tk1:
ssh -t ubuntu@tk1 'sudo bunzip2 < /nvidia_drivers.tbz2 | tar --list'
This should validate existing nVidia files from host as executed on tk1:
ssh -t ubuntu@tk1 'sudo sha1sum -c /etc/nv_tegra_release'
NOTE: The “-t” option of ssh can’t be used directly with scp, but you can use “ssh -t ‘sudo scp …’” and be creative.
On host, this script (with passwords) will check nVidia files (mine is in /usr/local/bin and is named “remote_nv_check.sh”):
#!/bin/bash
ssh -t ubuntu@tk1 'sudo sha1sum -c /etc/nv_tegra_release'
Next, a remote extract example, but beware permissions must be preserved and without root or root authority (sudo) this won’t happen (also note that naming exact file in this case names a relative path and so you must be in “/” when running this…it is the tar archive listing that determines the relative path):
ssh -t ubuntu@tk1 'cd / ; bunzip2 < /nvidia_drivers.tbz2 | sudo tar xv --overwrite usr/lib/xorg/modules/extensions/libglx.so'
Simply run the above command with the exact path of any file shown to not pass the remote_nv_check.sh command. One could make a script specific to libglx.so (and add others to the list if desired), e.g., create remote_nv_libglx_fix.sh:
#!/bin/bash
ssh -t ubuntu@tk1 'cd / ; bunzip2 < /nvidia_drivers.tbz2 | sudo tar xv --overwrite usr/lib/xorg/modules/extensions/libglx.so'
Replacing any file in the same way is easy once you know this commad. To get the list of all files available in the nvidia_drivers.tbz2:
bunzip2 < nvidia_drivers.tbz2 | tar --list