Score:0

Failed Nvidia graphics driver installation - bad aspect ratio

cn flag

Here are the specs I'm working with:

  • x86_64 architecture
  • Intel Core i7-4790K processor
  • Nvidia GeForce GTX 960 graphics card
  • Ubuntu version 20.04.3 LTS

From what I can tell, this seems to be a common issue. I attempted to install one of Nvidia's graphic drivers by following some advice on the forums. Very quickly, things went downhill, and I was eventually unable to boot the system (the login page wouldn't display, and I would be stuck with a black screen).

I salvaged the OS after an entire day of trying by going into the Recovery Mode command line, deleting all of my Nvidia packages, tweaking the blacklists (which I believe is what caused the mess to begin with - someone suggested blacklisting the default, open-source driver), and trying to fix a broken bumblebee (I kept getting bbswitch errors).

Now I can boot the system and log in, which is great, but the aspect ratio is messed up and the graphics are awful. My intuition is that the default graphics driver (the xserver / xorg / nouveau one) is not working properly. I don't know where to start with fixing it, though!

First, is there any way I can revert the graphics card settings/packages back to default, without reinstalling the OS? Or if that isn't possible, would there be any way to reinstall Ubuntu without losing my personal files and/or app data?

If that isn't an option, where would you guys start with diagnosing the exact issue and fixing it? Thanks in advance!

EDIT ( @heynnema ): Here is my output for dpkg -l *nvidia*: dpkg -l nvidia (pt1) dpkg -l nvidia (pt2)

Here is my output for dkms status: dkms status

Finally, here is what I see in that Additional Drivers tab: Additional Drivers

EDIT 2 ( @heynnema ):

Here is the error I get when attempting to use "Additional Drivers" to switch to nvidia-driver-495

attempt to install nvidia-driver-495

EDIT 3 ( @heynnema ): Here is what I get from dpkg -l *nvidia*:

dpkg -l *nvidia*
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/tr>
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name                             Version                >
+++-================================-=======================>
un  libgldispatch0-nvidia            <none>                 >
ii  libnvidia-cfg1-470:amd64         470.82.00-0ubuntu0.20.0>
un  libnvidia-cfg1-any               <none>                 >
un  libnvidia-common                 <none>                 >
ii  libnvidia-common-470             470.82.00-0ubuntu0.20.0>
un  libnvidia-compute                <none>                 >
ii  libnvidia-compute-470:amd64      470.82.00-0ubuntu0.20.0>
ii  libnvidia-compute-470:i386       470.82.00-0ubuntu0.20.0>
rc  libnvidia-compute-495:amd64      495.44-0ubuntu0.20.04.1>
un  libnvidia-decode                 <none>                 >
ii  libnvidia-decode-470:amd64       470.82.00-0ubuntu0.20.0>
ii  libnvidia-decode-470:i386        470.82.00-0ubuntu0.20.0>
un  libnvidia-encode                 <none>                 >
ii  libnvidia-encode-470:amd64       470.82.00-0ubuntu0.20.0>
ii  libnvidia-encode-470:i386        470.82.00-0ubuntu0.20.0>
un  libnvidia-extra                  <none>                 >
lines 1-21
Maheswar KARAKKATTU KISHOR KUM avatar
Just asking, have you done a full reinstall?
cn flag
Full reinstall of the OS, I'm assuming you mean? Haven't done that yet, but I realize that it might be the best option. Just don't want to lose my data.
heynnema avatar
ru flag
Edit your question and show me `dpkg -l *nvidia*`, and `dkms status`, and a screenshot of your `Software & Updates` **Additional Drivers** tab. Start comments to me with @heynnema or I'll miss them.
cn flag
@heynnema I've updated the original post with the screenshots. Thanks!
Nmath avatar
ng flag
Please don't post screenshots of your terminal! Instead, copy/paste the requested information and use [code fences](https://askubuntu.com/editing-help#code) to retain line breaks and monospace formatting. Can you also link to this guide that you followed? Something fishy about that considering that the guide probably gave bad or outdated information. Especially since installing proprietary Nvidia drivers can be done with a single command (`sudo ubuntu-drivers autoinstall`) or just a few clicks in the GUI software center.
cn flag
@Nmath I've created a bit of a nightmare for myself - I used advice from a bunch of different forum posts relating to the installation of Nvidia drivers, and boot issues relating to those drivers. I started with the command you posted and other simple, sane ways to go about it, but as things got worse (boot issues) I began to take more drastic (and in hindsight, silly) measures, like editing / deleting blacklists, uninstallation / reinstallation of bumblebee, xorg, etc. The only silly things I DIDN'T do was try to install directly from Nvidia's website, or a link to it.
Nmath avatar
ng flag
A full reinstall of the OS might be the most prudent course of action at this point if the answer below does not solve the problem, especially if you can't effectively and efficiently reverse all of the potentially damaging actions
Score:0
ru flag

sudo apt-get purge libnvidia-compute-470 # remove the last piece of Nvidia 470

Open Software & Updates, Additional Drivers tab

Select the nvidia-driver-470 # reinstall Nvidia 470 (NOT server package)

reboot # reboot the system

cn flag
Comments are not for extended discussion; this conversation has been [moved to chat](https://chat.stackexchange.com/rooms/131448/discussion-on-answer-by-heynnema-failed-nvidia-graphics-driver-installation-ba).
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.