- Nouveau
- Contents
- Installation
- Loading
- Enable early KMS
- Tips and tricks
- Keep NVIDIA driver installed
- Installing the latest development packages
- Dual head
- Setting console resolution
- Power management
- Fan control
- Optimus
- Vertical Sync
- Troubleshooting
- Disable MSI
- Phantom output issue
- Kernel parameters
- Xorg configuration
- Xrandr
- Random lockups with kernel error messages
- Flat Panel Table Invalid
- Wpilot
- суббота, 13 июля 2013 г.
- Как отключить драйвер Nouveau в Linux
- Unix Driver Archive
- Install NVIDIA Drivers
- Prerequisites
- Install DKMS
- Download and install the NVIDIA Drivers
- Download the NVIDIA Drivers for Linux
- Disable the nouveau Driver
- Configure the Dynamic Linker
- Install the NVIDIA Drivers
- Updating the NVIDIA Drivers
- Uninstalling the NVIDIA Drivers
- Debugging Installation of NVIDIA Drivers
- Additional resources
Nouveau
This article covers the open-source Nouveau driver for NVIDIA graphics cards. For information about the proprietary driver, see NVIDIA.
Find your card’s code name (a more detailed list is available on Wikipedia), and compare it with the feature matrix for supported features.
Contents
Installation
Install the mesa package, which provides the DRI driver for 3D acceleration.
- For 32-bit application support, also install the lib32-mesa package from the multilib repostory.
- For the DDX driver (which provides 2D acceleration in Xorg), install the xf86-video-nouveau package.
Loading
The Nouveau kernel module should load automatically on system boot. If it does not happen, then:
- Make sure you do not have nomodeset or vga= as a kernel parameter, since Nouveau requires kernel mode-setting.
- Also, check that you do not have Nouveau disabled using any modprobe blacklisting technique within /etc/modprobe.d/ or /usr/lib/modprobe.d/ .
- If all above still fails to load nouveau check dmesg for an opcode error. Add nouveau.config=NvBios=PRAMIN to your Kernel parameters to prevent module unloading.[1]
- Check if /etc/X11/xorg.conf exists and is referencing nvidia driver. It is probably a good idea to rename the file.
Enable early KMS
Kernel mode setting (KMS) is required by the Nouveau driver. By default, the KMS is done after the other kernel modules are loaded. You will see the text «Loading modules» and the size of the text may change, possibly with an undesirable flicker. See the Nouveau KernelModeSetting page for more details.
It is also possible to start the KMS as early as possible in the boot process, when the initramfs is loaded.
To do this, add nouveau to the MODULES array in /etc/mkinitcpio.conf (module names are separated by spaces):
If you are using a custom EDID file, you should embed it into initramfs as well:
Re-generate the initial ramdisk image:
If you are experiencing troubles with Nouveau leading to rebuild nouveau-drm several times for testing purposes, do not add nouveau to the initramfs. It is too easy to forget to rebuild the initramfs and it will just make any testing harder. Just use «Late start» until you are confident the system is stable. There might be additional problems with initramfs if you need a custom firmware (generally not advised).
Tips and tricks
Keep NVIDIA driver installed
If you want to keep the proprietary NVIDIA driver installed (and are not using OpenGL), but want to use the Nouveau driver, comment out nouveau blacklisting in /etc/modprobe.d/nouveau_blacklist.conf , /usr/lib/modprobe.d/nvidia.conf , or /usr/lib/modprobe.d/nvidia-dkms.conf modifying it as follows:
And tell Xorg to load nouveau instead of nvidia by creating the file /etc/X11/xorg.conf.d/20-nouveau.conf with the following content:
If you already used the NVIDIA driver, and want to test Nouveau without reboot, make sure the ‘nvidia’ module is no longer loaded:
Then load the ‘nouveau’ module:
And check that it loaded fine by looking at kernel messages:
Installing the latest development packages
To get the latest Nouveau improvements
Dual head
See Multihead#RandR how to setup multiple monitors by using RandR.
Setting console resolution
You can pass the resolution to nouveau with the video= kernel line option (see KMS).
Power management
The lack of proper power management in the nouveau driver is one of the most important causes of performance issues, since most cards will remain in their lower power state with lower clocks during their use. Experimental support for GPU reclocking is available for some cards (see the Nouveau PowerManagement page) and since kernel 4.5 can be controlled through a debugfs interface located at /sys/kernel/debug/dri/*/pstate .
For example, to check the available power states and the current setting for the first card in your system, run:
It is also possible to manually set/force a certain power state by writing to said interface:
Fan control
If it is implemented for your card you can configure fan control via /sys .
pwm1_enable can be set to 0, 1 or 2 meaning NONE, MANUAL and AUTO fan control. If set to manual fan control, you can set pwm1 manually, for example to 40 for 40%.
You can also set it by udev rule:
Optimus
You have two solutions to use Optimus on a laptop (aka hybrid graphics, when you have two GPUs on your laptop): bumblebee and PRIME
Vertical Sync
The factual accuracy of this article or section is disputed.
Xorg compositors are prone to show issues with Nouveau. Unlike most of them, Picom offers lots of options to tweak for a smoother and tearing free result. A configuration which is expected to deliver a good result would be the following:
Troubleshooting
Add drm.debug=14 and log_buf_len=16M to your kernel parameters to turn on video debugging:
Create verbose Xorg log:
View loaded video module parameters and values:
Disable MSI
If you are still having problems loading the module or starting X server append nouveau.config=NvMSI=0 to your Kernel parameters.
Phantom output issue
It is possible for the nouveau driver to detect «phantom» outputs. For example, both VGA-1 and LVDS-1 are shown as connected but only LVDS-1 is present.
This causes display problems and/or prevent suspending on lid closure.
Kernel parameters
The problem can be overcome by disabling the phantom output (VGA-1 in the examples given) with Kernel parameters:
Where d = disable.
The nouveau kernel module also has an option to disable TV-out detection [2]:
Xorg configuration
The phantom output can be disabled in Xorg by adding the following to /etc/X11/xorg.conf.d/20-nouveau.conf :
Xrandr
Xrandr can disable the output:
This can be added to the xinit configuration.
Random lockups with kernel error messages
Specific Nvidia chips with Nouveau may give random system lockups and more commonly throw many kernel messages, seen with dmesg. Try adding the nouveau.noaccel=1 kernel parameter. See Fedora:Common kernel problems#Systems with nVidia adapters using the nouveau driver lock up randomly for more information.
As an alternative you can also use the QT_XCB_FORCE_SOFTWARE_OPENGL=1 environment variable to disable OpenGL acceleration in Qt applications.
Flat Panel Table Invalid
This article or section needs expansion.
NVIDIA graphics cards with recent chipsets can cause startup issues — this includes X11 being unable to start and lspci freezing indefinitely[3][4][5][6][7].
This can break live distributions/installation media. This can be detected either by running lspci, or checking the systemd journal for the error:
The system may start if the Nouveau driver is disabled by passing the following kernel parameters:
The Nouveau driver can then be loaded using
The system should then function correctly. If you have another Nvidia graphics card, or just want to be safe, you can disable the offending card using:
The NVIDIA proprietary driver currently works correctly (version 381).
Источник
Wpilot
суббота, 13 июля 2013 г.
Как отключить драйвер Nouveau в Linux
При попытке установить драйвера для видеокарты Nvidia многие сталкивались вот с такой ошибкой:
ERROR: The Nouveau kernel driver is currently in use by your system. This driver is incompatible with the NVIDIA driver, and must be disabled before proceeding. Please consult the NVIDIA driver README and your Linux distribution’s documentation for details on how to correctly disable the Nouveau kernel driver. WARNING: The modprobe configuration file to disable Nouveau, /etc/modprobe.d/nvidia-installer-disable-nouveau.conf, is already present. Please be sure you have rebooted your system since that file was written. If you have rebooted, then Nouveau may be enabled for other reasons, such as being included in the system initial ramdisk or in your X configuration file. Please consult the NVIDIA driver README and your Linux distribution’s documentation for details on how to correctly disable the Nouveau kernel driver. ERROR: Installation has failed. Please see the file ‘/var/log/nvidia-installer.log’ for details. You may find suggestions on fixing installation problems in the README available on the Linux driver download page at www.nvidia.com.
Эта ошибка говорит о том что в настоящее время используется драйвер Nouveau и его нужно отключить для установки драйверов Nvidia.
Чтобы не возникало такой проблемы нужно отключить драйвер на начальном этапе загрузки системы. Для этого если система грузится как здесь Ubuntu 9.10 с флешки добавляем в menu.lst nouveau.modeset=0 после этого наш menu.lst будет выглядеть вот так:
title Start Ubuntu 9.10 from USB DISK
root (cd)
kernel /boot/vmlinuz file=/cdrom/preseed/ubuntu.seed boot=casper noprompt cdrom-detect/try-usb=true persistent nouveau.modeset=0
initrd /boot/initrd.lz
boot
Следущий шаг удаляем все драйвера Nouveau пишем в терминале:
sudo apt-get purge xserver-xorg-video-nouveau
Источник
Unix Driver Archive
Linux x86_64/AMD64/EM64T
Latest Production Branch Version: 470.74
Latest New Feature Branch Version: 465.31
Latest Legacy GPU version (390.xx series): 390.144
Latest Legacy GPU version (340.xx series): 340.108
Latest Legacy GPU version (304.xx series): 304.137
Latest Legacy GPU Version (71.86.xx series): 71.86.15
Latest Legacy GPU Version (96.43.xx series): 96.43.23
Latest Legacy GPU Version (173.14.xx series): 173.14.39
Archive
Linux x86/IA32
Latest Legacy GPU version (390.xx series): 390.144
Latest Legacy GPU version (340.xx series): 340.108
Latest Legacy GPU version (304.xx series): 304.137
Latest Legacy GPU version (71.86.xx series): 71.86.15
Latest Legacy GPU version (96.43.xx series): 96.43.23
Latest Legacy GPU version (173.14.xx series): 173.14.39
Archive
Linux aarch64
Latest Production Branch Version: 470.74
Latest New Feature Branch Version: 465.31
Archive
Linux 32-bit ARM
Latest Legacy GPU version (390.xx series): 390.144
Archive
FreeBSD x86
Latest Legacy GPU version (390.xx series): 390.144
Latest Legacy GPU version (340.xx series): 340.108
Latest Legacy GPU version (304.xx series): 304.137
Latest Legacy GPU Version (71.86.xx series): 71.86.15
Latest Legacy GPU Version (96.43.xx series): 96.43.23
Latest Legacy GPU Version (173.14.xx series): 173.14.39
Archive
FreeBSD x64
Latest Production Branch Version: 470.74
Latest New Feature Branch Version: 465.31
Latest Legacy GPU version (390.xx series): 390.144
Latest Legacy GPU version (340.xx series): 340.108
Latest Legacy GPU version (304.xx series): 304.137
Archive
Solaris x64/x86
Latest Production Branch Version: 470.74
Latest New Feature Branch Version: 465.31
Latest Legacy GPU version (390.xx series): 390.144
Latest Legacy GPU version (340.xx series): 340.108
Latest Legacy GPU version (304.xx series): 304.137
Latest Legacy GPU version (96.43.xx series): 96.43.23
Latest Legacy GPU version (173.14.xx series): 173.14.39
Archive
NVIDIA nForce Drivers
Open source drivers for NVIDIA nForce hardware are included in the standard Linux kernel and leading Linux distributions. This page includes information on open source drivers, and driver disks for older Linux distributions including 32-bit and 64-bit versions of Linux.
Источник
Install NVIDIA Drivers
NVIDIA is a manufacture of graphics processing units (GPU), also known as graphics cards.
NVIDIA devices on Linux have two popular device driver options: the opensource drivers from the nouveau project or the proprietary drivers published by NVIDIA. The nouveau drivers are built into the Clear Linux* OS kernel and are loaded automatically at system boot if a compatible card is detected.
These instructions show how to use the proprietary NVIDIA drivers which require a manual installation.
Software installed outside of swupd is not updated with Clear Linux OS updates and must be updated and maintained manually.
Prerequisites
- A Clear Linux OS system with a desktop installed
- A NVIDIA device installed
Install DKMS
The Dynamic Kernel Module System (DKMS) allows the NVIDIA kernel modules to be automatically integrated when kernel updates occur in Clear Linux OS.
Install the appropriate DKMS bundle using the instructions below:
The Long Term Support (LTS) kernel variant is more likely to remain compatible between updates with NVIDIA drivers.
The kernel-native-dkms bundle provides the dkms program and Linux kernel headers, which are required for compiling kernel modules.
The kernel-native-dkms bundle also:
- Adds a systemd update trigger (/usr/lib/systemd/system/dkms-new-kernel.service) to automatically run DKMS to rebuild modules after a kernel upgrade occurs with swupd update.
- Disables kernel module signature verification by appending a kernel command-line parameter ( module.sig_unenforce ) from the /usr/share/kernel/cmdline.d/clr-ignore-mod-sig.conf file.
- Adds a notification to the Message of the Day (MOTD) indicating kernel module signature verification is disabled.
We recommend that you always review the swupd update output to make sure kernel modules were successfully rebuilt against the new kernel. This is especially important for systems where a successful boot relies on a kernel module.
Install the kernel-native-dkms or kernel-lts-dkms bundle:
- Determine which kernel variant is running on Clear Linux OS. Only the native and lts kernels are enabled to build and load out-of-tree kernel modules with DKMS.
$ uname -r 5.XX.YY-ZZZZ.native
Ensure .native or .lts is in the kernel name.
2. Install the DKMS bundle corresponding to the installed kernel. Use kernel-native-dkms for the native kernel or kernel-lts-dkms for the lts kernel.
sudo swupd bundle-add kernel-native-dkms
sudo swupd bundle-add kernel-lts-dkms
- Update the Clear Linux OS bootloader and reboot.
sudo clr-boot-manager update reboot
Download and install the NVIDIA Drivers
Download the NVIDIA Drivers for Linux
- Identify the model of NVIDIA GPU that is installed.
sudo lshw -C display
- Go to the NVIDIA Driver Downloads website . Search for and download the appropriate driver based on the model of NVIDIA GPU you have with Linux 64-bit selected as the Operating System .
- Open a terminal and navigate to where the NVIDIA-Linux-x86_64-.run file was saved. In this example, it was saved in the Downloads folder.
- Make the NVIDIA-Linux-x86_64-.run file executable.
hmod +x :file:`NVIDIA-Linux-x86_64-.run
Disable the nouveau Driver
The proprietary NVIDIA driver is incompatible with the nouveau driver and needs to be disabled before installation can continue.
- Disable the nouveau driver by creating a blacklist file under /etc/modprobe.d and reboot.
sudo mkdir /etc/modprobe.d printf «blacklist nouveau \noptions nouveau modeset=0 \n» | sudo tee —append /etc/modprobe.d/disable-nouveau.conf
- Reboot the system and log back in. It is normal for the graphical environment to not start with no NVIDIA driver loaded.
Configure the Dynamic Linker
The NVIDIA installer will be directed to install files under /opt/nvidia as much as possible to keep its contents isolated from the rest of the Clear Linux OS system files under /usr. The dynamic linker will need to be configured to use the NVIDIA-provided libraries.
- Configure the dynamic linker to look for and cache shared libraries under /opt/nvidia/lib and /opt/nvidia/lib32.
echo «include /etc/ld.so.conf.d/*.conf» | sudo tee —append /etc/ld.so.conf sudo mkdir /etc/ld.so.conf.d printf «/opt/nvidia/lib \n/opt/nvidia/lib32 \n» | sudo tee —append /etc/ld.so.conf.d/nvidia.conf
Install the NVIDIA Drivers
- A terminal not running on /dev/tty1 is useful to view uninterrupted installation progress. Switch to a secondary virtual terminal by pushing CTRL + ALT + F2 or remotely login over SSH.
- Navigate into the directory where the NVIDIA installer was downloaded.
- Run the installer with the advanced options below.
sudo ./NVIDIA-Linux-x86_64- .run \ —utility-prefix=/opt/nvidia \ —opengl-prefix=/opt/nvidia \ —compat32-prefix=/opt/nvidia \ —compat32-libdir=lib32 \ —x-prefix=/opt/nvidia \ —documentation-prefix=/opt/nvidia \ —no-precompiled-interface \ —no-nvidia-modprobe \ —no-distro-scripts \ —force-libglx-indirect \ —dkms \ —silent
- The graphical interface may automatically start after the NVIDIA driver is loaded. Return to the working terminal and log back in if necessary.
- Validate the nvidia kernel modules are loaded.
lsmod | grep ^nvidia
- Run a Clear Linux OS system verification to restore files that the NVIDIA installer likely deleted.
sudo swupd verify —quick —fix —bundles=lib-opengl
The NVIDIA software places some files under the /usr subdirectory which are not managed by Clear Linux OS and conflict with the Clear Linux OS stateless design. Although a limited version of swupd verify –fix is ran above, other uses of the swupd verify –fix command should be avoided with the proprietary NVIDIA drivers installed.
Updating the NVIDIA Drivers
The proprietary NVIDIA drivers are installed manually outside of swupd and must be updated manually when needed.
Updating the NVIDIA drivers follows the same steps as initial installation, however the desktop environment must first be stopped so that the drivers are not in use.
- Follow the steps in Download the NVIDIA Drivers for Linux section to get the latest NVIDIA drivers.
- Temporarily set the default boot target to the multi-user which is a non-graphical runtime.
sudo systemctl set-default multi-user.target
- Reboot the system and log back in. It is normal for the graphical environment to not start.
- Follow the steps in Install the NVIDIA Drivers section to update the NVIDIA drivers. This installation will overwrite the previous NVIDIA drivers and files.
- Set the default boot target back to the graphical target.
sudo systemctl set-default graphical.target
- Reboot the system and log back in.
- Trigger a flatpak update which will download the runtime corresponding with the new NVIDIA drivers for flatpak apps requiring it.
Uninstalling the NVIDIA Drivers
The NVIDIA drivers and associated software can be uninstalled and nouveau driver restored by:
- Remove the previously created file /etc/modprobe.d that prevents nouveau from loading.
sudo rm /etc/modprobe.d/disable-nouveau.conf
- Run the sudo /opt/nvidia/bin/nvidia-uninstall
- Follow the prompts on the screen and reboot the system.
Debugging Installation of NVIDIA Drivers
- The NVIDIA driver places installer and uninstaller logs under /var/log/nvidia-install and /var/log/nvidia-uninstall.
- NVIDIA-Linux-x86_64-.run —advanced-options shows many parameters to control installation behavior.
- NVIDIA-Linux-x86_64-.run —extract-only extracts installation files into a directory namedNVIDIA-Linux-x86_64-.
Additional resources
I followed the above instructions and once I installed the Nvidia drivers with the options it restarted but only to a flashing cursor and not a bash prompt or the Clear Linux desktop. It doesn’t allow any input from the keyboard etc. Not sure if there is any option to recover other than to do a clean install?
There is a recovery mode in the installer. @miguelinux can you help here, please?
Источник