Can't start the Elastic service in Windows 10 - java

Similar question to this one but with a different OS. I've installed the latest Java and verified by:
> java -version
java version "1.8.0_191"
Java(TM) SE Runtime Environment (build 1.8.0_191-b12)
Java HotSpot(TM) 64-Bit Server VM (build 25.191-b12, mixed mode)
I also make sure that JAVA_HOME is set as system variable and verify it by:
> $env:java_home
C:\Program Files (x86)\Java\jdk1.8.0_192
Then, I tried both ZIP installation and MSI installation of the Elastic Windows Service. It's installed but doesn't run. When forced manually, it says that it can't do that on the local system (1067, the process terminated unexpectedly).
I tried to reinstall all the relevant components. I tried scm /scannow and reimporting the keys into registry. I tried to re-set the user and system environment variables. Etc. I'm out of ideas.
I noticed that there's no logs directory in Elastic installation root. Also, there's no configuration files in that directory as far I could see. Where exactly should they be located so I can check what's logged and play around with different settings.

Related

Cannot set up SDK for IntelliJ Idea

I am beginner in linux (running Linux Mint 18.3), and trying to set-up my environment for Java development. I've done this several times on my Windows machine, and it always worked, but couldn't make it work for linux.
Running command java-version returns the following:
openjdk version "1.8.0_162"
OpenJDK Runtime Environment (build 1.8.0_162-8u162-b12-0ubuntu0.16.04.2-b12)
OpenJDK 64-Bit Server VM (build 25.162-b12, mixed mode)
Still, when I open IntelliJ, it says that Project SDK is not defined. When I am trying to set it up to the folder /usr/lib/jvm/java-8-openjdk-amd64/jre/bin (being the location I found digging into my filesystem starting with command whereis java) it says that "The selected directory is not a valid home for JDK". I've added manually the path also to $JAVA_HOME and '$PATH' but the problem persists.
The path you posted says "jre" in it, you need the JDK.
You need shoose JDK path
without BIN folder, like D:\java\jdk\jdk1.8.0_162

Can't run java applications

I have trouble when trying to open my jar files with the following command:
java -jar software.jar
They load until a certain point and then nothing happens.
I deinstalled default-jdk and OpenJDK with synaptic and re-installed it with apt-get, but nothing changed. I had a similar problem one month ago and solved it (apparently only temporarly) by deleting the package gcj-5-jre-lib (5.4.0-6ubuntu1~16.04.4) (Java runtime library for use with gcj (jar files))
The following outputs will help:
java -version
openjdk version "1.8.0_131"
OpenJDK Runtime Environment (build 1.8.0_131-8u131-b11-2ubuntu1.16.04.3-b11)
OpenJDK 64-Bit Server VM (build 25.131-b11, mixed mode)
javac -version
1.8.0_131
My variables $JAVA_HOME and $JRE_HOME were correctly added to my $PATH.
I'm on Ubuntu 16.04
EDIT
Here is an example of what I get when I try to start PhyDE.jar
java -jar PhyDE.jar
Welcome to PhyDE 0.9971!
Reading preferences.
Creating PhyDE-Application window
Checking for updates...
You are using the latest version of PhyDE
Done with checking for updates
When checking the core use with the command top I see that the process is active, but the user interface does not open as it usually does. I am located in the folder where the jar file is, and same happens with other jar files.

Eclipse (and STS) using wrong JDK to start up

I have several versions of Java on my system (OS X El Capitan, version 10.11.6). My current JAVA_HOME variable is set to a Java 8 JDK, and the bin directory is in my path:
$ java -version
java version "1.8.0_121"
Java(TM) SE Runtime Environment (build 1.8.0_121-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.121-b13, mixed mode)
Nevertheless, whenever I try to start Eclipse or STS, I get a crash, and inside the .metadata/.log file in the workspace it includes the line:
java.version=9-ea
I can edit the eclipse.ini file and add a -vm flag to get it to start with the proper JVM, but what mystifies me is where Eclipse is getting the wrong information in the first place. Isn't setting JAVA_HOME enough? Where else might it be finding Java?
I think the native launcher of Eclipse uses /usr/libexec/java_home to determine the current JVM to use and I am not aware of a way to change that command to point to a different VM as a default.

What is the java.exe difference from jdk to (included) jre?

So, I had always thought there was no difference between the java.exe located in the jdk\bin and that in the jdk\jre\bin folders. Apparently, that is not the case, certainly not with java8 anyway.
I was testing the maverick ssh library and found that it would not auto-negotiate an encryption cipher from the list offered by the sshd server when using the java.exe from jdk\bin. Changing the java.exe used to that from the jre supplied with jdk (in the jdk\jre\bin folder) let the test app work fine.
So... what could possibly explain the difference - why would one java.exe work and the other not, if they are both the same?
They appear the same on the surface:
C:\Program Files\Java\jdk1.8.0_20>dir bin\java.exe
08/22/2014 03:35 PM 190,856 java.exe
C:\Program Files\Java\jdk1.8.0_20>dir jre\bin\java.exe
08/22/2014 03:35 PM 190,856 java.exe
But must be different under the hood:
C:\Program Files\Java\jdk1.8.0_20>diff bin\java.exe jre\bin\java.exe
Files bin\java.exe and jre\bin\java.exe differ
EDIT:
I did review the question which is suggested as a duplicate, however it did not address my question.
The versions of the binaries appear the same:
C:\Program Files\Java\jdk1.8.0_20>bin\java -version
java version "1.8.0_20"
Java(TM) SE Runtime Environment (build 1.8.0_20-b26)
Java HotSpot(TM) 64-Bit Server VM (build 25.20-b23, mixed mode)
C:\Program Files\Java\jdk1.8.0_20>jre\bin\java -version
java version "1.8.0_20"
Java(TM) SE Runtime Environment (build 1.8.0_20-b26)
Java HotSpot(TM) 64-Bit Server VM (build 25.20-b23, mixed mode)
I did not adjust the classpath or anything else on my commandline, other than the path to java.exe.
Compared the two using WinMerge... there are a few diffs nr the start and end (moreso) of the two files. All binary gobble-de-gook to me.
Re using that library and getting different results, that's almost certainly not anything to do with java.exe, but something to do with the classpath and jars used by the JDK install vs. the JRE install.
Re your different files, it's not just you: I dug up a Windows 8.1 machine with (an old copy of) Oracle's Java8 on it, and it's the same thing: Sizes, dates, and versions match, contents don't quite. This isn't true of my Linux box with Oracle's Java8 on it, where the jdk/bin/java and jdk/jre/bin/java files are identical (and not just symlinked). My guess is it relates to optimization defaults, but doesn't relate to your ssh library issue.

Can not start Integrated WebLogic server in Oracle Jdeveloper 12c

I got homework to create Oracle ADF applications according to the instructions on oracle.com, specifically there: http://docs.oracle.com/cd/E37547_01/tutorials/tut_rich_app/tut_rich_app_2.html
But in step 10, I can not start IntegratedWeblogic server.
Log with fails is there: http://www.sendspace.com/file/v9l7vy
My bare idea is diacritical marks and space in my Windows username 'Petr Mojžíš'. I use Microsoft account to login to Windows, which create this anomaly.
I use Windows 8.1 64bit in English version and Oracle JDeveloper 12c.
Thank you for your advice
Modify %HOME%\oracle_common\common\bin\commEnv.cmd file setting USER_MEM_ARGS environment variable after ":continue" tag and re-create default domain again from Application Servers view on JDeveloper.
SET USER_MEM_ARGS=-Xms32m -Xmx1024m -XX:MaxPermSize=512m -XX:MaxHeapSize=512m
Try to set a system environment variable JDEV_USER_HOME and point it to a path in your directory D:\JDEV_USER_HOME . But this way the Jdeveloper related information is stored in the D:\JDEV_USER_HOME rather than AppData under user directory .
The problem is that you have your Weblogic in directory that has both special characters and spaces C:\Users\Petr Mojžíš\AppData\Roaming\JDeveloper\system12.1.2.0.40.66.68\DefaultDomain
In order to overcome this, Close your JDeveloper, create a new Environment variables JDEV_USER_HOME which points to a directory without any spaces or special characters. Open JDeveloper again and you should be good to go.
I had experienced a situation with the integrated weblogic server goes to the point when it says it is and it stops there, jdeveloper does not exit task. Making it impossible to deploy apps.
Possible solution.
It seems that it might have to do with Environment settings.
I changed the JAVA_HOME to point to the one in %ORACLE_HOME%\oracle_common\jdk and set the path to %JAVA_HOME%\bin and it seems to solve the issue.
Previously I was on
java version "1.8.0_144"
Java(TM) SE Runtime Environment (build 1.8.0_144-b01)
Java HotSpot(TM) 64-Bit Server VM (build 25.144-b01, mixed mode)
and now on
java version "1.8.0_131"
Java(TM) SE Runtime Environment (build 1.8.0_131-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.131-b11, mixed mode)

Categories