Questions tagged as ['apt']

Questions about using any of the apt tools should use this tag. Advanced Packaging Tool, the package manager for Debian-based distributions. It is also the most used tool for installing packages in Ubuntu.
Score: 0
user241990 avatar
sudo apt-get update failed to Cannot initiate the connection to, where able to perform apt-get update root
cn flag

Am using ubuntu 20.04, where using proxy to connect internet.

Able to perform "apt-get update" as "root"

where not able to perform "apt-get update" && apt-get install vnc" as non-root user with sudo prefix

Score: 0
El Señor Gato avatar
Problems updating Kubuntu 20.04.02 Focal Fossa - Many error messages
lb flag

I have a problem updating my system. For some reason error messages are being displayed in Spanish even though I don't use it.

This is the error message what I got in terminal

E: El repositorio «cdrom://Kubuntu LTS _Focal Fossa_ - Release amd64 (20210209.1) focal Release» no tiene un fichero de Publicación.
N: No se puede actualizar de un repositorio como este de forma segura y por tanto  ...
Score: 0
Hannah Schmidt avatar
E: Sub-process /usr/bin/dpkg returned an error code (1) won't leave me alone :'(
sz flag

so... i've spent the past 7 hours of my life trying to update my pc, i fell into an abyss of confusing jargon i don't understand. i've tried everything i can handle trying without being put in a hospital and soon being interviewed for a netflix documentary on how i went insane and my story.

basically.... I try to run 'sudo apt --fix-broken install' as that is what the terminal tells me to do ever ...

Score: 0
jake avatar
Setting up grub-efi-amd64-signed error in apt install
in flag

I followed the uninstall and reinstall commands in but whenever I do sudo apt install <program> I'm still getting the below error:

Setting up grub-efi-amd64-signed (1.167~18.04.5+2.04-1ubuntu44.1.2) ...
Installing for x86_64-efi platform.
grub-install: error: cannot find EFI directory.
dpkg: error processing package grub-efi-amd64-signed (--configure): ...
Score: 1
How to fix Sublime Text PPA in Ubuntu 20.04?
dz flag
$ sudo apt update && sudo apt upgrade -y
Hit:1 focal InRelease
Hit:2 focal-updates InRelease                                                                                    
Hit:3 focal-backports InRelease                                                                             ...
Score: 0
JHLinux avatar
KDE with Ubuntu 20.04
au flag

I have installed kde on my Ubuntu installation trough sudo apt install kde-full, but I still have some question about updates, is there any issue removing Ubuntu desktop from it using sudo apt remove ubuntu-desktop ubuntu-software software-properties-gtk nautilus update-manager gnome-system-monitor? And what about new upgrades, for example, when Ubuntu 22.04 launch, will it upgrade just fine? Do I ...

Score: 2
Shubham Deshmukh avatar
Is shim a redundant package that is never used, compared to shim-signed?
jp flag

I did sudo apt-get autoremove --purge to free up some space, however it also removed the latest shim package that got updated just today.

shim (15.4-0ubuntu7)

also updated today was

shim-signed (15.4-0ubuntu7)

but shim-signed was NOT removed.

If autoremove removes older versions no longer required, however I believe shim is an essential element for secure boot process, or is it not? Please help me ...

Score: 0
can't upgrade a package... it wants to delete everything
pg flag

I get "The following packages have been kept back"

sudo apt upgrade
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Calculating upgrade... Done
The following packages have been kept back:
  libgbm1:i386 libgl1-mesa-dri:i386 libglapi-mesa:i386 libglx-mesa0:i386
  libosmesa6:i386 mesa-vulkan-drivers:i386
0 upgraded, 0 newly installed, 0 to remove and 6 ...
Score: 1
Andyc avatar
Still can't install Wine in Ubuntu 20.04
es flag

I know this question has at least half a dozen with a similar title, but none of those answers or comments help me. So here we go:

I tried to follow the instructions on the Wine Wiki. When I did

sudo dpkg --add-architecture i386

the command returned to the prompt with no error, so I assumed the architecture was added successfully. I added the repository as instructed, and then I did:

sudo apt update ...

Score: 0
Diorcula avatar
How to fix: dpkg: Warning: Files list file for package nodejs-doc missing?
ma flag

So i completely removed Nodejs by running file manager as Root and deleting every search hit for "nodejs". ' After i installed NodeJs again i get the following warning everytime:

dpkg: warning: files list file for package 'nodejs-doc' missing; assuming package has no files
 currently installed
(Reading database ... 228170 files and directories currently installed.)

How do i get the nodejs-doc files li ...

Score: 0
Rekkhan avatar
Get stuck with expired key of a removed package
es flag

After accidentally switching my repository, I got the

failed to download repository information error from Software Updater.

I tried to do

$ sudo apt-get  update

And found that I have an expired key for stable InRelease. (Which I believe belong to skypeforlinux) I uninstall and reinstall skypeforlinux, then revert the repository. Now skypeforlinux has completely gone from  ...

Score: 0
Michur55 avatar
Getting dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem
jp flag

While trying to use apt-get install, I'm getting this error dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem.


When I'm trying to fix it and use dpkg --configure -a, system is freezing on this message


Score: 0
Time Lord TCS avatar
Unable to upgrade from 18.04 to 20.04.2
sr flag

I can't for the life of me figure out how or what to remove or install to fix this upgrade, here is the output from grep Broken /var/log/dist-upgrade/apt.log:

Broken dpkg:amd64 Breaks on libapt-pkg5.0:amd64 < 1.6.14 @ii mK > (< 1.7~b)
Broken libqt5core5a:amd64 Breaks on libqtcore4:amd64 < 4:4.8.7+dfsg-7ubuntu1 @ii mK > (< 4:4.8.7+dfsg-20~)
Broken libgcc1:amd64 Conflicts on libgcc1:i386  ...
Score: 2
Brainz80 avatar
Trying to update ubuntu-minimal on WSL2 running Ubuntu 20.04.2 LTS
th flag

When trying to update ubuntu-minimal I get the following error:

Reading package lists... Done
Building dependency tree
Reading state information... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
2 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Setting up ubuntu-advantage-tools (27.2.1~20.04.1) ...
ERROR: File not found '/run/cl ...
Score: 0
Rad avatar
Broken apt sources list?
fo flag

I am trying to do boot-repair using try Ubuntu from live disc. I need to do apt commands, however I keep getting:

Media change: please insert the disc labeled
 'Ubuntu 21.04 _Hirsute Hippo_ - Release amd64 (20210420)'
in the drive '/cdrom/' and press [Enter]

I have seen a solution about removing cdrom entries from /etc/apt/sources.list, so I did. Now my lists are only 4 active entries, none is cdro ...

Score: 0
elysium avatar
-Could not exec dpkg! E: Sub-process /usr/bin/dpkg returned an error code (100) (08-01-2021)
us flag

I was trying to download Visual Base to Ubuntu 21.04; before actually download, I tried to run sudo apt-get update, it showed there are 4 upgradable n, I ran sudo apt-get dist-upgrade

it downloads the packages but fails to install, it threw an error as the title indicated. Now, I realized I cannot install VB, or any other software, or even update the packages to that matter.

How do I fix this and downlo ...

Score: 0
Xaphann avatar
Cannot install YUM on WSL
lc flag

I am trying to install yum to install another app on my WSL but keep getting the error cannot find the package. I am using the following command:

sudo apt install -y yum

It is returning this:

Reading package lists... Done

Building dependency tree

Reading state information... Done

E: Unable to locate package yum

Search the net I keep seeing to update the apt so I am using this:

 sudo apt updat ...
Score: 0
“Unable to locate package” after a crash installing other package with apt-get
ua flag

After a crash installing java with apt-get, I was trying to install maven, but apt wasn't finding:

> sudo apt-get install maven
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package maven

Already tried everything described here: "Unable to locate package" while trying to install packages with APT

But nothing helped, I found a solutio ...

Score: 0
Taufiq avatar
Unable to Switch back to running desktop mode from TTY in 18.04
tz flag

Tried following thing but did not work. Any help is highly appreciated.


sudo dpkg --configure -a
sudo apt-get update
sudo apt-get upgrade -y
sudo reboot
sudo apt-get update
sudo apt-get install --reinstall ubuntu-desktop
sudo apt-get install unity
sudo shutdown -r now
Score: 0
ile avatar
Updating Ubuntu when /boot partition is almost full
gs flag

My /boot partition is 500M in size, as I thought it would be enough when I did the installation. It seems it isn't.

Now it's almost full

/dev/sda1               446M  352M   61M  86% /boot

Doing apt-get upgrade doesn't succeed:

update-initramfs: Generating /boot/initrd.img-5.11.0-25-generic
Error 24 : Write error : cannot write compressed block 
E: mkinitramfs failure cpio 141 lz4 -9 -l 24
update-in ...
Score: 3
Manuel Jordan avatar
Why did "E: dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem" appear?
kz flag

For Ubuntu Desktop 18:04 for update I use:

  • sudo apt update
  • sudo apt upgrade

But suddenly for the latter now arises:

E: dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem

So executing that command I got:

sudo dpkg --configure -a
dpkg: dependency problems prevent configuration of linux-generic-hwe-18.04:
 linux-generic-hwe-18.04 depends on linux-headers-generi ...
Score: 0
WebLab - group avatar
Can't install anything after installing dde on ubuntu 20.04
gb flag
user@host:~$ sudo apt install iverilog 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
iverilog is already the newest version (10.3-1build1).
0 upgraded, 0 newly installed, 0 to remove and 12 not upgraded.
1 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
Setting up deepin-any ...
Score: 0
dinaradenis avatar
Error When Update To Hirsute Hippo
eg flag

I Want To Update My System From Focal Fossa ( LTS ) To Hirsute Hippo ( Normal ), But I Found Some Error :

root@localhost:~# do-release-upgrade
Checking for a new Ubuntu release
Get:1 Upgrade tool signature [819 B]
Get:2 Upgrade tool [1268 kB]
Fetched 1269 kB in 0s (0 B/s)
authenticate 'hirsute.tar.gz' against 'hirsute.tar.gz.gpg'
extracting 'hirsute.tar.gz'

Reading cache
lspci: /sys/bus/pci/device ...
Score: 1
elakhdar_ayoub avatar
missing packages error in wine installation
it flag

i'm trying to install wine the latest version using the following command

sudo apt install --install-recommends winehq-stable

but i faced some missing packages issues, so i tried to fix it through the command:

sudo apt install --install-recommends --fix-missing winehq-stable

even with that still unable to get the missed packages and i keep getting this error:

    Unable to correct missing packa ...
Score: 1
Stopping services from being restarted as a result of dist-upgrade replacing a dependency
my flag

Running Ubuntu Server 18.04

I believe I've encountered the following situation, and would like to stop it from occurring again.

The situation:

1/ I've put docker on hold with apt mark. This is confirmed with I do sudo apt upgrade --simulate, it correctly states:

The following packages have been kept back: docker-ce docker-ce-cli

2/ Someone performs sudo apt dist-upgrade. This causes a sha ...

Score: 0
TheMeaningfulEngineer avatar
Install a specific version of an older package by adding an old mirror
cn flag

I'm attempting to install a specific version of gcc to Ubuntu 18.04.

By default the version of Ubuntu at the time of this writing is 18.04.5. Installing it with sudo apt-get install gcc-7 results in the following:

user@server:~$ gcc-7 -v
gcc version 7.5.0 (Ubuntu 7.5.0-3ubuntu1~18.04) 
user@server:~$ sudo apt-cache policy gcc-7
  Installed: 7.5.0-3ubuntu1~18.04
  Candidate: 7.5.0-3ubuntu1~18.04
Score: 0
SureAns Incorporation avatar
Postfix exit code 75
pk flag

When I want to update or upgrade anything. or can install any kinks of software. The terminal shows this message "1 not fully install or remove". and installing process stops:

0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
**1 not fully installed or removed.**
After this operation, 0 B of additional disk space will be used.

Finally this error message is shown, and installing or updatin ...

Score: 0
paulhector avatar
Restoring [K]Ubuntu 20.04 after removing Python with apt-get
br flag

TLDR: I need to restore my distro after sudo removing all Python dependencies

I did the stupid thing and now I need to fix it. I wanted to do a clean install of Python for a class, uninstalling all programs that I installed using the command our teacher gave us (basically, remplacing apt-get install in the line he gave us to install Python with apt-get remove). So I ran the following:

sudo apt-get  ...

Score: 0
Ikrame Ounadi avatar
sudo apt update doesn't work in my ubuntu 19.04?
ke flag

It does this everytime i update anything ,i cant do anything , please help

E: The repository ' disco Release' does not have a Release file. N: Updating from such a repository can't be done securely, and is therefore disabled by default. N: See apt-secure(8) manpage for repository creation and user configuration details. E: The reposito ...

Score: 13
user37216 avatar
Why does Vim in Ubuntu 20.04 require Python 3?
tv flag

I'm using Docker, and my dockerfile is:

FROM ubuntu:20.04

WORKDIR /opt/test

# Apt installs
RUN apt update


If I build and run the container, and then run the following, it asks to install python3-minimal, and Python dependencies:

$ docker run -it ubuntu-test
root@3a13a90d3e86:/opt/test#  ...