Selecting or installing mhwd driver profile blocked by package

Difficulty: ★☆☆☆☆

If you are attempting to change driver selection through Manjaro Settings Manager or mhwd and you receive a message similar to

error: failed to prepare transaction (could not satisfy dependencies)
:: removing XXXXX breaks dependency 'xxxxx' required by nnnnn
Error: pacman failed!
Error: script failed!

then there are 2 things to keep in mind.

  1. It is usually easier to install a new profile than attempting to remove one first.
    (especially if is a related upgrade, such as nvidia-440xx > nvidia-450xx)

  2. Any blocking packages, especially ‘umbrella’ packages such as ‘linux-latest’ can be removed temporarily.

Realistic example

$ sudo mhwd -i pci video-hybrid-intel-nvidia-450xx-prime

Removing video-hybrid-intel-nvidia-440xx-prime…
Sourcing /etc/mhwd-x86_64.conf
Has lib32 support: true
Sourcing /var/lib/mhwd/local/pci/video-hybrid-intel-nvidia-440xx-prime/MHWDCONFIG
Processing classid: 0300
Sourcing /var/lib/mhwd/scripts/include/0300
checking dependencies…
error: failed to prepare transaction (could not satisfy dependencies)
:: removing linux57-nvidia-440xx breaks dependency ‘linux57-nvidia-440xx’ required by linux-latest-nvidia-440xx
Error: pacman failed!
Error: script failed!

So the proper procedure would be:

$ sudo pacman -R linux-latest-nvidia-440xx
$ sudo mhwd -i pci video-hybrid-intel-nvidia-450xx-prime

NOTES

  1. Dont forget about the ‘force’ (-f) flag which can be useful. Example:
    $ sudo mhwd -f -i pci video-hybrid-intel-nvidia-450xx-prime

  2. If you experience a bug where mhwd hangs or fails after a message similar to
    Dependencies to install: video-modesetting
    Proceed with installation? [Y/n]
    Then check for and install the profile dependency through mhwd. Example:
    $ sudo mhwd -i pci video-modesetting

  3. To use all of the above together, as shown by recent upgrades to 450xx-prime. Example:
    $ sudo pacman -R linux-latest-nvidia-440xx
    $ sudo mhwd -i pci video-modesetting
    $ sudo mhwd -f -i pci video-hybrid-intel-nvidia-450xx-prime


Helpful Links:
https://wiki.manjaro.org/index.php?title=Configure_Graphics_Cards

14 Likes

Hi, I followed all the steps but the same error are popping.

checking dependencies…
error: failed to prepare operation (could not satisfy dependencies)
:: removing nvidia-440xx-utils breaks dependency «nvidia-utils», required by nvidia-prime
Error: pacman failed!
Error: script failed!

I’m new to Manjaro, I need to remove the nvidia-prime, and then use the command?

yes that would work.
Its possible in your case that you might have been able to remove the original profile through mhwd, or to just use the force flag for the newer selection.
But also removing the blocking package(s) first would certainly work - and if you are trying to install another PRIME profile you will get them (ex - nvidia-prime) right back and reinstalled anyways.

1 Like

Yes! It work, thank you very much!!!

Thank you so much! Updating the video driver from video-hybrid-intel-nvidia-440xx-prime to video-hybrid-intel-nvidia-455xx-prime with that solution worked fine now!

Since the last Manjaro upgrade I’ve had very big power consumption (about 22 watt on my Dell XPS 15). After upgrading the video driver it’s down at about 2 to 3 watt.