Recently I have been getting this warning icon on my top bar. Clicking on it tells me:
An error occurred, please run Package Manager from the right-click menu or apt-get in a terminal to see what is wrong. The error message was: 'Error: BrokenCount > 0.' This usually means that your installed packages have unmet dependencies.
When I run apt update
in a terminal, everything is fine and I get no errors. But when I run apt upgrade
or apt --fix-broken install
I get the following error message:
You might want to run 'apt --fix-broken install' to correct these.
The following packages have unmet dependencies:
openjdk-11-jdk-headless : Depends: openjdk-11-jre-headless (= 11~19-1~18.04) but 11~7-1ubuntu1 is installed
openjdk-11-jre : Depends: openjdk-11-jre-headless (= 11~19-1~18.04) but 11~7-1ubuntu1 is installed
E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).
I don't know how to fix the problem. I can not run updates and upgrades on the machine.
openjdk-11-jre-headless
. If that doesn't work: removeopenjdk-11-jre-headless
and doapt --fix-broken install
again.sudo apt remove openjdk-11-jre-headless
also brings up an error.`The following packages have unmet dependencies: default-jre-headless : Depends: openjdk-11-jre-headless but it is not going to be installed openjdk-11-jdk-headless : Depends: openjdk-11-jre-headless (= 11~19-1~18.04) but it is not going to be installed openjdk-11-jre : Depends: openjdk-11-jre-headless (= 11~19-1~18.04) but it is not going to be installed E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).