By Manuel, 2022-Mar-31
Latest update: 2023-Apr-03
Important for older Nvidia GPUs!
Currently (2023-Feb) nvidia-inst
does not support installing (older) legacy drivers. This means certain older Nvidia GPUs should use either the nouveau
kernel driver or install the appropriate legacy driver from the AUR (with yay
).
IMPORTANT NOTE: if you have added repository [kernel-lts]
into file /etc/pacman.conf
, please remove it from the file because this repository may include outdated packages.
Tip: you can still use command nvidia-inst -t
to find the needed commands, just be sure to change the package names according to the version (for example, change nvidia-dkms
to nvidia-470xx-dkms
etc.).
Overview
A new Nvidia driver installer, nvidia-inst
, replaces the old nvidia-installer-dkms
.
Here’s the output of the nvidia-inst
command with the help option:
$ nvidia-inst -h nvidia-inst - help installing Nvidia graphics drivers Usage: nvidia-inst [options] Options: -h, --help This help. -b, --bumblebee Install bumblebee and Nvidia drivers for optimus cards. -f, --force Force driver installation even if a nvidia card is not detected. -n, --nouveau Install nouveau driver (open source). -p, --prime Install also prime render offload. -q, --quiet Suppress log messages. -t, --test Test mode. Nothing in your system will be modified. -v, --version Show version of this software. --32 Install also support for 32-bit apps. --conf Create also file /etc/X11/xorg.conf.d/20-nvidia.conf (might be needed on some systems). --drivers Show supported NVIDIA driver series for your card. --ignore Ignore all errors (useful for testing only). --legacyrepo Add a third party repository for legacy (470 and 390 series) Nvidia drivers. --listopts List options supported by nvidia-inst. --listseries List Nvidia driver versions supported by nvidia-inst. --series (Advanced) Use the given Nvidia driver version (for testing).
If you have used nvidia-installer-dkms before, the help output above should look rather familiar.
Options
With nvidia-inst
you can install drivers for your Nvidia GPU. nvidia-inst
detects which driver packages are needed. Additional features will be installed based on given options.
Likely the most important new options in nvidia-inst
are
--prime
This option will install package nvidia-prime
in addition to the Nvidia drivers.
--legacyrepo
Adds a third party repo that includes legacy Nvidia drivers like 470 and 390 series. If the legacy drivers are required, use this option to add this third party repo. Note that you may need to check the supported drivers using the option --drivers
.
NOTE: this is currently not working, see the beginning of this article.
--drivers
List which Nvidia series drivers are supported with your Nvidia GPU.
--32
Includes also support for 32-bit apps, like certain games.
--conf
This option creates a simple Nvidia config file into folder /etc/X11/xorg.conf.d
. By default, this file will not be created. Note that nvidia-installer-dkms usually created this file.
Other new options should be either self explanatory, or mainly meant for internal testing of nvidia-inst
.
About the internal operation
If nvidia-inst is executed e.g. with option --nouveau
, it will remove conflicting packages like the nvidia drivers, and then install the nouveau driver. A similar idea is used with all options that need to take care of conflicting packages and/or certain settings: conflicting stuff will be removed first, and then the new packages/settings will be installed.
This also means that if you have Nvidia related packages or settings that you want to save, you need to do that manually before using nvidia-inst
.
References
Examples
Enable legacy drivers (older Nvidia cards)
Older Nvidia cards like GT 700 series are not supported by the latest Nvidia driver available from the official Arch repositories. For those cards there are a few alternatives:
- the
nouveau
open source kernel driver - a legacy Nvidia driver from the
AUR
a legacy Nvidia driver from the third party repositorynot available anymore.
For the older cards nvidia-inst
supports nouveau
(option -n
), and a third party repository named kernel-lts
by @Jonathon.
The third party repository can be initialized with command
nvidia-inst --legacyrepo
This command adds the kernel-lts repository permanently into your pacman.conf
making certain Nvidia legacy (470 and 390 series) drivers available.
To see which of the legacy drivers is supported, runnvidia-inst --drivers
Before actually installing the drivers, you should test (dry-run) the install to make 100% sure it will work. Use option -t
:
nvidia-inst --series 390 -t 2022-04-25 23:45:00: Info: Running: nvidia-inst v1.0.3-1 2022-04-25 23:45:00: Info: Command line: nvidia-inst --series 390 -t 2022-04-25 23:45:00: Info: Selected mode: nvidia 2022-04-25 23:45:00: Info: Installing packages: nvidia-390xx-dkms nvidia-390xx-utils nvidia-390xx-settings ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ COMMANDS TO RUN: pacman -Syuq --noconfirm --noprogressbar --needed nvidia-390xx-dkms nvidia-390xx-utils nvidia-390xx-settings ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
or if 470 is supported:nvidia-inst --series 470 -t
if test (-t) runs without error, you can do real install:nvidia-inst --series 390
ornvidia-inst --series 470
After rebooting the drivers should be active. You will get driver updates as expected using pacman or yay.
Bumblebee (for old machines)
If you need to set up Bumblebee as detailed here: EndeavourOS Bumblebee wiki the nvidia-inst script can do that automatically too:
nvidia-inst -b