
If prompted, enter your admin username and password. Note that you may need to provide administrative privileges to complete the installation. Follow the on-screen instructions to complete the installation process.

Step 3: Run the InstallerĪfter you’ve downloaded the installer, double-click on the downloaded file to run it. Download the installer that matches your version of macOS. You can find the installer by searching for “Java for OS X 2015-001” on the Apple Support website. Once you’ve confirmed that you’re running a version of macOS that requires Legacy Java, you’ll need to download the installer from the Apple website. So it seems that the 1.6 JDK (or at least the JRE portion of it) may keep coming back, depending on other apps you use. Step 2: Download Legacy Java SE 6 Runtime Installer Afterward, the /System/Library/Frameworks/amework/Versions/CurrentJDK link was reset to /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents. UPDATE: After removing Java 1.6 from my machine, the next time I ran PhpStorm, it told me it needed to download and install the Java SE 6 runtime. Since that's where my new JDK is installed. It doesn't seem useful to leave CurrentJDK pointing to a non-existent directory, so I ran this command in the /System/Library/Frameworks/amework/Versions folder: sudo ln -sf /Library/Java/JavaVirtualMachines/jdk1.8.0_05.jdk/Contents CurrentJDK Lrwxr-xr-x 59 CurrentJDK -> /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents It's worth noting that /System/Library/Frameworks/amework contains a Versions folder, and at least in my case, that Versions folder contained: lrwxr-xr-x 10 1.4 -> CurrentJDK No modern version of OS X has a Java JDK inside there anyway. Those items are required by Java 7, 8, 9+ as well as Java SE 6. % sudo rm -rf /Library/Java/JavaVirtualMachines/1.6.0*.jdkĭo NOT remove any content in the amework (Note.: It under /System/Library/Frameworks/amework ) % sudo rm -rf /System/Library/Java/JavaVirtualMachines/1.6.0.jdk Remove the "system" JVM installed and maintained by Software Update However if you wish to rid your machine of Java SE 6,

The security issues are invariably sandbox violation tricks, and the standalone apps aren’t running Java sandboxed anyway. The security issues aren’t going to impact these apps. Java 6 is on your machine for legacy software that relies on it in standalone applications. But you can’t use Java 6 on the web anyway.

Security updates are important because of web sites that use Java maliciously. I don’t know the answer to your question, but I can suggest that you might be causing yourself unneeded problems.

From The macosx-port-dev Archives and How to properly uninstall Java 6 on OSX?:
