Mhwd -a pci nonfree 0300 - fails

I installed the latest 21.2 without the Nvidia drivers, a mistake I will admit that.
But tomorrow my most Linux sceptic is coming to celebrate Christmas, so now is my chance to change his mind. And the top of his list is games!
So I do really need the Nvidia drivers installed.
A quick search and I found this link over at Manjaro wiki and was happy that all it needed was:

sudo mhwd -a pci nonfree 0300

But to my disappointment it fails, with:

> Using config 'video-nvidia' for device: 0000:01:00.0 (0300:10de:1f08) Display controller nVidia Corporation TU106 [GeForce RTX 2060 Rev. A]
> Installing video-nvidia...
Sourcing /etc/mhwd-x86_64.conf
Has lib32 support: true
Sourcing /var/lib/mhwd/db/pci/graphic_drivers/nvidia/MHWDCONFIG
Processing classid: 0300
Sourcing /var/lib/mhwd/scripts/include/0300
Processing classid: 0302
:: Synchronizing package databases...
 core downloading...
 extra downloading...
 community downloading...
 multilib downloading...
error: target not found: linux513-nvidia
Error: pacman failed!
Error: script failed!

I do see why, linux513 isn’t valid in my system, I am running this kernel, after an update:

5.15.7-1-MANJARO

So what do I have to do to fix this?

Hi @macmattias, and welcome!

That’s probably because you still have 5.13 installed. Not using, maybe, but still installed.

Please post the output to:

mhwd-kernel --listinstalled

so we can check.

2 Likes

Thanks for a lighting fast reply! And you’re on to something. :slight_smile:
Here is the output:

Currently running: 5.15.7-1-MANJARO (linux515)
The following kernels are installed in your system:
   * linux513
   * linux515

Yes, it would seem kernel 5.13 is still installed. Make sure you’re booted into 5.15 and remove 5.13:

mhwd-kerrnel --remove linux513

And then reboot and see if it works.

Edit:

And it’s a good idea to have 2 kernels installed. So install 5.10, which is also LTS, also:

mhwd-kernel --install linux510
3 Likes

Your problem because you initially ran Manjaro with Linux kernel 5.13 and the proprietary NVDIA driver for kernel 5.13 didn’t exist in the remote (mirror) repository.

I assume you just freshly installed Manjaro, got updates notification, performed updates. What you need to do is to reboot your PC and choose Manjaro with Linux 5.15 in the advanced option of the GRUB interface.

Then just run sudo mhwd -a pci nonfree 0300 again and it will install NVDIA proprietary driver for Linux 5.15.

You can also use the GUI in settings to install open-source and proprietary graphics drivers as well as Linux kernels instead of via terminal.

You actually don’t need to remove kernel 5.13, since you will run the latest kernel version 5.15. But you can just remove version 5.13 since you cannot install proprietary graphics driver with that kernel version.

But, also follow @Mirdarthos suggestion to keep 2 kernels, one the 5.10 LTS and the new 5.15. So if you cannot boot Manjaro with kernel 5.15, you can try boot with 5.10 LTS.

That command is not installed for me, should I install it or should I just use the GUI tool?
I used the GUI tool. :slight_smile:
So now:

> Successfully installed video-nvidia

You can either spell mhwd-kernel correctly or use the GUI. :wink:

1 Like

You read me totally correct. :slight_smile:
Yes a reinstall of Manjaro due that I switched disk for it to a doubled size and 3 times faster.

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.