Old gpu installation thread

output-onlinepngtools output-onlinepngtools(2)

Install the nvidia driver manually on Zorin OS 16: (scroll down for Pop! OS instructions)

  1. Download the official Nvidia Driver and place it in the home folder
    Optional: rename the NVIDIA-Linux-x86_64-470.63.01.run driver to 1.run. I use 1.run because i don't want to write the whole nvidia name into the terminal (step 8 and 9).
  2. Install the build essential package, those are needed for the nvidia driver. Write in the terminal:
    sudo apt install build-essential libglvnd-dev pkg-config
  3. Disable Nouveau Nvidia driver, write in the terminal:
    sudo bash -c "echo blacklist nouveau > /etc/modprobe.d/blacklist-nvidia-nouveau.conf"
    Write in terminal:
    sudo bash -c "echo options nouveau modeset=0 >> /etc/modprobe.d/blacklist-nvidia-nouveau.conf"
  4. Check if the nouveau driver is blacklisted, write in the terminal:
    cat /etc/modprobe.d/blacklist-nvidia-nouveau.conf
  5. After you checked, write in the terminal:

sudo update-initramfs -u

  1. Install dkms, this is needed so you don't need to reinstall the nvidia driver anymore after a kernel upgrade. Write in the terminal:

sudo apt-get install dkms

  1. Stop Desktop Manager, write in the terminal:

sudo telinit 3

  1. Make the Nvidia Driver executable (i did not have to do this step in Zorin OS 16), write in terminal:

chmod +x NVIDIA-Linux-x86_64-470.63.01.run

  1. Install the new Nvidia Driver, write in terminal:

sudo bash NVIDIA-Linux-x86_64-470.63.01.run

  1. Follow the steps in the nvidia setup
  2. The Nvidia driver is now installed, reboot with this command:

sudo reboot

  1. When you are in Zorin OS 16 check if the driver is actually installed, to check this write in the terminal:

sudo lshw -c display

  1. When the configuration says "configuration: latency=0" you have to disable secure boot in the bios.
  2. Reboot and your good to go

output-onlinepngtools output-onlinepngtools(2)

Update the nvidia driver manually on Zorin OS 16:

  1. Stop Desktop Manager, write in the terminal:

sudo telinit 3

  1. Make the Nvidia Driver executable (i did not have to do this step in zorin os 16), write in terminal:

chmod +x NVIDIA-Linux-x86_64-470.74.run

  1. Install the new Nvidia Driver.
    Write in terminal:

sudo bash NVIDIA-Linux-x86_64-470.74.run

  1. Hit everything on yes in the installer. (The new driver will delete the older driver)
  2. The Nvidia driver is now installed, reboot with this command:

sudo reboot

output-onlinepngtools(1) output-onlinepngtools(2)

Install the nvidia driver manually on Pop! OS 21.04:
First i found a tutorial online to install the nvidia driver manually on Pop! OS 20.04. This guide did not work at all for Pop! OS 21.04 and i am not sure if the tutorial online is complete, because i had to do alot more then those few steps they posted here β†’ Upgrading NVIDIA Drivers in Pop OS 20.04 | by Nitin Reddy | Medium

  1. Download the official Nvidia Driver and place it in the home folder
    Optional: rename the NVIDIA-Linux-x86_64-470.74.run driver to 1.run
  2. Install the build essential package, those are needed for the nvidia driver.
    In terminal write:

sudo apt install build-essential libglvnd-dev pkg-config

  1. Blacklist the Nouveau Nvidia driver otherwise the nvidia driver does not work proper. In terminal write:
    sudo bash -c "echo blacklist nouveau > /etc/modprobe.d/blacklist-nvidia-nouveau.conf"
    In terminal write:
    sudo bash -c "echo options nouveau modeset=0 >> /etc/modprobe.d/blacklist-nvidia-nouveau.conf"

  2. Check if the nouveau driver is blacklisted.
    In terminal write:
    cat /etc/modprobe.d/blacklist-nvidia-nouveau.conf

  3. If everything is done
    In terminal write:

sudo update-initramfs -u

Now we are going to install the nvidia driver. We switch to text mode.

  1. In terminal write:

systemctl set-default multi-user.target

  1. In terminal write:

reboot

Now we have booted into text mode. Login with your username and password.

  1. Write:

sudo apt remove --purge ^nvidia-.*

  1. When the purge is done write:

sudo apt-get autoremove

  1. Remember i said to change the NVIDIA-Linux-x86_64-470.74.run to 1.run ?, to make it easier now). Write:

chmod +x ./1.run

Optional: This will uninstall traces of the older nvidia driver. Just to make sure the purge was done correctly.

sudo ./1.run --uninstall

  1. Install the nvidia driver. Write:

sudo ./1.run

  1. Hit everything on yes in the installer.
  2. When the installation is done, write:

sudo -i

  1. When you have root access, write:

systemctl set-default graphical.target

  1. Now write reboot and your good to go if you did all the steps above.
  2. To confirm it’s working open nvidia x server settings, if the driver is not in use it will not open. Also in terminal write:

sudo lshw -c display

  1. When the configuration says "configuration: latency=0" you have to disable secure boot in the bios.

output-onlinepngtools(1) output-onlinepngtools(2)

Update the nvidia driver manually on Pop! OS 21.04:

  1. In terminal write:

systemctl set-default multi-user.target

  1. In terminal write:

reboot

  1. Remember i said to change the NVIDIA-Linux-x86_64-470.74.run to 1.run ?, to make it easier now). Write:

chmod +x ./1.run

  1. Install the new Nvidia Driver.
    Write in terminal:

sudo ./1.run

  1. Hit everything on yes in the installer. (The new driver will delete the older driver)
  2. When the installation is done, write:

sudo -i

  1. When you have root access, write:

systemctl set-default graphical.target

  1. Now write reboot and your good to go if you did all the steps above.
6 Likes

Hmmm... This seems very thorough, but also quite complicated way how to install nv drivers.
Why not just adding an nVidia repository to your Zorin system with:

sudo add-apt-repository ppa:graphics-drivers/ppa
sudo apt-get update

and then just installing drivers like:

sudo apt install nvidia-graphics-drivers-<xyz>

?

1 Like

Your method install drivers only from PPA.
@Michel's method install more recent driver which is only available from Nvidia site.

1 Like

@boldos, how is this complicated ? The steps i posted tells you exactly how to do so.

My first zorin os installation got messy with the ppa, i will never use that method again. Jelly mode was so slow...i tried to refert back to stock zorin os driver but it did not let me to and made it worse so i did a clean install and decided to use the nvidia driver instead.

1 Like

Well, his method is in 3 lines :wink:
But of course the end result is not the same.

That is a peril of PPA.
As the name indicates it is a "personal" thing and some PPA is abandoned for quite sometime. phpMyadmin is one of those and I had to install it from the source :frowning:

Zorin OS 16 got a kernel update, i noticed the nvidia driver was not working properly anymore. I have read somewhere this can be fixed, but i can't find it anymore.

For now i just reinstalled the driver, that worked.

1 Like

I have seen three other posts on this same thing. That the 5.11.0-34 kernel update caused Black Screen for other users. Tagging this to @azorin and @zorink for immediate attention.

Well don't forget i use the nvidia driver from the nvidia site. I did not get a black screen, it booted fine but i noticed it was a bit laggy. So i checked the driver and it was set to noveau again (even if it is blacklisted).

In the past in mint 17 nvidia used dkms, but when i check in zorin i don't even see dkms is installed. Do we need it so the driver can load AFTER a new kernel upgrade ?

DKMS can definitely help with this, but whether you need it depends on how the driver was installed. Drivers patched in from the developer generally do not need DKMS to roll forward with a kernel update. Drivers installed from a third party source by the user would need DKMS to prevent having to reinstall the driver each and every time the kernel upgrades.

Well like i said before, i do remember in the past when i manually installed nvidia on the mint 17 installation it used dkms. Now when i manually install the driver it does not ask about it.

So "normally" after a kernel upgrade the driver should auto load ? Even when i installed the nvidia driver from the nvidia site ?

In the case of your guide, you are installing from the Nvidia site, not from an independent developer that patched the driver for Linux.
DKMS may help you prevent needing to reinstall after a kernel upgrade.
You can install dkms with:

sudo apt-get install dkms

Then when you move to install a new kernel, build against the... Actually let me find a guide or this post can get out of hand...


Guide:
https://www.xmodulo.com/build-kernel-module-dkms-linux.html

Oh - one other thing - You also can often search for and install a dkms kernel already compiled. You can choose between the native kernel build or the LTS build.

Thanks for the guide, i think i will just reinstall the driver if it happens again haha.

1 Like

There may be an easier way and I am just not smart enough to point in that direction. But this is an issue that comes up often enough (Mostly with Realtek Drivers) that it is probably well worth me learning more about.

New kernel 5.11.0-36 + new nvidia driver 470.74 is working fine here.

2 Likes

Finally some good news for a change! :+1:

1 Like

Thread updated with Pop! OS 21.04 tutorial and dkms solution for Zorin OS 16 so users don't have to reinstall the nvidia driver when a kernel upgrade has been done.

2 Likes

I edited the first post to much haha. Can @StarTreker or @Aravisian change that ? if not please change this part

sudo apt remove --purge '^nvidia-.*'

to

sudo apt remove --purge ^nvidia-.*

I would if I could brother, but I don't have mod privilege, I can edit the title, but not your post. I'll edit it in spirit, yeah I know, doesn't help much, its the thought that counts lol. Its a beautiful post though, you are super stellar! :stars:

1 Like

25 times, I would say so.:expressionless:

Be careful what you wish for... I changed almost everything.

For a good reason, though. I removed much of the bold text, as for users copy/pasting it, it can cause problems. I replaced all block quotes with quotes or with markdown copy tags to prevent the markdown software from mis-rendering the actual text.

1 Like

I know, wanted to create a simple and good tutorial for the forum. I am a perfectionist

Thanks :smiley: