Error in starting cassandra in windows 10 PC - java

I had downloaded the Cassandra software and installed the dependencies i.e. Python and Java. Then in cmd I wrote the following command.
C:\apache-cassandra-3.11.10\bin>cassandra
It gave the following output
WARNING! Powershell script execution unavailable.
Please use 'powershell Set-ExecutionPolicy Unrestricted'
on this user-account to run cassandra with fully featured
functionality on this platform.
Starting with legacy startup options
Starting Cassandra Server
Unrecognized VM option 'UseParNewGC'
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
My java version is:
C:\apache-cassandra-3.11.10\bin>java --version
java 16 2021-03-16
Java(TM) SE Runtime Environment (build 16+36-2231)
Java HotSpot(TM) 64-Bit Server VM (build 16+36-2231, mixed mode, sharing)
Does Cassandra 3.11.10 support Java-16?

Set the appropriate execution policy in Powershell.
Cassandra 3 only works with Java 8 and lower.
The other possibility for you is to run Cassandra on WSL (Windows Subsystem Linux).

Related

Java version compatible

I have a server with java code running and need to setup the same environment on another server to run the code
Now when I try to run my program I get this error
Exception in thread "main" java.lang.NoSuchMethodError: 'void sun.security.pkcs11.SunPKCS11.(java.io.InputStream)'
but on the first machine working fine and getting the result
I run java -v on first machine and get this result
java version "1.8.0_25"
Java(TM) SE Runtime Environment (build 8.1.002)
SAP Java Server VM (build 8.1.002 25.11-b13, Dec 16 2014 04:44:15 - 81_REL - optU - windows x86 - 6 - bas2:230506 (mixed mode))
but I can't find the same environment to install on the other server and make my program work

Flowable Open Source REST API Setup in Ubuntu 18.04

I followed instructions given in Flowable Getting Started Guide to setup Flowable REST API on Ubuntu 18.04. After running sudo ./catalina run, I do get Apache Tomcat up and running on port 8080. However, when I try REST APIs of flowable-rest, I get a 404 error.
java --version
java 17.0.1 2021-10-19 LTS
Java(TM) SE Runtime Environment (build 17.0.1+12-LTS-39)
Java HotSpot(TM) 64-Bit Server VM (build 17.0.1+12-LTS-39, mixed mode, sharing)
I tried this on Windows and it worked without a problem. Therefore, I think this happens due to a permissions issue, environment variable issue or Java version/path related issue. However, I'm not that familiar with Java and I'm unable to isolate the exact cause.

CentOS Invalid maximum heap size for .exe program

im using a VM with minimal installed CentOS 7. Im quite new with linux and CentOs. My Java version:
java -version
openjdk version "1.8.0_232"
OpenJDK Runtime Environment (build 1.8.0_232-b09)
OpenJDK 64-Bit Server VM (build 25.232-b09, mixed mode)
When I try running a java based application (a .exe) I get the following error, this Java application should be running with Java8, in fact it was running last time the VM was on (last friday) today (sunday) when a turned on again it gives the error:
Invalid maximum heap size: -Xmx1g
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
I tried the following commands:
java -Xmx1024M -Xms1024M
result of above command
and
java -Xmx2048M -d64
results of the second command
But as you see I only get some java usage text, and the problem persists.
Also tried to add into .bash_profile the line. Again with no success.
export _JAVA_OPTIONS=-Xmx2g
Updating.
Hello, it worked after a reinstalled the app, and with the export _JAVA_OPTIONS=-Xmx2g on .bash_profile.

Can't create Java VM rjb ubuntu

I am using rjb to connect java classes in my rails application...
But I am getting this error can't create Java VM
My ruby -v gave me
ruby 1.9.3p484 (2013-11-22 revision 43786) [x86_64-linux]
and java --version
java version "1.7.0_79"
OpenJDK Runtime Environment (IcedTea 2.5.5) (7u79-2.5.5-0ubuntu0.14.04.2)
OpenJDK 64-Bit Server VM (build 24.79-b02, mixed mode)
I went through this post Error “can't create Java VM” trying to use Ruby Java Bridge (RJB) gem but the problem is I can not install 32 bit java as it is needed by some other application
I would download the jdk from oracle (http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html), the version you need. Then for your application set JAVA_HOME to that install directory. You can have multiple different jvms installed on a system.

Neo4j Java 7 Terminal Issue

I'm having issues starting my neo4j instance (2.0.0 M03). I have java 7 installed as indicated in the code block below but when trying to start neo4j it apparently does not recognize this, gives and error and does not start. The terminal output is below. Any ideas on how to fix this or what exactly is going wrong? Thanks a lot.
Tim-Bornys-MacBook-Pro:neo4j community 2.0.0 M03 BornyTM$ java -version
java version "1.7.0_25"
Java(TM) SE Runtime Environment (build 1.7.0_25-b15)
Java HotSpot(TM) 64-Bit Server VM (build 23.25-b01, mixed mode)
Tim-Bornys-MacBook-Pro:neo4j community 2.0.0 M03 BornyTM$ bin/neo4j start
WARNING! You are using an unsupported version of the Java runtime. Please use Oracle(R) Java(TM) Runtime Environment 7.
Starting Neo4j Server...WARNING: not changing user
process [88317]... waiting for server to be ready.... Failed to start within 120 seconds.
Neo4j Server may have failed to start, please check the logs.
The problem was JAVA_HOME was not set to the correct JVM. To determine where you have your instance installed you can enter the following into terminal:
/usr/libexec/java_home -v 1.7
This should return the location, in my case: /Library/Java/JavaVirtualMachines/jdk1.7.0_25.jdk/Contents/Home/
To set JAVA_HOME just export pointing towards the location like below (enter into the console):
export JAVA_HOME=/Library/Java/JavaVirtualMachines/jdk1.7.0_25.jdk/Contents/Home/

Categories