Why are upgradable packages not upgraded?
Solution 1:
You can run the command line below for upgrade all upgradable packages and their dependencies:
sudo apt-get dist-upgrade
Solution 2:
In this case “upgradable packages” are actually not upgradable because they have unmet dependencies.
To reproduce: try to update the specific packages in question (see How To Update A Specific Package In Ubuntu) by executing sudo apt-get install --only-upgrade <packagename>
. If any package has unmet dependencies, the upgrade will fail due to
E: Unable to correct problems, you have held broken packages.
Upgrading these packages would require to resolve the unmet dependencies. Information on that can be found in the answer to “How do I resolve unmet dependencies after adding a PPA?” and “Fixing Unable to correct problems, you have held broken packages”.
Solution 3:
I suggest running:
sudo apt-get upgrade
This worked for me. It will tell you how many packages it upgraded, how many new ones were installed, how many were deleted, and how many were not upgraded (kept back).
I had packages that were kept back, so after reading this post, which provides multiple solutions, I ran the following to install the packages that were kept back:
sudo apt-get --with-new-pkgs upgrade
This will also include which packages are no longer needed and could be removed. Per the output's instructions, I ran the following to remove them:
sudo apt autoremove
Lastly I ran the first code again, just to make sure all was clear and would get the output "0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded."