-
1. Re: JBoss On - Starting rhq-server.sh
javim Aug 4, 2010 5:47 AM (in response to javim)Does someone know about it? It still happens even with the 2.4.0 version
[my_user@my_machine bin]$ sudo ./rhq-server.sh start
Trying to start the RHQ Server...
RHQ Server (pid 11840) is NOT running
Failed to start - make sure the RHQ Server is fully configured properly
[my_user@my_machine bin]$ -
2. Re: JBoss On - Starting rhq-server.sh
lkrejci Aug 4, 2010 6:08 AM (in response to javim)Hi Javier,
to be honest with you I have never seen this happen. Are you 100% sure that that the installation is full and uncorrupted in some way?
Also, to be able to diagnose this further, we'd need to know more about your RHQ installation. What OS you use? Where is RHQ installed? Do you cd into it through some symlink? What java version do you use? I see that you "sudo" the start up script. How is JAVA_HOME or RHQ_SERVER_JAVA_HOME env variable set for root? Off top of my head those are the things that theoretically might influence the startup but we'll know more when you provide some more info.
Also does the server start up if you start it as the current user?
Regards,
Lukas
-
3. Re: JBoss On - Starting rhq-server.sh
javim Aug 4, 2010 6:24 AM (in response to lkrejci)Hi Lukas
OS: Red Hat EL 5
JAVA: jdk1.6.0_17
RHQ_HOME: /home/my_home/jon-server-2.4.0.GA
I use sudo becoz y need permissions to execute rhq-server.sh or ill would get the next message
[my_user@my_machine bin]$ ./rhq-server.sh start
Trying to start the RHQ Server...
./rhq-server.sh: line 401: /home/my_home/jon-server-2.4.0.GA/bin/rhq-server.pid: Permiso denegado
RHQ Server (pid 11986) is NOT running
Failed to start - make sure the RHQ Server is fully configured properlyJAVA_HOME or RHQ_SERVER_JAVA_HOME are defined at the begining of rhq-server.sh. I had to do this becoz rhq-server.sh didnt recognize them in /etc/profile or /home/my_home/.bashrc or /home/my_home/.bash_profileI dont know what more to doThanks Lukas,Best regards -
4. Re: JBoss On - Starting rhq-server.sh
lkrejci Aug 4, 2010 6:53 AM (in response to javim)Hmm,
there should be no explicit need to run the rhq server as root. Normal user should be able to start it up as well. I thought you're doing it because of some policy you have defined in your environment, but as I said the RHQ server doesn't mandate to be run as root.
The fact that you get a permission denied error when the script is trying to create the PID file tells me that maybe you have some permission issues in the RHQ install dir.
What user owns the RHQ directory?
Does the file /home/my_home/jon-server-2.4.0.GA/bin/rhq-server.pid exist? If it does, who owns it?
You should delete the file before starting the server (it should be deleted automatically when you do rhq-server.sh stop), because that file contains the process id of the server, which would obviously be wrong if the file existed and you were starting a new server.
It is also very weird that the env variables aren't recognized when defined in the parent shell. I'd double check that you really are defining them and that they exist after you re-login.
-
5. Re: JBoss On - Starting rhq-server.sh
pilhuhn Aug 4, 2010 7:35 AM (in response to javim)Can you please supply boot.log and rhq-server-log4j.log files here?
The error you see mean that the server itself had issues starting.
Alternatively you can start via
bin/rhq-server.sh console
and paste the console output into your reply.
-
6. Re: JBoss On - Starting rhq-server.sh
javim Aug 5, 2010 3:24 AM (in response to pilhuhn)I did it. I think there's a mem problem with JVM.
$ ./rhq-server.sh console
Starting RHQ Server in console...
=========================================================================JBoss Bootstrap Environment
JBOSS_HOME: /home/bodies/jon-server-2.4.0.GA/jbossas
JAVA: /usr/java/jdk1.6.0_17/bin/java
JAVA_OPTS: -Dprogram.name=run.sh -Dapp.name=rhq-server -Xms1024M -Xmx1024M -XX:PermSize=256M -XX:MaxPermSize=256M -Djava.net.preferIPv4Stack=true -Djboss.server.log.dir=/home/bodies/jon-server-2.4.0.GA/logs -Djava.awt.headless=true -Djboss.platform.mbeanserver -Dsun.lang.ClassLoader.allowArraySyntax=true -Djava.util.logging.config.file=/home/bodies/jon-server-2.4.0.GA/jbossas/server/default/conf/logging.properties -Djava.net.preferIPv4Stack=true
CLASSPATH: /home/bodies/jon-server-2.4.0.GA/jbossas/bin/run.jar:/usr/java/jdk1.6.0_17/lib/tools.jar
=========================================================================
Error occurred during initialization of VM
Could not reserve enough space for object heap -
7. Re: JBoss On - Starting rhq-server.sh
pilhuhn Aug 5, 2010 3:54 AM (in response to javim)Hey,
the output shows "-Xms1024M -Xmx1024M" which means the server wants to reserve 1GB memory for heap (and additional 256MB for perm gen), which in total makes ~1.4GB that the JVM wants. Looks like this is too much for your server.
You may tune this by setting RHQ_SERVER_JAVA_OPTS to something like
export RHQ_SERVER_JAVA_OPTS="-Xmx256m ....." (the ... being more arguments)
-
8. Re: JBoss On - Starting rhq-server.sh
javim Aug 5, 2010 4:14 AM (in response to pilhuhn)Hey Heiko
That was the problem!! The server died bcoz it couldnt run JVM bcoz mem problem. I changed params to
-Xms512M -Xmx512M -XX:PermSize=256M -XX:MaxPermSize=256M
and it already works. I know that is not the correct heap size to make it works correctly. Unless I know that it runs. I'll try to obtain more memmory for my VM.
Thank everybody very much.
Best regards,
Javier