I'm running Mac OSX and have installed UltraESB. When I try to run it I get the following error:
adding os/x equivalent of tools.jar
Starting AdroitLogic UltraESB ... Using JAVA_HOME :
/Library/Java/JavaVirtualMachines/jdk1.7.0_55.jdk/Contents/Home Using
ULTRA_HOME: /opt/ultraesb-2.2.0 log4j:ERROR setFile(null,true) call
failed. java.io.FileNotFoundException: logs/ultraesb.log (Permission
denied)
Can anyone tell me why?
I gave the folder read, write and execute permissions.
Related
warning: ignoring JAVA_HOME=C:\Program Files\Java\jdk-11.0.15; using bundled JDK
Installing service : "elasticsearch-service-x64"
Using ES_JAVA_HOME (64-bit): "C:\Program Files\elasticsearch-8.2.0\jdk"
Exception in thread "main" java.lang.RuntimeException: starting java failed with [1]
output:
[0.150s][error][logging] Error opening log file 'logs/gc.log': Permission denied
[0.150s][error][logging] Initialization of output 'file=logs/gc.log' using options 'filecount=32,filesize=64m' failed.
error:
Could not rename log file 'logs/gc.log' to 'logs/gc.log.10' (Permission denied).
Invalid -Xlog option '-Xlog:gc*,gc+age=trace,safepoint:file=logs/gc.log:utctime,pid,tags:filecount=32,filesize=64m', see error log for details.
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
at org.elasticsearch.tools.launchers.JvmOption.flagsFinal(JvmOption.java:114)
at org.elasticsearch.tools.launchers.JvmOption.findFinalOptions(JvmOption.java:79)
at org.elasticsearch.tools.launchers.MachineDependentHeap.determineHeapSettings(MachineDependentHeap.java:61)
at org.elasticsearch.tools.launchers.JvmOptionsParser.jvmOptions(JvmOptionsParser.java:135)
at org.elasticsearch.tools.launchers.JvmOptionsParser.main(JvmOptionsParser.java:87)
Did you try changing jvm.options and set Xms and Xms memory arguments?
Both should be the same value, and value should be below the total available system memory.
Also try changing log level in log4j.properties file to get some detailed error log, if that helps.
I have problems with running Elastic Search on my ubuntu 20.04 server (I can do it locally). When I run ./bin/elasticsearch in terminal I get lines below
Exception in thread "main" java.lang.RuntimeException: starting java failed with [1]
output:
[0.000s][error][logging] Error opening log file 'logs/gc.log': Permission denied
[0.001s][error][logging] Initialization of output 'file=logs/gc.log' using options 'filecount=32,filesize=64m' failed.
error:
OpenJDK 64-Bit Server VM warning: Option UseConcMarkSweepGC was deprecated in version 9.0 and will likely be removed in a future release.
Could not rename log file 'logs/gc.log' to 'logs/gc.log.05' (Permission denied).
Invalid -Xlog option '-Xlog:gc*,gc+age=trace,safepoint:file=logs/gc.log:utctime,pid,tags:filecount=32,filesize=64m', see error log for details.
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
at org.elasticsearch.tools.launchers.JvmOption.flagsFinal(JvmOption.java:119)
at org.elasticsearch.tools.launchers.JvmOption.findFinalOptions(JvmOption.java:81)
at org.elasticsearch.tools.launchers.JvmErgonomics.choose(JvmErgonomics.java:38)
at org.elasticsearch.tools.launchers.JvmOptionsParser.jvmOptions(JvmOptionsParser.java:135)
at org.elasticsearch.tools.launchers.JvmOptionsParser.main(JvmOptionsParser.java:86)
What I tried: sudo chmod -R +w /home/ubuntu/data/stepa/elasticsearch-7.16.2/logs/. It didn't help.
I didn't succeed to find answer on elastic search forum.
Thank you for any help.
Finally, I found the solution. Log lines mean problems with rights. Current user has to be an owner of directory. In my case owner of /home/ubuntu/data/stepa/elasticsearch-7.16.2/logs/ was root. I changed it using this command sudo chown username:group /home/ubuntu/data/stepa/elasticsearch-7.16.2/logs
("ubuntu: " in my case because group is default and username is ubuntu)
Thanks to ilvar for clues.
So I was trying to make a 1.17.1 minecraft server on my mac. I couldn't open my 1.17.1_server.jar with Java 8 so I download Java 16.0.2.
Unfortunately, everytime I was opening the 1.17.1_server.jar file, I got
"The Java JAR file "1.17._server.jar" could not be launched." .
I first thought that it was because the file was launch by Java 8 instead of 16.
So I went into the terminal and run :<path to java> -jar 1.17.1_server.jar
I then got this : Error: Unable to access jarfile 1.17.1_server.jar
Finally i tried to put the path of the jar file in the command...
So I've run : path to java -jar path to server
and got this :
[main/ERROR]: Failed to load properties from file: server.properties
[15:57:35] [main/WARN]: Failed to load eula.txt
[15:57:35] [main/INFO]: You need to agree to the EULA in order to run the server. Go to eula.txt for more info.
So why I have to agreed Eula if i've never launched it ? Does it think that he already been launched ?
As stated in the error message
[15:57:35] [main/INFO]: You need to agree to the EULA in order to run the server. Go to eula.txt for more info.
You have to open the file and check yes
Okay find the solution: my eula and server properties file were in my user folder dk why (never moved them so...)
I wrote an app and it works fine by me. But on other pc-s it throws an exception.
java.sql.SQLException: No suitable driver found for jdbc:sqlserver
I give it (only the app.jar file) to my college, and he gets this error. I give him a jdbcdriver.jar file and, nothing changed.
However I use jre7, I added a line to the code:
Class.forName("com.mysql.jdbc.Driver");
And than he gets another exception:
Error: java.lang.ClassNotFoundException: com.mysql.jdbc.Driver
What can I do to run this app properly on other pc-s?
Put the jar file, containing the MySql Driver on the classpath when starting your application.
The switch is called -cp or -classpath like this:
java -cp ".;mysql.jar" my.package.Main
assuming you start your application from the root directory which is named my.package.Main. The classpath separator is the one for Windows. For unix based OSs you need to use : i guess.
I am running a simple code of MapReduce and am getting the following error:
`Exception in thread "main" java.io.IOException: Error opening job jar: Test.jar
at org.apache.hadoop.util.RunJar.main(RunJar.java:90)
Caused by: java.util.zip.ZipException: error in opening zip file
at java.util.zip.ZipFile.open(Native Method)
at java.util.zip.ZipFile.<init>(ZipFile.java:114)
at java.util.jar.JarFile.<init>(JarFile.java:133)
at java.util.jar.JarFile.<init>(JarFile.java:70)
at org.apache.hadoop.util.RunJar.main(RunJar.java:88)`
Some details of the problem:
My hadoop version is 0.20.
I have set new JobConf(Statecount.class) where Statecount.class is the class from which I am running this job. What do I have to do to resolve this error?
Can anyone help me?
Thanks.
check that the hadoop user (usually 'hadoop') have permission to this file
sometimes hadoop need that some files will be on the HDFS and not in your file system.
Are you trying to run a jar named Test.jar in the java program RunJar?
If so please remember that any local path used could only be the on the name node.