An error occurred, please run Package Manager from the right-click menu or apt-get in a teminal to see what is wrong. The error message was :'Error:BrokenCount>0'. This usually means that your installed packages have unment dependences
is usually encountered by Ubuntu Linux users, mostly when upgrading systems packages or the whole system to higher versions. As the message suggests, there might be bad repositories. The obvious solution is either to remove the bad repositories or all except the default ones. To do so run
Code: Select all
gksu software-properties-gtk
This will open the software sources dialog
Click on "Other Software" and remove all third party repositories, and thereafter, run the commands below
Code: Select all
sudo apt-get update && sudo apt-get install -f && sudo apt-get update
or
Code: Select all
sudo apt-get update && sudo apt-get -f install && sudo apt-get update
See if the problem has been solved.
If the the method above does not work, try the one below.
Update package repositories:
Code: Select all
sudo apt-get update
Clean if any broken ones, the downloaded packages:
Code: Select all
sudo apt-get clean
The system may suggest to remove the broken packages or unneeded or some packages that are needed but their dependencies or such have been removed leaving them orphan. In this case, execute
Code: Select all
sudo apt-get autoremove
Please use the command above with care.
Reconfigure packages:
Code: Select all
sudo dpkg --configure -a
Fix broken packages:
Code: Select all
sudo apt-get install -f
If the solutions above do not work, try this one: Remove the sources list and update packages again:
Code: Select all
sudo rm -vf /var/lib/apt/lists/*
-v, --verbose explain what is being done
-f, --force ignore nonexistent files and arguments, never prompt
Update the packages:
Code: Select all
sudo apt-get update
There is no guarantee the above solutions will work, if that is the case try to run the command:
Code: Select all
sudo apt-get install –fix-broken
Problem not solved? Last but not least, try to update and upgrade packages, problematic packages may be removed and replaced with their upgrades:
Code: Select all
sudo apt-get update && sudo apt-get upgrade
During all these trials, you may solve one problem and cause another one. The most likely problems are addressed below.
Unity and/or gnome desktop disappearing
In this case your system menu/gnome desktop may disappear, you can neither access/open the Terminal by Ctrl + Alt + T nor by any other graphical means.
Fix this by opening the tty terminal as follows:
Code: Select all
Ctrl + Alt + F1 (Try F1 - F6)
Enter your username and password, and then
Code: Select all
sudo apt-get purge unity #Remove old unity
sudo apt-get install unity #Install unity
After the commands above, you may see the Unity Dash and use Terminal, but the color of the Terminal may change from purple to black, copying into Terminal may not be possible and you may not be able to open the system menu and/or perform any GUI task. To alleviate all these problems, execute:
Code: Select all
sudo apt-get install ubuntu-desktop
Finally you may consider to upgrade your system to the newest stable version, for example, from Ubuntu Linux 14.04 to 16.04.
Another possible error, especially, after upgrading is:
W: Target Packages (universe/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list:15 and /etc/apt/sources.list:52
W: Target Packages (universe/binary-i386/Packages) is configured multiple times in /etc/apt/sources.list:15 and /etc/apt/sources.list:52
W: Target Packages (universe/binary-all/Packages) is configured multiple times in /etc/apt/sources.list:15 and /etc/apt/sources.list:52
W: Target Translations (universe/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list:15 and /etc/apt/sources.list:52
W: Target Translations (universe/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list:15 and /etc/apt/sources.list:52
W: Target Translations (universe/i18n/Translation-en_ZA) is configured multiple times in /etc/apt/sources.list:15 and /etc/apt/sources.list:52
W: Target DEP-11 (universe/dep11/Components-amd64.yml) is configured multiple times in /etc/apt/sources.list:15 and /etc/apt/sources.list:52
W: Target DEP-11-icons (universe/dep11/icons-64x64.tar) is configured multiple times in /etc/apt/sources.list:15 and /etc/apt/sources.list:52
You can get rid of this error by reseting your repositories as follows (see other options)
Code: Select all
$sudo rm /etc/apt/sources.list #Backup in case something goes wrong
$sudo software-properties-gtk
Select your options
Save
$sudo apt-get update