Even though JRE 8 is installed on my MAC OS Yosemite 10.10.3,while running the Android present in tools in sdk - the error - " No Java Runtime present,requesting to install " gets displayed in terminal- how do i solve this issue?
I wanted to install Xamarin test recorder - after installing they asked me to install Android sdk
SDK is downloaded in Library/Developer/Xamarin/android-sdk
Now when I run Android present in tools folder - I get the error - No Java run time
I've installed JRE 8 with get the verified java version from their site
Can someone please help!!
Below is worked for me on macos mojave 10.14.6 version
I installed current jdk(https://www.oracle.com/java/technologies/javase-downloads.html)
Then do respectively;
it is done. And you can check the version with java -version command.
Since it sounds like your JAVA_HOME variable is not set correctly, follow the instructions for setting that.
Setting JAVA_HOME environment variable on MAC OSX 10.9
I would imagine once you set this, it will stop complaining.
To handle this problem in a clean way, I suggest to use brew
and jenv
.
JAVA_VERSION=11
brew reinstall jenv
brew reinstall openjdk@${JAVA_VERSION}
jenv add /usr/local/opt/openjdk@${JAVA_VERSION}/
jenv global ${JAVA_VERSION}
~/.bashrc
or ~/.zshrc
export PATH="$HOME/.jenv/bin:$PATH"
eval "$(jenv init -)"
export JAVA_HOME="$HOME/.jenv/versions/`jenv version-name`"
Then restart your shell and try to execute java -version
Note: If you have this problem, your current JDK version is not existent or misconfigured (or may be you have only JRE).
In newer versions of OS X (especially Yosemite, EL Capitan), Apple has removed Java support for security reasons. To fix this you have to do the following.
Mount the disk image file and install Java 6 runtime for OS X.
After this you should not be seeing any of the below messages:
- Unable to find any JVMs matching version "(null)"
- No Java runtime present, try --request to install.
If you came across the error when tried to generate a jks file (keystore), so try adding
/Applications/Android\ Studio.app/Contents/jre/jdk/Contents/Home/bin/keytool
before running the command, like so:
/Applications/Android\ Studio.app/Contents/jre/jdk/Contents/Home/bin/keytool -genkey -v -keystore ~/key.jks -keyalg RSA -keysize 2048 -validity 10000 -alias key
I have Mojave 10.14.6 and the only thing that did work for me was:
export JAVA_HOME=/Library/Internet\ Plug-Ins/JavaAppletPlugin.plugin/Contents/Home
Hope it helps! You can now type java --version
and it should work
install JDK it will work ,
here is the jdk link to download .
link: https://www.oracle.com/technetwork/java/javase/downloads/jdk13-downloads- 5672538.html
I didn't need the full JDK, I just needed to make JRE work and none of the other answers provided above worked for me. Maybe it used to work, but now (1st Jul 2018) it isn't working. I just kept getting the error and the pop-up.
I eventually solved this issue by placing the following JAVA_HOME export in ~/.bash_profile:
export JAVA_HOME=/Library/Internet\ Plug-Ins/JavaAppletPlugin.plugin/Contents/Home
Hope this helps someone. I'm running Mac OS High Sierra.
Source: Stackoverflow.com