I am using Ubuntu Server.
When I do:
apt-get upgrade
it gets stuck on:
Setting up openjdk-6-jre-headless (6b20-1.9.7-0ubuntu1) ...
Why? And what can I do to stop it?
I tried removing it with apt-get... I get this error:
E: dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem.
So then I tried this:
dpkg --purge openjdk-6-jre-headless
I got this:
dpkg: dependency problems prevent removal of openjdk-6-jre-headless:
openjdk-6-jre-lib depends on openjdk-6-jre-headless (>= 6b17).
ca-certificates-java depends on openjdk-6-jre-headless (>= 6b16-1.6.1-2) | java6-runtime-headless; however:
Package openjdk-6-jre-headless is to be removed.
Package java6-runtime-headless is not installed.
Package openjdk-6-jre-headless which provides java6-runtime-headless is to be removed.
ca-certificates-java depends on openjdk-6-jre-headless (>= 6b16-1.6.1-2) | java6-runtime-headless; however:
Package openjdk-6-jre-headless is to be removed.
Package java6-runtime-headless is not installed.
Package openjdk-6-jre-headless which provides java6-runtime-headless is to be removed.
dpkg: error processing openjdk-6-jre-headless (--purge):
dependency problems - not removing
Errors were encountered while processing:
openjdk-6-jre-headless
The thing is I think my DB is using it... Not sure... I am using Cassandra with Thrift...
Yes, it's getting a bit more complex...
# dpkg --configure -a
I get:
dpkg: dependency problems prevent configuration of openjdk-6-jre:
openjdk-6-jre depends on openjdk-6-jre-headless (>= 6b20-1.9.7-0ubuntu1); however:
Package openjdk-6-jre-headless is not configured yet.
dpkg: error processing openjdk-6-jre (--configure):
dependency problems - leaving unconfigured
Processing triggers for libc-bin ...
ldconfig deferred processing now taking place
dpkg: dependency problems prevent configuration of libaccess-bridge-java:
libaccess-bridge-java depends on default-jre | openjdk-6-jre | sun-java6-jre; however:
Package default-jre is not installed.
Package openjdk-6-jre is not configured yet.
Package sun-java6-jre is not installed.
dpkg: error processing libaccess-bridge-java (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of icedtea-6-jre-cacao:
icedtea-6-jre-cacao depends on openjdk-6-jre-headless (= 6b20-1.9.7-0ubuntu1); however:
Package openjdk-6-jre-headless is not configured yet.
dpkg: error processing icedtea-6-jre-cacao (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of libaccess-bridge-java-jni:
libaccess-bridge-java-jni depends on libaccess-bridge-java (>= 1.26.2-5); however:
Package libaccess-bridge-java is not configured yet.
dpkg: error processing libaccess-bridge-java-jni (--configure):
dependency problems - leaving unconfigured
Errors were encountered while processing:
openjdk-6-jre
libaccess-bridge-java
icedtea-6-jre-cacao
libaccess-bridge-java-jni
Thanks again for any help.
I've had little upgrade problems like this before.
two possibilities, try:
then
Failing that, try
Then
then
Cassandra is a Java application and depending on which version you are running it requires different Java packages. In the past it has required openjdk but I believe the newer version will accept sunJDK. You have to have one of them for it to work.
dpkg -C
will audit your system for misconfigured or non-functioning packages, then recommend a solution.You should try manually removing the top of the dependency tree, too: have you tried to remove
ca-certificates-java
? If that remove fails, you can remove its requirer, and so on and so forth.As a last resort: If you run
dpkg
with the--force-depends
flag, all dependency errors automagically turn into warnings. Thereby allowing you to hose your system, of course; use with caution. Certainly include the--dry-run
option first to check that what's being done is what you want.