Chinmayee Srivathsa's Weblog

Stumblin' Along...

Wednesday Jan 09, 2008


This blog attempts to summarize what I've learned from forum postings and personal experiences as I try out various things with GlassFish 9.1.

Log files

A useful resource for troubleshooting your problems are the log files (there is a separate server.log file for each domain, node agent, and instance).  For problems related to starting a domain, nodeagents, or instance see the server.log.

The location of the server.log file for domains, nodeagents, and instances:
- domain: <install-dir>/domains/<domain-name>/logs/server.log
- nodeagent:<install-dir>/nodeagents/<node-agent-name>/agent/logs/server.log
- instance: <install-dir>/nodeagents/<node-agent-name>/<instance-name>/logs/server.log

Thread Dumps

Another useful resource is the thread dump.  With  JDK 5, you have the very useful jps command. Run the jps command and look for PELaunch, which denotes a running app server process (node agents, domains, clusters, etc).

(prompt) jps

1261 Jps
1104 PELaunch

If you want to terminate unresponsive app server process use the kill -3 <PELaunch PID> command in Unix and sendsignal utility for Windows. For more info, see thread dumps.

Common Problems and Solutions


Problem Solution
Cluster instances fail to start. server.log of the instance shows "connection refused" messages
1. Ensure that you followed the steps here and here:
2. If you're still having problems, edit your
/etc/hosts file and ensure that your hostname maps to an absolute IP address and not to 127.0.0.1.
You cannot log on to the Admin Console of the DAS or a domain, although it appears that you have have started it.
1. Ensure that you are NOT using the deprecated startserv command. See the docs for instructions on how to start a domain.
2. Verify that your  hostname  is mapped to an absolute IP address. 
3. Ensure that you do not have a firewall running.
4. There is a known issue and a workaround for Mac OS X systems. See this forum post.


Unable to start the domain.
1. If the error messages suggest that you do not have read-write access to the domain's folder, you probably installed the application server as a different user and you are trying to start the domain as  a different user. Ensure that the user who installed the app server provides the app server user with read-write access to app server domain folders.
Although you have installed JDK 5, GlassFish reports that Java 2 SDK version 5.0 or above not found. 1. Ensure that you are running the correct version of java to unjar your files. Add <jdk5_install_dir>/bin to your PATH environment variable. Run java -version command to ensure that you are running the correct version.
2. Set
JAVA_HOME to your <jdk5_install_dir>.
Load balancer (working fine earlier) does not work after restarting the cluster.
Ensure that you have created a health-checker for your cluster and load balancer. Use the create-http-health-checker command.
In-memory replication not working. Unable to make your web apps highly available.
Ensure that you have enabled/checked the Availability Enabled option while deploying your application. For step-by-step instructions (either using HADB or in-memory replication), see this.

[1] Comments
Like this post? del.icio.us | furl | slashdot | technorati | digg

Make a Wish!

Tuesday Nov 06, 2007

Let us know what you want to see in GlassFish v3 documentation and the GlassFish documentation team will work on delivering what you wish for!

Participate in the GlassFish v3 documentation planning meetings and help us provide what you are looking for, in the docs.
Meeting details are here.

Another way to send in your suggestions and feedback: write to - docs at glassfish dot dev dot java dot net.

Like this post? del.icio.us | furl | slashdot | technorati | digg

GlassFish Error Messages

Thursday Oct 11, 2007

The Error Message Reference guide for GlassFish is now available in Wiki format here. If you have information on how to handle a GlassFish error message, contribute to this Wiki and help make life easier for other users!

Like this post? del.icio.us | furl | slashdot | technorati | digg