Linux Hint Posted November 23, 2023 Share Posted November 23, 2023 In this article, we will show you how to check if an NVIDIA GPU is installed on your computer from different Linux distributions. Topic of Contents: Method 1: Using the Lspci Command Method 2: Using the Nvidia-Detect Command Method 3: Using the Ubuntu-Drivers Command Conclusion Method 1: Using the Lspci Command The “lspci” command is used to list all the PCI devices that are installed on your computer. It can also be used to list only the GPUs that are installed on your computer. The “lspci” command is available on most of the common Linux distributions. To list only the installed GPUs of your computer, run the following command: $ lspci | grep 'VGA|NVIDIA' As you can see, we have an NVIDIA GeForce GTX 1050 Ti GPU installed on our computer. You will most likely have a different GPU installed on your computer. So, you will see a different output than ours. Method 2: Using the Nvidia-Detect Command The “nvidia-detect” command is available on the Debian Linux operating system. If you’re using a Debian Linux on your computer, you can use it to check whether you have an NVIDIA GPU installed on your computer. The “nvidia-detect” tool is not installed on Debian Linux by default. But you can easily install it from the Debian non-free package repository. First, enable the Debian non-free package repository on your Debian Linux operating system. Then, update the Debian Linux package repository cache with the following command: $ sudo apt update To install the “nvidia-detect” tool, run the following command: $ sudo apt install nvidia-detect To confirm the installation, press “Y” and then press <Enter>. To check whether you have an NVIDIA GPU installed on your computer, run the “nvidia-detect” command as follows: $ nvidia-detect If you have an NVIDIA GPU installed on your computer, it is listed on the output of the “nvidia-detect” command. As you can see, we have an NVIDIA GeForce GTX 1050 Ti GPU installed on our computer. You will most likely have a different NVIDIA GPU installed on your computer. Method 3: Using the Ubuntu-Drivers Command If you’re using Ubuntu Linux on your computer, you can use the “ubuntu-drivers” command to check whether you have an NVIDIA GPU installed on your computer. To check whether you have an NVIDIA GPU installed on your computer from the Ubuntu Linux operating system, run the “ubuntu-drivers” command as follows: $ ubuntu-drivers devices If you have an NVIDIA GPU installed on your computer, it will be listed on the output of the “ubuntu-drivers” command. As you can see, we have an NVIDIA GeForce GTX 1050 Ti GPU installed on our computer. You will most likely have a different NVIDIA GPU installed on your computer. Conclusion In this article, we showed you how to use the “lspci” command to check if you have an NVIDIA GPU installed on your computer from most of the common Linux distributions. We also showed you how to use the “nvidia-detect” and “ubuntu-drivers” commands to check if you have an NVIDIA GPU installed on your computer from the Debian Linux and Ubuntu Linux operating systems, respectively. View the full article Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.