Howto remove Java?

Questions about applications and software
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
McCleod48

Howto remove Java?

Post by McCleod48 »

I've found Mint as a proper replacement for Ubuntu but I hit a setback in my effort to optimize the system.

My test-install is a Mint 13 MATE 32-bit (it's on my travelling-stick).

I'm trying to get rid of Java as I have absolutely no need for it what-so-ever. But I can't. If I remove the installed Java-support another Java-support gets installed in it's place. And if I remove that I get another one instead. Why can't I remove Java?
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
User avatar
xenopeek
Level 25
Level 25
Posts: 29459
Joined: Wed Jul 06, 2011 3:58 am

Re: Howto remove Java?

Post by xenopeek »

Because you have applications installed that require Java (like LibreOffice, which is a Java application). So if you uninstall it, the package manager will detect you would end up with a broken system and so installs another package to satisfy the dependencies.

I guess your concern would be mostly about Java in your browser, from security standpoint? You can easily remove Java from your browser with the following command:

Code: Select all

sudo apt-get --purge autoremove icedtea-*
This completely removes the IcedTea-Web Plugin from Firefox, making your browser free from Java and so not a target for Java based malware.
Image
McCleod48

Re: Howto remove Java?

Post by McCleod48 »

xenopeek wrote:Because you have applications installed that require Java (like LibreOffice, which is a Java application). So if you uninstall it, the package manager will detect you would end up with a broken system and so installs another package to satisfy the dependencies.

I guess your concern would be mostly about Java in your browser, from security standpoint? You can easily remove Java from your browser with the following command:

Code: Select all

sudo apt-get --purge autoremove icedtea-*
This completely removes the IcedTea-Web Plugin from Firefox, making your browser free from Java and so not a target for Java based malware.
I have removed LibreOffice. I do not use office-suites. And still I can't get rid of Java.

My concern is to remove every software package that I do not need and I do not need Java. I have been running Ubuntu for 5+ years without Java. I really do not need it.

Which packages depends upon Java?
McCleod48

Re: Howto remove Java?

Post by McCleod48 »

McCleod48 wrote: Which packages depends upon Java?
I found a tool: apt-rdepends

Give it an option '-r' it finds all packages depending upon a certain package.

And BTW. Only libreoffice-base depends on Java. You can have every part of Libre Office except Libre Office Base without having Java installed.

But thanks for reminding me on dependencies. :-)
User avatar
xenopeek
Level 25
Level 25
Posts: 29459
Joined: Wed Jul 06, 2011 3:58 am

Re: Howto remove Java?

Post by xenopeek »

With the following four commands I can completely remove Java from Linux Mint 13 MATE. Assuming you haven't added any applications to the default install of Linux Mint that require Java, this should work for you also.

Code: Select all

sudo apt-get --purge autoremove icedtea*
sudo apt-get --purge autoremove libreoffice*
sudo apt-get --purge autoremove openjdk*
sudo apt-get --purge autoremove java-common libservlet2.5-java libxerces2-java libxml-commons-external-java libxml-commons-resolver1.1-java tzdata-java
This removes all Java programs and libraries. It leaves Javascript libraries in place.
Image
User avatar
windyweather
Level 3
Level 3
Posts: 174
Joined: Wed Nov 09, 2011 8:34 pm
Location: Coos Bay, OR

How about just disable the IceTea plugin inside FireFox?

Post by windyweather »

Doesn't this work too? And much easier for those of us that are less command line oriented?

In FireFox - Menu Tools > Add Ons > Plugins Tab, then Disable IceTea.
Doesn't that disable the Java plugin in FireFox?
Someday, they might fix it. Or not. But that's easier than uninstalling it.

Works? Right?
Thanks,
ww
[Systems include LM 20 in VirtualBox / Win 10 Host on AMD Ryzen 3800x / AsRock A300 Ryzen 3200G]
meteorrock

Re: Howto remove Java?

Post by meteorrock »

This command here worked for me using Linux mint 14.1 with Mate.

Code: Select all

sudo apt-get purge openjdk*
If you want to get Java up and working, if you change your mind or looking for a Java that is working better on different browsers, check our thread down here about midway down. http://forums.linuxmint.com/viewtopic.php?f=42&t=122822

Image
Locked

Return to “Software & Applications”