They offer different flash templates with latest features.
Login

Forgot password
Register
Back
Written by:
Alexio
Score: 14
votes: 22
Format: Article

 How to fix broken packages using the Command Line


Using aptitude for package management instead of apt-get, please note that it is bad practice to use aptitude and apt-get interchangeably, as they record separately the changes made by a user.

 

Open the Terminal from the Mint Menu and start with the commands:

sudo aptitude update && sudo aptitude install gtkorphan

The && is used to run the second command if the first command runs successfully.

 

Continue by running:

sudo aptitude update && sudo aptitude upgrade

This is used to double-check that you have all the updates.

 

To clear out the broken packages use the command:

sudo aptitude -f

It brings up a beautiful interface to search, navigate, install, update and otherwise to manage packages.

Use the commands on the screen to install all the updates. You may use the mouse or CTRL + T to open the menu. Also, you could use the arrow keys and the Enter key to navigate.

You can also install the Aptitude Package Manager if you want to use something like Synaptic. Just type aptitude-gtk in the search field of the Mint Menu and click on Install package 'aptitude-gtk'. You can then find it under the Administration menu.

 

You may also use other commands to:

  • install software for your system, with needed dependencies as well:
sudo aptitude install
  • remove packages as well as orphaned dependencies:
sudo aptitude remove
  • remove packages and orphaned dependencies, as well as any configuration files left behind:   
sudo aptitude purge
  • search for packages in the local apt package lists:
sudo aptitude search package-name
  • show details about a package:
sudo aptitude show package-name
  • update the local packages lists:
sudo aptitude update
  • upgrade any installed packages that have been updated:
sudo aptitude upgrade
  • upgrade packages, even if it means uninstalling certain packages:
sudo aptitude dist-upgrade
  • delete only out-of-date packages, but keep current ones:
sudo aptitude autoclean
  • delete any downloaded files necessary for installing the software on your system:
sudo aptitude clean
  • fix a package at it’s current version, and don’t update it:
sudo aptitude hold

 

Recommended reading: Aptitude vs Apt-Get


Tags: CLI aptitude fix broken packages
Created: 3 years ago.
Last edited: 3 years ago.
Reviewed: 3 years ago.
Read 1680 times.

Comments
2 days ago

k-9s
Thank you, this was very helpful  
9 months ago

linux1492
This article rules!!! Thanks so much. Well done.  
1 year ago

ssj_satish
Nice article. Solved the problem, I was hunting for 3 days.
Thanks a lot.
 
1 year ago

pathavlicek
right on aptitude  
1 year ago

jaredchu
sudo aptitude -f

this command removed all my package, when i come back my computer return black screen and nothing in there...
 
3 years ago

blueXrider
Good information.  
3 years ago

remoulder
I didn't say your post was an idea, following your instructions is not a good idea. It may well have worked for you but you probably understand what you are doing. An inexperienced user doing this could cause themselves problems.  
3 years ago

Alexio
This is a tutorial and not an idea :) It worked well for me and for others when Synaptic was not able to fix the broken packages. It is possible to install a nice front-end to aptitude called "aptitude-gtk".  
3 years ago

remoulder
This is not a good idea, users should understand what is causing the broken packages, not just force a fix or they could end up removing needed software. Besides imo, it is easier to see what is going on using synaptic rather than aptitude.  

Other tutorials from Alexio