I've come to the following situations, where I prefer to explain my situation and get a proper set of steps/actions to make it work properly.
Info for my laptop:
System: Host: zutobg-Latitude-E6220 Kernel: 4.15.0-101-generic x86_64 bits: 64 Desktop: Gnome 3.28.4
Distro: Ubuntu 18.04.4 LTS
Machine: Device: laptop System: LENOVO product: 42844MG v: ThinkPad W520 serial: N/A
Mobo: LENOVO model: 42844MG serial: N/A UEFI [Legacy]: LENOVO v: 8BET62WW (1.42 ) date: 07/26/2013
Battery BAT0: charge: 60.8 Wh 100.0% condition: 60.8/56.2 Wh (108%)
CPU: Quad core Intel Core i7-2860QM (-MT-MCP-) cache: 8192 KB
clock speeds: max: 3600 MHz 1: 797 MHz 2: 799 MHz 3: 797 MHz 4: 796 MHz 5: 797 MHz 6: 797 MHz
7: 797 MHz 8: 798 MHz
Graphics: Card-1: Intel 2nd Generation Core Processor Family Integrated Graphics Controller
Card-2: NVIDIA GF106GLM [Quadro 2000M]
Display Server: x11 (X.Org 1.19.6 ) drivers: modesetting,nvidia (unloaded: fbdev,vesa,nouveau)
Resolution: 1920x1080@60.00hz
OpenGL: renderer: Mesa DRI Intel Sandybridge Mobile version: 3.3 Mesa 19.2.8
Audio: Card-1 NVIDIA GF106 High Definition Audio Controller driver: snd_hda_intel
Card-2 Intel 6 Series/C200 Series Family High Definition Audio Controller driver: snd_hda_intel
Sound: Advanced Linux Sound Architecture v: k4.15.0-101-generic
Network: Card-1: Intel 82579LM Gigabit Network Connection (Lewisville) driver: e1000e
IF: enp0s25 state: down mac: f0:de:f1:7a:da:2d
Card-2: Intel Centrino Ultimate-N 6300 driver: iwlwifi
IF: wlp3s0 state: up mac: 24:77:03:1a:14:f8
Drives: HDD Total Size: 1506.3GB (13.8% used)
ID-1: USB /dev/sda model: Expansion size: 1000.2GB
ID-2: /dev/sdb model: Crucial_CT250MX2 size: 250.1GB
ID-3: /dev/sdc model: Samsung_SSD_850 size: 256.1GB
Partition: ID-1: / size: 44G used: 14G (33%) fs: ext4 dev: /dev/sda6
ID-2: /home size: 336G used: 29G (10%) fs: ext4 dev: /dev/sda7
ID-3: swap-1 size: 5.24GB used: 0.00GB (0%) fs: swap dev: /dev/sda5
RAID: No RAID devices: /proc/mdstat, md_mod kernel module present
Sensors: System Temperatures: cpu: 57.0C mobo: N/A
Fan Speeds (in rpm): cpu: 2514
Info: Processes: 330 Uptime: 1:10 Memory: 2769.5/32051.1MB Client: Shell (bash) inxi: 2.3.56
So I have card-1 and card-2. Until recently I just used my machine for basic stuff, not playing games. I decided to explore Steam. Before that I haven't done anything in terms of VGA drivers or setup beside using Software & Updates program to select the driver on the top. Did it work properly back in the time - I don't know and it doesn't matter anymore.
So the game I wanted to play require Vulcan 3D API which
I said to myself, OK, i have Nvidia and I have a driver, so it should be OK.
But the game didn't start because of the Vulkan 3D API error. Then I tried to install vulkan-sdk which conclude in the following error
After that I reached a dozens pages through google to solve the issue and ofc a lot of commands happened. Here they are:
357 sudo apt-get update
358 sudo apt-get dist-upgrade
359 uname -r
360 steam -tcp
361 apt install meson libsystemd-dev pkg-config ninja-build git libdbus-1-dev libinih-dev
362 sudo apt install meson libsystemd-dev pkg-config ninja-build git libdbus-1-dev libinih-dev
363 ls
364 git clone https://github.com/FeralInteractive/gamemode.git
365 cd gamemode
366 git checkout 1.5.1
367 ./bootstrap.sh
368 sudo apt-get install python3 python3-pip python3-setuptools python3-wheel ninja-build
369 pip3 --version
370 nvidia-settings
371 which nvidia-smi
372 sudo prime-select nvidia
373 nvidia-settings
374 cd gamemode
375 ./bootstrap.sh
376 dpkg -l nvidia
377 sudo add-apt-repository ppa:graphics-drivers/ppa
378 sudo apt update
379 chmod +x NVIDIA-Linux-x86_64-440.82.run
380 ./NVIDIA-Linux-x86_64-440.82.run
381 sudo ./NVIDIA-Linux-x86_64-440.82.run
382 inxi -Fxz
383 sudo apt install inxi
384 inxi -Fxz
385 apt install vulcan-utils
386 sudo apt install vulcan-utils
387 wget -qO - http://packages.lunarg.com/lunarg-signing-key-pub.asc | sudo apt-key add -
388 sudo wget -qO /etc/apt/sources.list.d/lunarg-vulkan-1.1.106-bionic.list http://packages.lunarg.com/vulkan/1.1.106/lunarg-vulkan-1.1.106-bionic.list
389 sudo apt update
390 sudo apt install vulkan-sdk
391 sudo apt install libvulkan-dev
392 sudo apt install vulkan-sdk
393 sudo apt install libglm-dev cmake libxcb-dri3-0 libxcb-present0 libpciaccess0 libpng-dev libxcb-keysyms1-dev libxcb-dri3-dev libx11-dev g++ gcc g++-multilib libmirclient-dev libwayland-dev libxrandr-dev libxcb-ewmh-dev git python3 bison
394 sudo apt install vulkan-sdk
395 libvulkan-dev --version
396 sudo apt install vulkan-sdk
397 sudo apt update
398 sudo apt install vulkan-sdk
399 sudo apt install lunarg-vulkan-sdk
400 nvidia-settings
401 sudo apt-get purge nvidia*
402 ls
403 cd /etc/vulkan/
404 ls
405 cd icd.d/
406 ls
407 nvidia-settings
408 ls
409 cd Downloads/
410 ls
411 chmod +x NVIDIA-Linux-x86_64-396.18.run
412 sudo ./NVIDIA-Linux-x86_64-396.18.run
413 nvidia-settings
414 vulkaninfo
415 sudo apt install vulkan-utils
416 sudo apt install vulkan-sdk
417 vulkaninfo
418 tar xf vulkansdk-linux-x86_64-1.2.135.0.tar.gz
419 ls
420 cd Downloads/
421 ls
422 cd 1.2.135.0/
423 ls
424 source setup-env.sh
425 vulkaninfo
426 vulkaninfo --html
427 nvidia-settings
428 vkvia
429 sudo apt install vulkan-sdk
430 wget -qO - http://packages.lunarg.com/lunarg-signing-key-pub.asc | sudo apt-key add -
431 sudo wget -qO /etc/apt/sources.list.d/lunarg-vulkan-1.1.92-bionic.list http://packages.lunarg.com/vulkan/1.1.92/lunarg-vulkan-1.1.92-bionic.list
432 sudo apt update
433 sudo apt install vulkan-sdk
434 libvlkan-dev --version
435 sudo apt install glslang-tools
436 sudo apt install vulkan-sdk
437 sudo apt install libvulcan-dev
438 sudo apt install aptitude
439 sudo aptitude install lunarg-vulkan-sdk
440 vkcube
441 sudo apt install vulkan-sdk
442 sudo apt install mesa-vulkan-drivers
443 vkcube
444 sudo apt-get install -y libvulkan-dev
445 sudo apt install vulkan-sdk
446 vulkaninfo
447 nvidia-settings
448 vulkaninfo
449 vkcube
450 apt install vulkan-utils
451 sudoapt install vulkan-utils
452 sudo apt install vulkan-utils
453 sudo apt upgrade
454 sudo apt install nvidia-graphics-drivers-396 nvidia-settings vulkan vulkan-utils
455 vkcube
456 vulkaninfo
457 sudo apt install vulkan-sdk
458 dnf remove xorg-x11-drv-nvidia-340xx akmod-nvidia-340xx
459 nvidia-settings
460 sudo apt install vulkan-sdk
461 vulkaninfo
462 vkcube
463 sudo apt install vulkan-utils
464 sudo apt-get install -y libvulkan-dev
465 libvlkan-dev --version
466 vulkaninfo --html
467 export VULKAN_SDK=~/vulkan/1.1.xx.y/x86_64
468 export PATH=$VULKAN_SDK/bin:$PATH
469 export LD_LIBRARY_PATH=$VULKAN_SDK/lib:$LD_LIBRARY_PATH
470 export VULKAN_SDK=~/vulkan/1.1.xx.y/x86_64
471 export PATH=$VULKAN_SDK/bin:$PATH
472 export LD_LIBRARY_PATH=$VULKAN_SDK/lib:$LD_LIBRARY_PATH
473 export VK_LAYER_PATH=$VULKAN_SDK/etc/vulkan/explicit_layer.d
474 nvidia-settings
475 vulkaninfo --html
476 vkcube
477 vulkaninfo
478 sudo apt install vulkan-sdk
479 vulkaninfo
480 vkcube
481 nvidia-settings
482 apt-get install -f
483 sudo apt-get install -f
484 sudo apt upgrade
485 sudo apt-get install -f
486 sudo apt update --fix-missing
487 sudo apt install -f
488 sudo dpkg --configure -a
489 sudo dpkg -l | grep ^..r
490 sudo dpkg --remove --force-remove --reinstreq
491 sudo apt clean
492 sudo apt update
493 apt-get
494 nvidia-settings
495 apt-get install -f
496 sudo apt-get install -f
497 sudo apt autoremove
498 sudo apt --fix=broken install
499 sudo apt --fix-broken install
500 dpkg --configure -a
501 sudo dpkg --configure -a
502 sudo apt update
503 nvidia-settings
504 lspci | grep VGA
505 vkcube
506 vulkaninfo
507 inxi -Fxz
508 lspci | grep VGA
509 nvidia-smi
510 modinfo
511 vulkaninfo
512 nvidia-settings
Basically i tried so many things listed above, that in the end I get a broken Nvidia driver and broken package manager because of that.
Using the command nvidia-settings
I can reach my Nvidia driver click The command nvidia-smi
is showing click
But in order to play any game I need to switch my prime profile to be the intel one https://i.stack.imgur.com/BxMtd.png
Reboots is required.
Now ofc the commands nvidia-smi
is producing:
NVIDIA-SMI has failed because it couldn't communicate with the NVIDIA driver. Make sure that the latest NVIDIA driver is installed and running.
Beside of that I got a broken package manager:
https://i.stack.imgur.com/wVP99.png
https://i.stack.imgur.com/PW6R9.png
If I try to install a program I got:
zutobg@zutobg-Latitude-E6220:~$ sudo apt-get install hardinfo
[sudo] password for zutobg:
Reading package lists... Done
Building dependency tree
Reading state information... Done
You might want to run 'apt --fix-broken install' to correct these.
The following packages have unmet dependencies:
libnvidia-ifr1-390 : Depends: libnvidia-gl-390 but it is not going to be installed
libnvidia-ifr1-390:i386 : Depends: libnvidia-gl-390:i386 but it is not going to be installed
nvidia-driver-390 : Depends: libnvidia-gl-390 (= 390.132-0ubuntu0.18.04.1) but it is not going to be installed
Recommends: libnvidia-gl-390:i386 (= 390.132-0ubuntu0.18.04.1)
E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).
How I can fix all those added PPA, manual installed Nvidia over other driver and how to make it work.
Thank you for your help.
PS: some additional info from commands
zutobg@zutobg-Latitude-E6220:~$ cat /var/log/gpu-manager.log
log_file: /var/log/gpu-manager.log
last_boot_file: /var/lib/ubuntu-drivers-common/last_gfx_boot
new_boot_file: /var/lib/ubuntu-drivers-common/last_gfx_boot
can't access /run/u-d-c-nvidia-was-loaded file
can't access /opt/amdgpu-pro/bin/amdgpu-pro-px
Looking for nvidia modules in /lib/modules/4.15.0-101-generic/updates/dkms
Found nvidia module: nvidia.ko
Looking for amdgpu modules in /lib/modules/4.15.0-101-generic/updates/dkms
Is nvidia loaded? no
Was nvidia unloaded? no
Is nvidia blacklisted? yes
Is intel loaded? yes
Is radeon loaded? no
Is radeon blacklisted? no
Is amdgpu loaded? no
Is amdgpu blacklisted? no
Is amdgpu versioned? no
Is amdgpu pro stack? no
Is nouveau loaded? no
Is nouveau blacklisted? yes
Is nvidia kernel module available? yes
Is amdgpu kernel module available? no
Vendor/Device Id: 8086:126
BusID "PCI:0@0:2:0"
Is boot vga? yes
Vendor/Device Id: 10de:dda
BusID "PCI:1@0:0:0"
Is boot vga? no
Error: can't access /sys/bus/pci/devices/0000:01:00.0/driver
The device is not bound to any driver.
Skipping "/dev/dri/card0", driven by "i915"
Skipping "/dev/dri/card0", driven by "i915"
Skipping "/dev/dri/card0", driven by "i915"
Found "/dev/dri/card0", driven by "i915"
output 0:
card0-LVDS-1
Number of connected outputs for /dev/dri/card0: 1
Does it require offloading? yes
last cards number = 2
Has amd? no
Has intel? yes
Has nvidia? yes
How many cards? 2
Has the system changed? No
Intel IGP detected
Intel hybrid system
Removing /usr/share/X11/xorg.conf.d/11-nvidia-prime.conf
Setting power control to "auto" in /sys/bus/pci/devices/0000:01:00.0/power/control
zutobg@zutobg-Latitude-E6220:~$ uname -a
Linux zutobg-Latitude-E6220 4.15.0-101-generic #102-Ubuntu SMP Mon May 11 10:07:26 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
zutobg@zutobg-Latitude-E6220:~$ lspci -nnk |egrep -A3 -i "3D|VGA"
00:02.0 VGA compatible controller [0300]: Intel Corporation 2nd Generation Core Processor Family Integrated Graphics Controller [8086:0126] (rev 09)
Subsystem: Lenovo 2nd Generation Core Processor Family Integrated Graphics Controller [17aa:21d1]
Kernel driver in use: i915
Kernel modules: i915
--
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GF106GLM [Quadro 2000M] [10de:0dda] (rev a1)
Subsystem: Lenovo GF106GLM [Quadro 2000M] [17aa:21d1]
Kernel modules: nvidiafb, nouveau, nvidia_drm, nvidia
01:00.1 Audio device [0403]: NVIDIA Corporation GF106 High Definition Audio Controller [10de:0be9] (rev a1)
zutobg@zutobg-Latitude-E6220:~$ sudo lshw -C display
[sudo] password for zutobg:
*-display UNCLAIMED
description: VGA compatible controller
product: GF106GLM [Quadro 2000M]
vendor: NVIDIA Corporation
physical id: 0
bus info: pci@0000:01:00.0
version: a1
width: 64 bits
clock: 33MHz
capabilities: pm msi pciexpress vga_controller bus_master cap_list
configuration: latency=0
resources: iomemory:ffffffff0-fffffffef iomemory:ffffffff0-fffffffef memory:f0000000-f1ffffff memory:c0000000-cfffffff memory:d0000000-d3ffffff ioport:5000(size=128) memory:f2080000-f20fffff
*-display
description: VGA compatible controller
product: 2nd Generation Core Processor Family Integrated Graphics Controller
vendor: Intel Corporation
physical id: 2
bus info: pci@0000:00:02.0
version: 09
width: 64 bits
clock: 33MHz
capabilities: msi pm vga_controller bus_master cap_list rom
configuration: driver=i915 latency=0
resources: irq:38 memory:f2400000-f27fffff memory:e0000000-efffffff ioport:6000(size=64) memory:c0000-dffff
zutobg@zutobg-Latitude-E6220:~$ dpkg -l | grep -i nvidia
ii bbswitch-dkms 0.8-4ubuntu1 amd64 Interface for toggling the power on NVIDIA Optimus video cards
ii bumblebee 3.2.1-17 amd64 NVIDIA Optimus support for Linux
ii libnvidia-cfg1-390:amd64 390.132-0ubuntu0.18.04.1 amd64 NVIDIA binary OpenGL/GLX configuration library
ii libnvidia-common-390 390.132-0ubuntu0.18.04.1 all Shared files used by the NVIDIA libraries
ii libnvidia-compute-390:amd64 390.132-0ubuntu0.18.04.1 amd64 NVIDIA libcompute package
ii libnvidia-compute-390:i386 390.132-0ubuntu0.18.04.1 i386 NVIDIA libcompute package
ii libnvidia-decode-390:amd64 390.132-0ubuntu0.18.04.1 amd64 NVIDIA Video Decoding runtime libraries
ii libnvidia-decode-390:i386 390.132-0ubuntu0.18.04.1 i386 NVIDIA Video Decoding runtime libraries
ii libnvidia-encode-390:amd64 390.132-0ubuntu0.18.04.1 amd64 NVENC Video Encoding runtime library
ii libnvidia-encode-390:i386 390.132-0ubuntu0.18.04.1 i386 NVENC Video Encoding runtime library
ii libnvidia-fbc1-390:amd64 390.132-0ubuntu0.18.04.1 amd64 NVIDIA OpenGL-based Framebuffer Capture runtime library
ii libnvidia-fbc1-390:i386 390.132-0ubuntu0.18.04.1 i386 NVIDIA OpenGL-based Framebuffer Capture runtime library
iU libnvidia-ifr1-390:amd64 390.132-0ubuntu0.18.04.1 amd64 NVIDIA OpenGL-based Inband Frame Readback runtime library
iU libnvidia-ifr1-390:i386 390.132-0ubuntu0.18.04.1 i386 NVIDIA OpenGL-based Inband Frame Readback runtime library
ii nvidia-compute-utils-390 390.132-0ubuntu0.18.04.1 amd64 NVIDIA compute utilities
ii nvidia-dkms-390 390.132-0ubuntu0.18.04.1 amd64 NVIDIA DKMS package
iU nvidia-driver-390 390.132-0ubuntu0.18.04.1 amd64 NVIDIA driver metapackage
ii nvidia-kernel-common-390 390.132-0ubuntu0.18.04.1 amd64 Shared files used with the kernel module
ii nvidia-kernel-source-390 390.132-0ubuntu0.18.04.1 amd64 NVIDIA kernel source package
rc nvidia-opencl-icd-340 340.108-0ubuntu0.18.04.1 amd64 NVIDIA OpenCL ICD
ii nvidia-prime 0.8.8.2 all Tools to enable NVIDIA's Prime
ii nvidia-settings 440.64-0ubuntu0~0.18.04.1 amd64 Tool for configuring the NVIDIA graphics driver
ii nvidia-utils-390 390.132-0ubuntu0.18.04.1 amd64 NVIDIA driver support binaries
ii primus 0~20150328-6 amd64 client-side GPU offloading for NVIDIA Optimus
ii xserver-xorg-video-nvidia-390 390.132-0ubuntu0.18.04.1 amd64 NVIDIA binary Xorg driver
[sudo] password for zutobg:
Reading package lists... Done
Building dependency tree
Reading state information... Done
You might want to run 'apt --fix-broken install' to correct these.
The following packages have unmet dependencies:
libnvidia-ifr1-390:i386 : Depends: libnvidia-gl-390:i386 but it is not going to be installed
E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution). – zutobg May 31 '20 at 10:06
after that I did "sudo apt upgrade" and "sudo apt --fix-broken install" seen and modified from @ParsaMousavi suggested thread and help from linuxquestions forum. I'll see now what i can do for my Nvidia driver – zutobg May 31 '20 at 12:55