Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Some time ago I have installed Java Development Kit on Ubutu. I typed "sudo apt-get java" or something like that. After that got "java" and "javac" commands in my command line. Now I would like to uninstall this JDK. I tried to type "sudo apt-get remove java". And as the result I get "E: Couldn't find package java".

Could anybody, pleas, help me with that?

share|improve this question
up vote 3 down vote accepted

Try in a console "aptitude search jdk" and watch at the results.
You can spot a character on the far left of each line. If that character is an 'i' it means that the package is currenty installed on the system. Probably it will be something like "sun-java6-jdk" or "openjdk-6-jdk".
At that point you can do "sudo aptitude purge $1" where $1 is the name of the package you have found from the previous result list.

share|improve this answer
Be careful to only remove the JDK not all "java" as the JRE is required by many things. – Chris Nava Feb 18 '10 at 23:01

Have you tried using Synaptic Package Manager to locate the Java 'stuff' you want to remove?

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .