Questions tagged [apt]
APT is short for Advanced Packaging Tool, the package manager for Debian-based distributions. It is also the most used tool for installing packages in Ubuntu. Questions about using any of the apt commands should use this tag.
17,495
questions
2620
votes
25
answers
5.2m
views
How to list all installed packages
I'd like to output a list of all installed packages into a text file so that I can review it and bulk-install on another system. How would I do this?
1694
votes
29
answers
1.8m
views
"The following packages have been kept back:" Why and how do I solve it?
I just added a PPA repository for the development version of the GIMP, but I get this error:
$ apt-get update && apt-get upgrade
...
The following packages have been kept back:
gimp gimp-...
1623
votes
27
answers
2.0m
views
How can PPAs be removed?
I've added many PPAs using the add-apt-repository command. Is there a simple way to remove these PPAs? I've checked in /etc/apt/sources.list for the appropriate deb lines but they aren't there.
This ...
1171
votes
25
answers
3.6m
views
Unable to lock the administration directory (/var/lib/dpkg/) is another process using it?
I get this error when trying to use apt-get:
E: Could not get lock /var/lib/dpkg/lock - open (11 Resource temporarily unavailable)
E: Unable to lock the administration directory (/var/lib/dpkg/) is ...
1115
votes
19
answers
2.5m
views
How can I update my nodeJS to the latest version?
I have installed nodeJS on Ubuntu with following code
sudo apt-get install nodejs
Since I am a new user for ubuntu I also ran this code too
sudo apt-get install npm
Now when I type
nodejs --...
1071
votes
7
answers
1.2m
views
How to upgrade a single package using apt-get?
How do I update a single package? As far as man apt-get says apt-get upgrade doesn't take a package/list of packages as parameter:
upgrade
upgrade is used to install the newest versions of all ...
877
votes
9
answers
2.3m
views
How do I search for available packages from the command-line?
I have successfully installed some packages using the command:
sudo apt-get install packagename
when I have known in advance that those packages are available. But how can I search for or get a list ...
876
votes
9
answers
2.7m
views
How to install updates via command line?
When I log into my web server via SSH I see the information:
88 packages can be updated.
80 updates are security updates
I tried apt-get update then apt-get upgrade but each time I log in I still ...
815
votes
4
answers
539k
views
What is the difference between apt and apt-get?
I read about the new fancy progress bar which was added to apt 1.0 in Softpedia and how to enable it here. However on running sudo apt-get update, I did not see the fancy progress bars. On reading the ...
702
votes
9
answers
2.1m
views
What does "sudo apt-get update" do?
I am wondering what sudo apt-get update does?
What does it update?
667
votes
14
answers
1.4m
views
How do I resolve unmet dependencies after adding a PPA?
Occasionally, when I'm installing stuff, I get an error like the following:
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the ...
614
votes
15
answers
1.2m
views
How do I fix the GPG error "NO_PUBKEY"?
I added some extra repositories with the Software Sources program. But when I reload the package database, I get an error like the following:
W: GPG error: http://ppa.launchpad.net trusty InRelease:...
560
votes
2
answers
712k
views
What is the difference between apt-get update and upgrade?
What is the difference between apt-get update and apt-get upgrade?
Which should I run first?
Do any of them automatically run the other?
540
votes
6
answers
853k
views
What is "dist-upgrade" and why does it upgrade more than "upgrade"?
I was wondering why upgrade sometimes doesn't want to upgrade certain parts of the system, while dist-upgrade does. Here's an example after running apt-get upgrade:
apt-get upgrade:
rimmer@rimmer-...
451
votes
9
answers
1.1m
views
How do I install Python 3.6 using apt-get?
I've tried the normal way, sudo apt-get install python3.6, but... well... that didn't work.
So, how would I go about it? (I'd preferably not build it on my own)
I'm using Ubuntu 16.04.
449
votes
22
answers
452k
views
Trouble downloading packages list due to a "Hash sum mismatch" error
When I check for updates, I get a "Failed To Download Repository Information" error.
This is what comes up under details:
W: Failed to fetch gzip:/var/lib/apt/lists/partial/us.archive.ubuntu....
435
votes
5
answers
702k
views
How can I see all versions of a package that are available in the archive?
Is there a way I can see all the versions that are in the archives that I have configured in sources.list. I can see the last version of each archive withapt-get policy, but how can I see them all?
...
430
votes
6
answers
816k
views
How to downgrade a package via apt-get?
How can I downgrade a package to an older version via apt-get?
Other tools are also acceptable but apt-get is preferred.
404
votes
5
answers
342k
views
How can I accept the Microsoft EULA agreement for ttf-mscorefonts-installer?
After a recent update, ttf-mscorefonts-installer prompted me to accept its license agreement.
┌─────────────────┤ Configuring ttf-mscorefonts-installer ├─────────────────┐
│ ...
382
votes
10
answers
387k
views
How do I fix a "Problem with MergeList" or "status file could not be parsed" error when trying to do an update?
The computer gave me this output in a window:
E: Encountered a section with no Package: header
E: Problem with MergeList /var/lib/apt/lists/archive.ubuntu.com_ubuntu_dists_natty_main_binary-...
374
votes
16
answers
1.5m
views
Unable to correct problems, you have held broken packages
After upgrading from 10.04 to 12.04 I am trying to install different packages.
For instance ia32-libs and skype (4.0).
When trying to install these, I am getting the 'Unable to correct problems, you ...
356
votes
7
answers
2.9m
views
"Unable to locate package" while trying to install packages with APT
When I try to install any package through the command line, I get an error.
$ sudo apt-get install <package>
Reading package lists... Done
Building dependency tree
Reading state ...
331
votes
2
answers
91k
views
Dwarf Fortress starting during apt-get upgrade
When I run apt-get upgrade on my Ubuntu 17.04 machine, sometimes it starts Dwarf Fortress by itself.
It has happened already at least two times, so it was probably not just some sort of one time ...
330
votes
20
answers
256k
views
How to list manually installed packages?
I'd like to get a list of packages installed manually by apt or aptitude and be able to find out whether a foobar package was installed manually or automatically.
How can we do that from the command ...
317
votes
9
answers
355k
views
Skipping acquire of configured file 'main/binary-i386/Packages' as repository 'xxx' doesn't support architecture 'i386'
Getting below error message while issuing :
sudo apt-get update
Get:1 http://us.archive.ubuntu.com/ubuntu xenial InRelease [95.8 kB]
Ign:2 http://repo.mongodb.org/apt/debian wheezy/mongodb-org/3.2 ...
314
votes
9
answers
749k
views
How can I fix a 404 Error when using a PPA or updating my package lists?
PPA seems to be constantly offline. Whenever I use sudo apt-get update, this error is shown:
W: Failed to fetch http://ppa.launchpad.net/ 404 Not Found
How do I fix these errors?
302
votes
5
answers
210k
views
Avoiding user interaction with tzdata when installing certbot in a docker container
I want to install certbot in a docker environment with an Ubuntu 16.04 image:
For example:
docker run -it ubuntu:16.04 /bin/bash
When I'm inside the container, the most straightforward way to ...
297
votes
8
answers
402k
views
How can I fix apt error "W: Target Packages ... is configured multiple times"?
I just installed Ubuntu Gnome 16.04. I told it to save my documents - which worked. Some software had to be reinstalled. Now when I run sudo apt-get update I see this:
W: Target Packages (main/binary-...
292
votes
8
answers
246k
views
How do I find out which repository a package comes from?
Is there a method or command which can tell from which repository a package is coming from?
280
votes
3
answers
559k
views
What is the Difference Between `apt-get purge` and `apt-get remove`?
Is there any difference between
sudo apt-get purge <package-name>
and
sudo apt-get remove <package-name>
?
I often see people recommend one or the other.
In other words, what ...
277
votes
3
answers
505k
views
Error sudo: add-apt-repository: command not found
I’m running Ubuntu 14.04. When I run:
sudo add-apt-repository ppa:ubuntu-wine/ppa
I get the following error:
sudo: add-apt-repository: command not found
I tried to run
sudo apt-get install ...
270
votes
4
answers
720k
views
E: Could not get lock /var/lib/dpkg/lock-frontend - open (11: Resource temporarily unavailable)
I'm trying to run this command in the terminal:
sudo apt install software-properties-common
This is the error message I get:
E: Could not get lock /var/lib/dpkg/lock-frontend - open (11: Resource ...
243
votes
12
answers
626k
views
How to uninstall LibreOffice?
Which package should I remove to completely remove libreoffice? I have no need for office tools.
That's the one gripe I have with package managers like apt, there's no simple way to perform the ...
240
votes
9
answers
226k
views
Is it possible to get a list of most recently installed packages?
Is it possible to get a list of packages that were most recently installed through apt-get?
237
votes
8
answers
319k
views
How can I remove gpg key that I added using apt-key add -?
I don't need the key in my server's keyring anymore. Is it possible to remove it? I added the key using this command:
curl http://repo.varnish-cache.org/debian/GPG-key.txt | apt-key add -
Thanks ...
234
votes
8
answers
359k
views
How can I get apt to use a mirror close to me, or choose a faster mirror?
Downloading from the main Ubuntu archive is slow even when it's not release day, how can I get apt-get to automatically use a mirror that is close to me?
232
votes
17
answers
1.2m
views
apt-get update fails to fetch files, “Temporary failure resolving …” error
Err http://archive.canonical.com natty InRelease
Err http://security.ubuntu.com oneiric-security InRelease
Err http://extras.ubuntu.com natty InRelease
...
232
votes
11
answers
593k
views
How do I install a different Python version using apt-get?
How can I install a different version of Python using apt-get?
Obviously I realise I can install using the source tar ball, however I would prefer not to install from source and instead use the ...
225
votes
4
answers
106k
views
Why is Ubuntu moving to Snap packages?
Why Ubuntu dumping .deb packages and moving to .snap packages?
At least for now they are keeping .deb package for normal distributions. .deb is already the most popular packaging format out there.
...
223
votes
6
answers
469k
views
Installed Teamviewer using a 64-bit system, but I get a dependency error
I was trying to install Teamviewer, but I was getting a dependency error. I tried to install the required packages, but with no luck.
I'm getting this error:
Unpacking teamviewer (from ...
222
votes
2
answers
265k
views
What is difference between the options "autoclean", "autoremove" and "clean"?
apt-get has a few options which looks the same to me: autoclean, autoremove and clean. What do each of them do?
217
votes
23
answers
377k
views
sudo apt update error: "Release file is not yet valid"
I keep getting this error every time I try to sudo apt update:
Hit:1 ubuntu bionic InRelease
Ign:3 linux/chrome/deb stable InRelease
Get:2 /ubuntu bionic-updates InRelease [88.7 kB]...
205
votes
7
answers
233k
views
Where can I look up my update history?
Is there a place where I can look what updates I've installed?
203
votes
5
answers
742k
views
What can I do if a repository/PPA does not have a Release file?
When updating, I get the following error message:
W: The repository 'http://ppa.launchpad.net/mc3man/trusty-media/ubuntu xenial Release' does not have a Release file.
Here, I find another statement ...
201
votes
3
answers
279k
views
How do I get details about a package which isn't installed?
How can I get some details about a package without installing it, (eg. the description and version number) like in Synaptic or Aptitude. The command
dpkg -s PACKAGE
does not work, with this error. ...
201
votes
2
answers
285k
views
29 packages can be updated - How? [duplicate]
I see the following message when I login:
29 packages can be updated.
6 updates are security updates.
How can I perform the updates?
I tried apt-get upgrade and some stuff was installed but the ...
200
votes
6
answers
253k
views
dpkg error: "trying to overwrite file, which is also in..."
For example:
$ sudo apt-get install curl
Reading package lists... Done
Building dependency tree
Reading state information... Done
You might want to run 'apt-get -f install' to correct these:
The ...
200
votes
6
answers
215k
views
How do I get and modify the source code of packages installed through apt-get?
I am assuming that all application installed through apt-get are open source; but for those that are available in that manner, where can I get the source code for these applications as well as update ...
199
votes
6
answers
239k
views
Why am I getting authentication errors for packages from an Ubuntu repository?
I'm experimenting with VPNs, so I wanted to install pptpd.
john@desktop:~$ sudo apt-get install pptpd
[sudo] password for john:
<snip>
The following extra packages will be installed:
bcrelay
...
199
votes
6
answers
110k
views
Is aptitude still considered superior to apt-get?
When I first started with Ubuntu using aptitude was the 'in-thing', with some stated improvements over apt-get. Am I correct in saying that apt-get has now 'caught up' with aptitude, and it makes ...