2

after commands

sudo apt-get update
sudo apt-get upgrade

I try to refresh my nvidia driver with commands, but got error :

root@master-at-home:/opt/PhpStorm-242.24807.17/bin# sudo ubuntu-drivers devices
== /sys/devices/pci0000:00/0000:00:01.0/0000:01:00.0 ==
modalias : pci:v000010DEd00001341sv00001462sd00001112bc03sc02i00
vendor   : NVIDIA Corporation
model    : GM108M [GeForce 840M]
driver   : nvidia-driver-418-server - distro non-free
driver   : nvidia-driver-510 - distro non-free recommended
driver   : nvidia-driver-510-server - distro non-free
driver   : nvidia-driver-470 - distro non-free
driver   : nvidia-driver-470-server - distro non-free
driver   : nvidia-driver-450-server - distro non-free
driver   : nvidia-driver-390 - distro non-free
driver   : xserver-xorg-video-nouveau - distro free builtin

root@master-at-home:/opt/PhpStorm-242.24807.17/bin# ubuntu-drivers autoinstall Reading package lists... Done Building dependency tree... Done Reading state information... Done Some packages could not be installed. This may mean that you have requested an impossible situation or if you are using the unstable distribution that some required packages have not yet been created or been moved out of Incoming. The following information may help to resolve the situation:

The following packages have unmet dependencies: dpkg-dev : Depends: libdpkg-perl (= 1.21.1ubuntu2) but 1.21.1ubuntu2.3 is to be installed Recommends: build-essential but it is not going to be installed E: Unable to correct problems, you have held broken packages.

I try to fix the problem with next :

Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
0 upgraded, 0 newly installed, 0 to remove and 6 not upgraded.
root@master-at-home:/opt/PhpStorm-242.24807.17/bin# sudo aptitude -f install    libdpkg-perl
libdpkg-perl is already installed at the requested version (1.21.1ubuntu2.3)
libdpkg-perl is already installed at the requested version (1.21.1ubuntu2.3)
No packages will be installed, upgraded, or removed.
0 packages upgraded, 0 newly installed, 0 to remove and 6 not upgraded.
Need to get 0 B of archives. After unpacking 0 B will be used.

root@master-at-home:/opt/PhpStorm-242.24807.17/bin# sudo aptitude -f install build-essential The following NEW packages will be installed: build-essential{b} 0 packages upgraded, 1 newly installed, 0 to remove and 6 not upgraded. Need to get 4 744 B of archives. After unpacking 21,5 kB will be used. The following packages have unmet dependencies: build-essential : Depends: gcc (>= 4:10.2) but it is not installable Depends: g++ (>= 4:10.2) but it is not installable Depends: dpkg-dev (>= 1.17.11) but it is not installable The following actions will resolve these dependencies:

 Keep the following packages at their current version:
  1. build-essential [Not Installed]
    
    
    
    

Accept this solution? [Y/n/q/?] Y No packages will be installed, upgraded, or removed. 0 packages upgraded, 0 newly installed, 0 to remove and 6 not upgraded. Need to get 0 B of archives. After unpacking 0 B will be used.

But it did not help and I still got error :

root@master-at-home:/opt/PhpStorm-242.24807.17/bin# ubuntu-drivers autoinstall
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies: dpkg-dev : Depends: libdpkg-perl (= 1.21.1ubuntu2) but 1.21.1ubuntu2.3 is to be installed Recommends: build-essential but it is not going to be installed E: Unable to correct problems, you have held broken packages.

I used hints from branch Unable to correct problems, you have held broken packages

and next opened synaptic and several times I selected menu Edit -> Fix Broken Packages but nothing changed and button "Apply" is still disabled.

In my OS :

root@master-at-home:/opt/PhpStorm-242.24807.17/bin# uname -a
Linux master-at-home 6.8.0-49-generic #49~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Wed Nov  6 17:42:15 UTC 2 x86_64 x86_64 x86_64 GNU/Linux
root@master-at-home:/opt/PhpStorm-242.24807.17/bin# sudo lshw -numeric -C display
  *-display
       description: 3D controller
       product: GM108M [GeForce 840M] [10DE:1341]
       vendor: NVIDIA Corporation [10DE]
       physical id: 0
       bus info: pci@0000:01:00.0
       version: a2
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress bus_master cap_list rom
       configuration: driver=nouveau latency=0
       resources: irq:38 memory:f6000000-f6ffffff memory:e0000000-efffffff memory:f0000000-f1ffffff ioport:e000(size=128) memory:f7000000-f707ffff
  *-display
       description: VGA compatible controller
       product: 4th Gen Core Processor Integrated Graphics Controller [8086:416]
       vendor: Intel Corporation [8086]
       physical id: 2
       bus info: pci@0000:00:02.0
       logical name: /dev/fb0
       version: 06
       width: 64 bits
       clock: 33MHz
       capabilities: msi pm vga_controller bus_master cap_list rom fb
       configuration: depth=32 driver=i915 latency=0 resolution=1920,1080
       resources: irq:39 memory:f7400000-f77fffff memory:d0000000-dfffffff ioport:f000(size=64) memory:c0000-dffff

I can not select proper video driver in driver manager because of this error ...

Which step have I to take to fix this error ?

UPDATED # 1:

I run update commands without errors :

root@master-at-home:/opt/PhpStorm-242.24807.17/bin# sudo apt update
Hit:1 https://dl.google.com/linux/chrome/deb stable InRelease
Hit:2 https://deb.nodesource.com/node_18.x nodistro InRelease                                     
Hit:3 http://ua.archive.ubuntu.com/ubuntu jammy InRelease                                         
Hit:4 https://download.docker.com/linux/ubuntu jammy InRelease                      
Hit:5 https://deb.opera.com/opera-stable stable InRelease                           
Hit:6 https://ppa.launchpadcontent.net/giuspen/ppa/ubuntu jammy InRelease
Hit:7 https://ppa.launchpadcontent.net/ondrej/php/ubuntu jammy InRelease
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
6 packages can be upgraded. Run 'apt list --upgradable' to see them.
root@master-at-home:/opt/PhpStorm-242.24807.17/bin# sudo apt dist-upgrade
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Calculating upgrade... Done
Get more security updates through Ubuntu Pro with 'esm-apps' enabled:
  vlc-plugin-qt libvlc5 redis-server vlc-data python3-tornado libvlccore9
  libzbar0 libheif1 vlc imagemagick libavcodec-extra vlc-bin libjs-jquery-ui
  libpathplan4 vlc-l10n graphviz libavdevice58 libgvpr2 libgvc6 ffmpeg
  libopenexr25 libpostproc55 libcgraph6 libmagickcore-6.q16-6-extra
  vlc-plugin-samba libcdt5 php-twig libmagickwand-6.q16-6 libavcodec-extra58
  vlc-plugin-notify libavutil56 imagemagick-6.q16 libswscale5 redis-tools
  libeditorconfig0 libmagickcore-6.q16-6 vlc-plugin-access-extra
  vlc-plugin-skins2 vlc-plugin-video-splitter liblab-gamut1 libswresample3
  imagemagick-6-common vlc-plugin-video-output libavformat58 libde265-0
  libvlc-bin vlc-plugin-base vlc-plugin-visualization libavfilter7
Learn more about Ubuntu Pro at https://ubuntu.com/pro
#
# Patches available for the local privilege escalation issue in needrestart
# tracked by CVE-2024-48990, CVE-2024-48991, CVE-2024-48992, and CVE-2024-10224
# For more see: https://ubuntu.com/blog/needrestart-local-privilege-escalation
#
The following NEW packages will be installed:
  debsuryorg-archive-keyring
The following packages will be upgraded:
  php-common php8.4-cli php8.4-common php8.4-opcache php8.4-phpdbg php8.4-readline
6 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 5 314 kB of archives.
After this operation, 37,9 kB of additional disk space will be used.
Do you want to continue? [Y/n] Y
Get:1 https://ppa.launchpadcontent.net/ondrej/php/ubuntu jammy/main amd64 debsuryorg-archive-keyring all 2024.02.05+ubuntu22.04.1+deb.sury.org+1 [4 328 B]
Get:2 https://ppa.launchpadcontent.net/ondrej/php/ubuntu jammy/main amd64 php-common all 2:95+ubuntu22.04.1+deb.sury.org+1 [16,9 kB]
Get:3 https://ppa.launchpadcontent.net/ondrej/php/ubuntu jammy/main amd64 php8.4-readline amd64 8.4.2-1+ubuntu22.04.1+deb.sury.org+1 [13,7 kB]
Get:4 https://ppa.launchpadcontent.net/ondrej/php/ubuntu jammy/main amd64 php8.4-opcache amd64 8.4.2-1+ubuntu22.04.1+deb.sury.org+1 [467 kB]
Get:5 https://ppa.launchpadcontent.net/ondrej/php/ubuntu jammy/main amd64 php8.4-phpdbg amd64 8.4.2-1+ubuntu22.04.1+deb.sury.org+1 [2 017 kB]
Get:6 https://ppa.launchpadcontent.net/ondrej/php/ubuntu jammy/main amd64 php8.4-cli amd64 8.4.2-1+ubuntu22.04.1+deb.sury.org+1 [1 995 kB]
Get:7 https://ppa.launchpadcontent.net/ondrej/php/ubuntu jammy/main amd64 php8.4-common amd64 8.4.2-1+ubuntu22.04.1+deb.sury.org+1 [801 kB]
Fetched 5 314 kB in 5s (1 056 kB/s)      
Selecting previously unselected package debsuryorg-archive-keyring.
(Reading database ... 274447 files and directories currently installed.)
Preparing to unpack .../0-debsuryorg-archive-keyring_2024.02.05+ubuntu22.04.1+deb.sury.org+1_all.deb ...
Unpacking debsuryorg-archive-keyring (2024.02.05+ubuntu22.04.1+deb.sury.org+1) ...
Preparing to unpack .../1-php-common_2%3a95+ubuntu22.04.1+deb.sury.org+1_all.deb ...
Unpacking php-common (2:95+ubuntu22.04.1+deb.sury.org+1) over (2:92ubuntu1) ...
Preparing to unpack .../2-php8.4-readline_8.4.2-1+ubuntu22.04.1+deb.sury.org+1_amd64.deb ...
Unpacking php8.4-readline (8.4.2-1+ubuntu22.04.1+deb.sury.org+1) over (8.4.1-3+ubuntu22.04.1+deb.sury.org+1) ...
Preparing to unpack .../3-php8.4-opcache_8.4.2-1+ubuntu22.04.1+deb.sury.org+1_amd64.deb ...
Unpacking php8.4-opcache (8.4.2-1+ubuntu22.04.1+deb.sury.org+1) over (8.4.1-3+ubuntu22.04.1+deb.sury.org+1) ...
Preparing to unpack .../4-php8.4-phpdbg_8.4.2-1+ubuntu22.04.1+deb.sury.org+1_amd64.deb ...
Unpacking php8.4-phpdbg (8.4.2-1+ubuntu22.04.1+deb.sury.org+1) over (8.4.1-3+ubuntu22.04.1+deb.sury.org+1) ...
Preparing to unpack .../5-php8.4-cli_8.4.2-1+ubuntu22.04.1+deb.sury.org+1_amd64.deb ...
Unpacking php8.4-cli (8.4.2-1+ubuntu22.04.1+deb.sury.org+1) over (8.4.1-3+ubuntu22.04.1+deb.sury.org+1) ...
Preparing to unpack .../6-php8.4-common_8.4.2-1+ubuntu22.04.1+deb.sury.org+1_amd64.deb ...
Unpacking php8.4-common (8.4.2-1+ubuntu22.04.1+deb.sury.org+1) over (8.4.1-3+ubuntu22.04.1+deb.sury.org+1) ...
Setting up debsuryorg-archive-keyring (2024.02.05+ubuntu22.04.1+deb.sury.org+1) ...
Setting up php-common (2:95+ubuntu22.04.1+deb.sury.org+1) ...
Setting up php8.4-common (8.4.2-1+ubuntu22.04.1+deb.sury.org+1) ...
Setting up php8.4-opcache (8.4.2-1+ubuntu22.04.1+deb.sury.org+1) ...
Setting up php8.4-readline (8.4.2-1+ubuntu22.04.1+deb.sury.org+1) ...
Setting up php8.4-cli (8.4.2-1+ubuntu22.04.1+deb.sury.org+1) ...
Setting up php8.4-phpdbg (8.4.2-1+ubuntu22.04.1+deb.sury.org+1) ...
Processing triggers for man-db (2.10.2-1) ...
Processing triggers for php8.4-cli (8.4.2-1+ubuntu22.04.1+deb.sury.org+1) ...
Processing triggers for php8.4-phpdbg (8.4.2-1+ubuntu22.04.1+deb.sury.org+1) ...

But checking autoinstall I still got errors :

root@master-at-home:/opt/PhpStorm-242.24807.17/bin# ubuntu-drivers autoinstall
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies: dpkg-dev : Depends: libdpkg-perl (= 1.21.1ubuntu2) but 1.21.1ubuntu2.3 is to be installed Recommends: build-essential but it is not going to be installed E: Unable to correct problems, you have held broken packages.

I try full-upgrade command :

root@master-at-home:/opt/PhpStorm-242.24807.17/bin# sudo apt full-upgrade
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Calculating upgrade... Done
Get more security updates through Ubuntu Pro with 'esm-apps' enabled:
  vlc-plugin-qt libvlc5 redis-server vlc-data python3-tornado libvlccore9
  libzbar0 libheif1 vlc imagemagick libavcodec-extra vlc-bin libjs-jquery-ui
  libpathplan4 vlc-l10n graphviz libavdevice58 libgvpr2 libgvc6 ffmpeg
  libopenexr25 libpostproc55 libcgraph6 libmagickcore-6.q16-6-extra
  vlc-plugin-samba libcdt5 php-twig libmagickwand-6.q16-6 libavcodec-extra58
  vlc-plugin-notify libavutil56 imagemagick-6.q16 libswscale5 redis-tools
  libeditorconfig0 libmagickcore-6.q16-6 vlc-plugin-access-extra
  vlc-plugin-skins2 vlc-plugin-video-splitter liblab-gamut1 libswresample3
  imagemagick-6-common vlc-plugin-video-output libavformat58 libde265-0
  libvlc-bin vlc-plugin-base vlc-plugin-visualization libavfilter7
Learn more about Ubuntu Pro at https://ubuntu.com/pro
#
# Patches available for the local privilege escalation issue in needrestart
# tracked by CVE-2024-48990, CVE-2024-48991, CVE-2024-48992, and CVE-2024-10224
# For more see: https://ubuntu.com/blog/needrestart-local-privilege-escalation
#
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

Still the same error:

root@master-at-home:/opt/PhpStorm-242.24807.17/bin# ubuntu-drivers autoinstall
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies: dpkg-dev : Depends: libdpkg-perl (= 1.21.1ubuntu2) but 1.21.1ubuntu2.3 is to be installed Recommends: build-essential but it is not going to be installed E: Unable to correct problems, you have held broken packages.

UPDATED # 2 :

I check contents of the files :

sudo nano /etc/apt/sources.list :

deb cdrom:[Kubuntu 22.04.3 LTS Jammy Jellyfish - Release amd64 (20230807.1)]/ jammy main multiverse restricted universe

See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to

newer versions of the distribution.

deb http://ua.archive.ubuntu.com/ubuntu/ jammy main restricted

deb-src http://ua.archive.ubuntu.com/ubuntu/ jammy main restricted

Major bug fix updates produced after the final release of the

distribution.

deb-src http://ua.archive.ubuntu.com/ubuntu/ jammy-updates main restricted

N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu

team. Also, please note that software in universe WILL NOT receive any

review or updates from the Ubuntu security team.

deb http://ua.archive.ubuntu.com/ubuntu/ jammy universe

deb-src http://ua.archive.ubuntu.com/ubuntu/ jammy universe

deb-src http://ua.archive.ubuntu.com/ubuntu/ jammy-updates universe

N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu

team, and may not be under a free licence. Please satisfy yourself as to

your rights to use the software. Also, please note that software in

multiverse WILL NOT receive any review or updates from the Ubuntu

security team.

deb http://ua.archive.ubuntu.com/ubuntu/ jammy multiverse

deb-src http://ua.archive.ubuntu.com/ubuntu/ jammy multiverse

deb-src http://ua.archive.ubuntu.com/ubuntu/ jammy-updates multiverse

N.B. software from this repository may not have been tested as

extensively as that contained in the main release, although it includes

newer versions of some applications which may provide useful features.

Also, please note that software in backports WILL NOT receive any review

or updates from the Ubuntu security team.

deb-src http://ua.archive.ubuntu.com/ubuntu/ jammy-backports main restricted universe multiverse

deb-src http://security.ubuntu.com/ubuntu jammy-security main restricted

deb-src http://security.ubuntu.com/ubuntu jammy-security universe

deb-src http://security.ubuntu.com/ubuntu jammy-security multiverse

This system was installed using small removable media

(e.g. netinst, live or single CD). The matching "deb cdrom"

entries were disabled at the end of the installation process.

For information about how to configure apt package sources,

see the sources.list(5) manual.

and

root@master-at-home:/etc/apt/sources.list.d# ls -la
total 48
drwxr-xr-x 2 root root 4096 січ  9 13:57 .
drwxr-xr-x 8 root root 4096 січ 10 15:07 ..
-rw-r--r-- 1 root root  110 гру 23 17:35 docker.list
-rw-r--r-- 1 root root  142 гру  8 14:32 giuspen-ubuntu-ppa-jammy.list
-rw-r--r-- 1 root root  142 гру  8 14:32 giuspen-ubuntu-ppa-jammy.list.save
-rw-r--r-- 1 root root  190 гру  8 14:32 google-chrome.list
-rw-r--r-- 1 root root  190 гру  8 14:32 google-chrome.list.save
-rw-r--r-- 1 root root  113 гру  8 14:32 nodesource.list
-rw-r--r-- 1 root root  113 гру  8 14:32 nodesource.list.save
-rw-r--r-- 1 root root  140 гру  8 14:32 ondrej-ubuntu-php-jammy.list
-rw-r--r-- 1 root root  140 гру  8 14:32 ondrej-ubuntu-php-jammy.list.save
-rw-r--r-- 1 root root  187 січ  9 13:57 opera-stable.list

In my KDE I have discover and Synaptic and I found in it :

enter image description here

Not shure which Software & Updates GUI do you mean ? Is it some special program I need to install?

karel
  • 122,292
  • 133
  • 301
  • 332
mstdmstd
  • 199

1 Answers1

2

You seem to have a dependency conflict, check that you have main, universe, restricted, multiverse, jammy-updates and jammy-security in /etc/apt/sources.list /etc/apt/sources.list.d/ like

deb http://archive.ubuntu.com/ubuntu jammy main restricted universe multiverse
deb http://archive.ubuntu.com/ubuntu jammy-updates main restricted universe multiverse
deb http://archive.ubuntu.com/ubuntu jammy-backports main restricted universe multiverse
deb http://security.ubuntu.com/ubuntu jammy-security main restricted universe multiverse

and in the Software & Updates GUI check that main, restricted, universe, and multiverse are enabled

update:

your /etc/apt/sources.list should be like this:

deb http://ua.archive.ubuntu.com/ubuntu jammy main restricted universe multiverse
deb http://ua.archive.ubuntu.com/ubuntu jammy-updates main restricted universe multiverse
deb http://ua.archive.ubuntu.com/ubuntu jammy-backports main restricted universe multiverse
deb http://security.ubuntu.com/ubuntu jammy-security main restricted universe multiverse

so you need to add or uncomment ( remove the # at the begining ) some of these lines

then we save and execute these commands:

sudo apt update
sudo apt dist-upgrade

And now you should be able to do ubuntu-drivers autoinstall

then you can install your NVIDIA driver without the mismatch

Saxtheowl
  • 2,394
  • 2
  • 12
  • 22