In order to know the Java HOME Path on your Mac, you can execute the java_home command-line utility available on macOS under /usr/libexec/
Example:
Code2care@Mac % /usr/libexec/java_home
/Users/c2ctech/Library/Java/JavaVirtualMachines/openjdk-20/Contents/Home
As you can see that my Java HOME is set to be that of OpenJDK-20 (i.e. Java JDK 20)

Using this path you can get into the bin folder and have access to the path of all java related executable files.
Code2care@Mac % cd bin
Code2care@Mac % ls
jar jcmd jhsdb jpackage jstatd
jarsigner jconsole jimage jps jwebserver
java jdb jinfo jrunscript keytool
javac jdeprscan jlink jshell rmiregistry
javadoc jdeps jmap jstack serialver
javap jfr jmod jstat
-
Facing issues? Have Questions? Post them here! I am happy to answer!
More Posts related to MacOS,
- How to Display Analog Clock on Mac Menu Bar
- Shutdown Mac Terminal Command
- How to know the Serial Number of MacBook on macOS Ventura 13.0
- macOS: Remove Desktop or Documents Folder from iCloud Drive Syncing
- [fix] How to Show file extensions on all files on Mac
- How to install Zoom Add-in to Outlook (Mac)
- How to turn off Stage Manager - macOS Ventura
- Fix - Xode - Internal logic error: Connection was invalidated
- How to do calculations in Mac Terminal
- How to delete a Page in Microsoft Word File on Mac (macOS)
- How to Refresh Mac Desktop
- How to install Java on macOS [Big Sur]
- How to Disable Mac Terminal Bell Sound
- Installing MongoDB on Linux/Unix/macOS/Ubuntu
- How to Uninstall Brew on Mac
- Find your macOS version
- Change TextEdit File Encoding
- AppleScript Example with TextEdit
- How to install homebrew (brew) on M1 Mac
- How to Find File and Directory Size in Mac Terminal
- How to open new tab in Sublime Text Editor [macOS]
- How to list all users in Mac Terminal
- Turn off Auto-Capitalization on macOS Ventura 13
- How to check Command Line Tools Version [Updated for Ventura]
- Change Current User Password using Mac Terminal Command
More Posts:
- How to Convert a Java Object into an Optional with Example - Java
- What is FCM Messages Test Notification! [Microsoft Teams] [Google Hangouts] - Microsoft
- Python: NumPy Concatenate Arrays Example - Python
- Python 3.x : How to Convert String to Bytes - Python
- [fix] macOS Ventura xcrun: error: invalid active developer path missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun - MacOS
- How to Enable Cookies in Safari on Mac - MacOS
- How to check if a String contains substring or a word using javaScript - JavaScript
- Graph API error when querying BookingBusinesses - ErrorExceededFindCountLimit, The GetBookingMailboxes request returned too many results - Microsoft