How to launch JBoss on Win7? - jboss6.x

i tried to launch it by cmd with this command:
C:...\jboss-eap-6.4.0\bin>standalone.bat
but it failed with error:
Error occured during initialization of VM
Could not reserve enough space for object heap
how to launch JBoss? i did something wrong?

JBoss could be trying to use more memory than it's permitted by Java's memory range. You can try increasing the heap size.
Add this to your standalone.bat before running it again:
set "JAVA_OPTS=-Xms128M -Xmx512M -XX:MaxPermSize=256M"

Related

Neo4j refused to connect

Characteristics :
Linux
Neo4j version 3.2.1
Access on remote
Installation
I Had install neo4j and gave the folder chmod 777 .
Im running it remotely on my machine and I had already enabled non local access
Doing NEo4j start i get this message
Active database: graph.db
Directories in use:
home: /home/cloudera/Muna/apps/neo4j
config: /home/cloudera/Muna/apps/neo4j/conf
logs: /home/cloudera/Muna/apps/neo4j/logs
plugins: /home/cloudera/Muna/apps/neo4j/plugins
import: /home/cloudera/Muna/apps/neo4j/import
data: /home/cloudera/Muna/apps/neo4j/data
certificates: /home/cloudera/Muna/apps/neo4j/certificates
run: /home/cloudera/Muna/apps/neo4j/run
Starting Neo4j.
WARNING: Max 1024 open files allowed, minimum of 40000 recommended. See the Neo4j manual.
Started neo4j (pid 9469). It is available at http://0.0.0.0:7474/
There may be a short delay until the server is ready.
See /home/cloudera/Muna/apps/neo4j/logs/neo4j.log for current status.
and it is not connecting in the browser .
running neo4j console
# There is insufficient memory for the Java Runtime Environment to continue.
# Native memory allocation (malloc) failed to allocate 409600000 bytes for AllocateHeap
# An error report file with more information is saved as:
# /home/cloudera/hs_err_pid18598.log
where could the problem be coming from ?
Firstly, you should set the maximum open files to 40000, which is the recommended value. Then you do not get the WARNING. Like this: http://neo4j.com/docs/1.6.2/configuration-linux-notes.html
Secondly,'failed to allocate memory' means that the Java virtual machine cannot allocate the memory you start it with.
It can be a misconfiguration, or you physically do not have enough memory.
Please read the memory sizing guidelines here:
https://neo4j.com/docs/operations-manual/current/performance/

i have just begun to use android studio and i cant seem to get my gradle to sync with my application. here is what it shows :

7:46:20 PM Gradle sync started
7:46:35 PM Gradle sync failed: Unable to start the daemon process.
This problem might be caused by incorrect configuration of the daemon.
For example, an unrecognized jvm option is used.
Please refer to the user guide chapter on the daemon at https://docs.gradle.org/2.10/userguide/gradle_daemon.html
Please read the following process output to find out more:
-----------------------
Error occurred during initialization of VM
Could not reserve enough space for object heap
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
Consult IDE log for more details (Help | Show Log)
the jvm version is 1.7.0_79
and the studio version is 2.1.1
Error occurred during initialization of VM Could not reserve enough space for object heap Error: Could not create the Java Virtual Machine.
There's no space available in RAM. To fix go to /android-studio-dir/bin and edit studio.vmoptions and studio64.vmoptions to increment the -Xmx and to reserve more memory to Java. Note that the number of processes active may influence on that.
Probably, the /tmp location is full..
Found this somewhere..
Use df command
df
You should see an output with a line like this:
tmpfs 102400 102312 88 100% /tmp
So to change the size of the tmp file:
sudo mount -o remount,size=2G /tmp
Done! Now, It should work..

Spark - UbuntuVM - insufficient memory for the Java Runtime Environment

I'm trying to install Spark1.5.1 on Ubuntu14.04 VM. After un-tarring the file, I changed the directory to the extracted folder and executed the command "./bin/pyspark" which should fire up the pyspark shell. But I got an error message as follows:
[ OpenJDK 64-Bit Server VM warning: INFO: os::commit_memory(0x00000000c5550000, 715849728, 0) failed;
error='Cannot allocate memory' (errno=12) There is insufficient
memory for the Java Runtime Environment to continue.
Native memory allocation (malloc) failed to allocate 715849728 bytes
for committing reserved memory.
An error report file with more information is saved as:
/home/datascience/spark-1.5.1-bin-hadoop2.6/hs_err_pid2750.log ]
Could anyone please give me some directions to sort out the problem?
We need to set spark.executor.memory in conf/spark-defaults.conf file to a value specific to your machine. For example,
usr1#host:~/spark-1.6.1$ cp conf/spark-defaults.conf.template conf/spark-defaults.conf
nano conf/spark-defaults.conf
spark.driver.memory 512m
For more information, refer to the official documentation: http://spark.apache.org/docs/latest/configuration.html
Pretty much what it says. It wants 7GB of RAM. So give the VM ~ 8GB of RAM.

Need command to check permgenspace in running tomcat server

I need a command to check the permgenspace in tomcat server. The basic is if I am hitting permgenspace error I want to see the space there.
I used below command to check permgenspace, It is always showing same size eventhough Tomcat may hits the java.lang.OutOfMemoryError: PermGen space error.
java -XX:+PrintFlagsFinal tomcat | grep PermSize
uintx AdaptivePermSizeWeight = 20 {product}
uintx MaxPermSize = 174063616 {pd product}
uintx PermSize = 21757952 {pd product}
Error: Could not find or load main class tomcat
Please suggest me on this.
You should try the following command:
jstat -gcpermcapacity SERVERPID
For java 8+ this command is deprecated; Use these ones instead :
jstat -gcutil SERVERPID
jstat -gc SERVERPID
Source : http://docs.oracle.com/javase/7/docs/technotes/tools/share/jstat.html#gcpermcapacity_option
You could try this :
export JAVA_OPTS="-Xms1024m -Xmx10246m -XX:NewSize=256m
-XX:MaxNewSize=356m -XX:PermSize=256m -XX:MaxPermSize=356m"
You can change the actual heap size and PermGen Space as per your requirement.
Restart and run tomcat command again

Unable to start titan-server (Titan with Cassandra and Rexster)

I am trying to implement titan graph database on cassandra for one of my applications. As per documentation, I have downloaded and extracted titan-cassandra-0.3.2 and when it trying to run titan.sh with titan-server-rexster.xml andtitan-server-cassandra.properties as arguments I am facing below error:
In below stack trace it says "Cannot locate /opt/isv/app/pkgs/titan-cassandra-0.3.2/config/cassandra.yaml" but I do have that file in that location. Could anyone please help?
WARN org.apache.cassandra.utils.CLibrary - Unable to lock JVM memory (ENOMEM). This can result in part of the JVM being swapped out, especially with mmapped I/O enabled. Increase RLIMIT_MEMLOCK or run Cassandra as root.
72 [pool-1-thread-1] ERROR org.apache.cassandra.config.DatabaseDescriptor - Fatal configuration error
org.apache.cassandra.exceptions.ConfigurationException: Cannot locate /opt/isv/app/pkgs/titan-cassandra-0.3.2/config/cassandra.yaml
at org.apache.cassandra.config.DatabaseDescriptor.getStorageConfigURL(DatabaseDescriptor.java:113)
at org.apache.cassandra.config.DatabaseDescriptor.loadYaml(DatabaseDescriptor.java:130)
at org.apache.cassandra.config.DatabaseDescriptor.<clinit>(DatabaseDescriptor.java:122)
at org.apache.cassandra.service.CassandraDaemon.setup(CassandraDaemon.java:150)
at org.apache.cassandra.service.CassandraDaemon.activate(CassandraDaemon.java:366)
at org.apache.cassandra.service.CassandraDaemon.main(CassandraDaemon.java:409)
at com.thinkaurelius.titan.diskstorage.cassandra.embedded.CassandraDaemonWrapper$CassandraStarter.run(CassandraDaemonWrapper.java:64)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)
Cannot locate /opt/isv/app/pkgs/titan-cassandra-0.3.2/config/cassandra.yaml
Fatal configuration error; unable to start server. See log for stacktrace.
A complete walkthrough for ENOMEM is here
http://docs.datastax.com/en/archived/cassandra/2.0/cassandra/troubleshooting/trblshootInsufficientResources_r.html also do not forget
Basically edit /etc/security/limits.conf file appending the following
memlock unlimited
nofile 100000
nproc 32768
as unlimited
and then run sysctl -p

Resources