To use the “java” command-line tool you need to install a JDK.

Pls help from the pop up of "To use the “java” command-line tool you need to install a JDK."

it is very much annoying. even through downloaded the java JDK. still problem continues.

please help me to sort out.

MacBook Air 13", macOS 10.15

Posted on Nov 15, 2019 6:52 AM

Reply
Question marked as Top-ranking reply

Posted on Nov 15, 2019 7:22 AM

We can’t help. You must research, troubleshoot, and solve this yourself. You or somebody with access to this Mac has installed something that needs Java. Some app that tries to start or to restart periodically. Some app dependent on Oracle Java. Which means you must find that app, and must then decide to either keep that app and install and properly configure the JDK, or to remove it all and that including the app.


The following command-line command will find most apps that use Java:


sudo find / -type f -iname *.jar


Launch Terminal.app, issue that command, and enter an admin password for the sudo.


There’s almost certainly also a launch agent here, which is what is attempting to invoke the Java-using app directly or maybe via a script.


Of course a fair amount of what’s posted for this error is “well, install Java”, which usually suppresses the error—if it’s the expected JDK, amd properly confiugred—and whatever here will then hopefully start doing whatever, and stop logging this annoying error. But if you’re not using this stuff, get rid of it. (Not the least of which because parts of recent Java can require a commercial license, and can require payments to Oracle, if not (re)configured to avoid using the part of the Java code that requires the commercial license.)

1 reply
Question marked as Top-ranking reply

Nov 15, 2019 7:22 AM in response to RafeequeAk

We can’t help. You must research, troubleshoot, and solve this yourself. You or somebody with access to this Mac has installed something that needs Java. Some app that tries to start or to restart periodically. Some app dependent on Oracle Java. Which means you must find that app, and must then decide to either keep that app and install and properly configure the JDK, or to remove it all and that including the app.


The following command-line command will find most apps that use Java:


sudo find / -type f -iname *.jar


Launch Terminal.app, issue that command, and enter an admin password for the sudo.


There’s almost certainly also a launch agent here, which is what is attempting to invoke the Java-using app directly or maybe via a script.


Of course a fair amount of what’s posted for this error is “well, install Java”, which usually suppresses the error—if it’s the expected JDK, amd properly confiugred—and whatever here will then hopefully start doing whatever, and stop logging this annoying error. But if you’re not using this stuff, get rid of it. (Not the least of which because parts of recent Java can require a commercial license, and can require payments to Oracle, if not (re)configured to avoid using the part of the Java code that requires the commercial license.)

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

To use the “java” command-line tool you need to install a JDK.

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.