Skip to main content

how to eliminate SEVERE errors (No class name for worker...) when starting up domain?

9 replies [Last post]
929 Guest
Offline
Joined: 2012-02-13

Hello, I just joined the mailing list and coincidently saw one of my forum posting appear at users@glassfish.java.net after I edited it. I now realize people on the mailing list may reply to the forum posting having only viewed the last posting in the forum. Thus I'm writing this email to try to summarize the complete question in one email. I'll continue to update my forum posting based on whatever I learn. One thing I don't know is if this email will trigger a new forum posting (in which case I'll close the original forum posting).

I have a new CentOS 6.2 server with fresh installs of GlassFish 3.1.1, Apache 2.2.21, mod_jk 1.2.32, and using the bug fix grizzly tar file ( see here ) to get mod_jk working. I'm using the recommended hello.war file to verify correct operation. This application runs fine when accessed externally over the internet.

However, I notice one type of SEVERE error in my server.log file, which occurs multiple times. The error appears every time I restart the domain (that is, asadmin> restart-domain --port 4850). At the bottom of this email, I cut-and-pasted a snippet of the server.log file showing this error, and I've attached the domain.xml file as well in case it helps.

QUESTION 1: How to eliminate the SEVERE errors for...
No class name for worker.worker1 worker

QUESTION 2: How to remove the WARNING related to:

threadpool.max_threads_too_low .

Which thread pool are they referring to? If I type: # asadmin> list-threadpools server admin-thread-pool
http-thread-pool
thread-pool-1 I changed the http-thread-pool max size from 5 to 200 in the admin web-console then restarted the domain, but this had no effect on the WARNING message in server.log shown below. How to remove this warning?

QUESTION 3: The official Administration Guide uses the following lines to bring up GlassFish:

asadmin> deploy /path/to/file/hello.war --port 4850
asadmin> create-http-listener --listenerport 8009 --listeneraddress 0.0.0.0 --defaultvs server gf_listener --port 4850
asadmin> create-network-listener --protocol http-listener-1 --listenerport 8009 --jkenabled true jk-connector --port 4850
asadmin> set server-config.network-config.network-listeners.network-listener.jk-connector.jk-configuration-file=/home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties --port 4850
asadmin> restart-domain --port 4850 I obtained the above lines from: go to http://docs.oracle.com/cd/E18930_01/html/821-2416/ and click on the PDF link, turn to page 151 and see Steps 5 and 6, which shows the above sequence. However, Amy's blog (http://weblogs.java.net/blog/amyroh/archive/2009/06/running_glassfi.html) only creates http-listener (not a network-listener), and the set command is different between the two. I assume the 3.1.1 documentation to be more relevant than Amy's blog, since this blog was written in 2009. Would LOVE to know which method is officially recommended. Here is Amy's sequence:

asadmin> deploy /path/to/file/hello.war --port 4850
asadmin> create-http-listener --listenerport 8009 --listeneraddress 0.0.0.0 --defaultvs server jk-connector --port 4850
asadmin> set configs.config.server-config.network-config.network-listeners.network-listener.jk-connector.jk-enabled=true --port 4850
asadmin> restart-domain --port 4850
If I use the 3.1.1 documentation, I'm not quite sure why I need to issue a create-http-listener as well as a create-network-listener. Could someone explain when one is used versus the other and if they're always both required, etc.? I couldn't find information regarding this anywhere, so I'm following the 3.1.1 Administrative Guide document to the letter. Anyway, I tried both methods, and they both result in the same problems noted above, except the 3.1.1 documentation's method duplicates the SEVERE errors twice (once for each of http-listener and network-listener), whereas Amy's method simply has SEVERE errors for the http-listener.

Here's what I placed in httpd.conf:
LoadModule jk_module /etc/httpd/modules/mod_jk.so
JkWorkersFile /home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties
JkLogFile /etc/httpd/logs/mod_jk.log
JkLogLevel debug
JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "
JkOptions +ForwardKeySize +ForwardURICompat -ForwardDirectories
JkRequestLogFormat "%w %V %T"
...
Listen 0.0.0.0:80

The glassfish-jk.properties file is: worker.list=worker1
worker.worker1.type=ajp13
worker.worker1.host=localhost
worker.worker1.port=8009
maxThreads=256
I followed Amy's method to bring up the GlassFish domain (see above), and as soon as GlassFish comes up, I look at the server.log file. Here's a snippet showing SEVERE error for "No class name for worker..." and WARNING for threadpool.max_threads_too_low (and my desperate plea for help):

[#|2012-02-13T09:58:34.900-0800|INFO|glassfish3.1.1|org.glassfish.ha.store.spi.BackingStoreFactoryRegistry|_ThreadID=10;_ThreadName=Thread-2;|Registered org.glassfish.ha.store.adapter.cache.ShoalBackingStoreProxy for persistence-type = replicated in Bac

kingStoreFactoryRegistry|#]

[#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=13;_ThreadName=Thread-2;|Grizzly Framework 1.9.36 started in: 48ms - bound to [0.0.0.0:8080]|#]

[#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=12;_ThreadName=Thread-2;|Grizzly Framework 1.9.36 started in: 15ms - bound to [0.0.0.0:3700]|#]

[#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=14;_ThreadName=Thread-2;|Grizzly Framework 1.9.36 started in: 26ms - bound to [0.0.0.0:4850]|#]

[#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=11;_ThreadName=Thread-2;|Grizzly Framework 1.9.36 started in: 10ms - bound to [0.0.0.0:7676]|#]

[#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=15;_ThreadName=Thread-2;|Grizzly Framework 1.9.36 started in: 31ms - bound to [0.0.0.0:8181]|#]

[#|2012-02-13T09:58:35.747-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.admin.adapter|_ThreadID=10;_ThreadName=Thread-2;|The Admin Console is already installed, but not yet loaded.|#]

[#|2012-02-13T09:58:36.098-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0169: Created HTTP listener [http-listener-1] on host/port [0.0.0.0:8080]|#]

[#|2012-02-13T09:58:36.111-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0169: Created HTTP listener [http-listener-2] on host/port [0.0.0.0:8181]|#]

[#|2012-02-13T09:58:36.121-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0169: Created HTTP listener [admin-listener] on host/port [0.0.0.0:4850]|#]

[#|2012-02-13T09:58:36.140-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0170: Apache mod_jk/jk2 attached to virtual-server [server] listening on port [8,009]|#]

[#|2012-02-13T09:58:36.178-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0171: Created virtual server [server]|#]

[#|2012-02-13T09:58:36.181-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0171: Created virtual server [__asadmin]|#]

[#|2012-02-13T09:58:36.829-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0172: Virtual server [server] loaded default web module []|#]

[#|2012-02-13T09:58:37.005-0800|SEVERE|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|No class name for worker.worker1 worker|#]

[#|2012-02-13T09:58:37.005-0800|SEVERE|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|No class name for worker.worker1 worker|#]

[#|2012-02-13T09:58:37.005-0800|SEVERE|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|No class name for worker worker|#]

[#|2012-02-13T09:58:37.006-0800|SEVERE|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|No class name for worker.worker1 worker|#]

[#|2012-02-13T09:58:37.006-0800|INFO|glassfish3.1.1|org.apache.jk.common.ChannelSocket|_ThreadID=10;_ThreadName=Thread-2;|JK: ajp13 listening on /0.0.0.0:8009|#]

[#|2012-02-13T09:58:37.012-0800|WARNING|glassfish3.1.1|org.apache.tomcat.util.threads.ThreadPool|_ThreadID=10;_ThreadName=Thread-2;|threadpool.max_threads_too_low|#]

[#|2012-02-13T09:58:37.026-0800|INFO|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|Jk running ID=0 time=0/32 config=null|#]

[#|2012-02-13T09:58:37.603-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=10;_ThreadName=Thread-2;|core.start_container_done|#]

[#|2012-02-13T09:58:37.892-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.security.com.sun.enterprise.security|_ThreadID=10;_ThreadName=Thread-2;|SEC1002: Security Manager is OFF.|#]

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
amyroh
Offline
Joined: 2004-05-06

On 2/13/12 11:40 AM, modjklist@comcast.net wrote:
> Hello, I just joined the mailing list and coincidently saw one of my
> forum posting
>
> appear at users@glassfish.java.net after I edited it. I now realize
> people on the mailing list may reply to the forum posting having only
> viewed the last posting in the forum. Thus I'm writing this email to
> try to summarize the complete question in one email. I'll continue to
> update my forum posting based on whatever I learn. One thing I don't
> know is if this email will trigger a new forum posting (in which case
> I'll close the original forum posting).
>
> I have a new CentOS 6.2 server with fresh installs of GlassFish 3.1.1,
> Apache 2.2.21, mod_jk 1.2.32, and using the bug fix grizzly tar file
> (see here
> )
> to get mod_jk working. I'm using the recommended hello.war file to
> verify correct operation. This application runs fine when accessed
> externally over the internet.
>
> However, I notice one type of SEVERE error in my server.log file,
> which occurs multiple times. The error appears every time I restart
> the domain (that is, asadmin> restart-domain --port 4850). At the
> bottom of this email, I cut-and-pasted a snippet of the server.log
> file showing this error, and I've attached the domain.xml file as well
> in case it helps.
>
> QUESTION 1: How to eliminate the SEVERE errors for...
>
> |No class name for worker.worker1 worker|
>
> QUESTION 2: How to remove the WARNING related to:
> |threadpool.max_threads_too_low|.
>
> Which thread pool are they referring to? If I type: # asadmin>
> list-threadpools server
> admin-thread-pool
> http-thread-pool
> thread-pool-1
> I changed the http-thread-pool max size from 5 to 200 in the admin
> web-console then restarted the domain, but this had no effect on the
> WARNING message in server.log shown below. How to remove this warning?
>
> QUESTION 3: The official Administration Guide uses the following lines
> to bring up GlassFish:
> asadmin> deploy /path/to/file/hello.war --port 4850
> asadmin> create-http-listener --listenerport 8009 --listeneraddress 0.0.0.0 --defaultvs server gf_listener --port 4850
> asadmin> create-network-listener --protocol http-listener-1 --listenerport 8009 --jkenabled true jk-connector --port 4850
> asadmin> set server-config.network-config.network-listeners.network-listener.jk-connector.jk-configuration-file=/home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties --port 4850
> asadmin> restart-domain --port 4850
> I obtained the above lines from: go
> tohttp://docs.oracle.com/cd/E18930_01/html/821-2416/
> and
> click on the PDF link, turn to page 151 and see Steps 5 and 6, which
> shows the above sequence. However, Amy's blog
> (http://weblogs.java.net/blog/amyroh/archive/2009/06/running_glassfi.html)
> only creates http-listener (not a network-listener), and the set
> command is different between the two. I assume the 3.1.1 documentation
> to be more relevant than Amy's blog, since this blog was written in
> 2009. Would LOVE to know which method is officially recommended. Here
> is Amy's sequence:
> asadmin> deploy /path/to/file/hello.war --port 4850
> asadmin> create-http-listener --listenerport 8009 --listeneraddress 0.0.0.0 --defaultvs server jk-connector --port 4850
> asadmin> set configs.config.server-config.network-config.network-listeners.network-listener.jk-connector.jk-enabled=true --port 4850
> asadmin> restart-domain --port 4850

I read the doc again and I agree it could be misleading to use both
create-http-listener and create-network-listener. You should use either
and not both. I've talked to the doc person and he will update this
section to be more clear in the 3.1.2 release.

All you need to do is the following with 3.1.1 if you're not using
glassfish-jk.properties file.

(1) asadmin create-network-listener--protocol http-listener-1
--listenerport 8009 --jkenabled true jk-connector
(2) restart GF

That's it.

> If I use the 3.1.1 documentation, I'm not quite sure why I need to
> issue a create-http-listener as well as a create-network-listener.
> Could someone explain when one is used versus the other and if they're
> always both required, etc.? I couldn't find information regarding this
> anywhere, so I'm following the 3.1.1 Administrative Guide document to
> the letter. Anyway, I tried both methods, and they both result in the
> same problems noted above, except the 3.1.1 documentation's method
> duplicates the SEVERE errors twice (once for each of http-listener and
> network-listener), whereas Amy's method simply has SEVERE errors for
> the http-listener.
>
> Here's what I placed in httpd.conf:
> LoadModule jk_module /etc/httpd/modules/mod_jk.so
> JkWorkersFile /home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties
> JkLogFile /etc/httpd/logs/mod_jk.log
> JkLogLevel debug
> JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "
> JkOptions +ForwardKeySize +ForwardURICompat -ForwardDirectories
> JkRequestLogFormat "%w %V %T"
> ...
> Listen 0.0.0.0:80
>
> The glassfish-jk.properties file is:
>
> worker.list=worker1
> worker.worker1.type=ajp13
> worker.worker1.host=localhost
> worker.worker1.port=8009
> maxThreads=256

I didn't see that you set
network-listener.jk-configuration-file=glassfish-jk.properties above.
This isn't necessary and you can just put workers info in apache/conf.

Do you have the following workers.properties in apache/conf?

worker.list=worker1
worker.worker1.type=ajp13
worker.worker1.host=localhost
worker.worker1.port=8009

I'd suggest the following -

* Copy the above workers.properties in apache/conf
* Restart Apache
* Delete all jk listeners you created (or start with clean domain.xml)
* asadmin create-network-listener--protocol http-listener-1
--listenerport 8009 --jkenabled true jk-connector
* Restart GF

Let me know if you still get errors.

Amy

> I followed Amy's method to bring up the GlassFish domain (see above),
> and as soon as GlassFish comes up, I look at the server.log file.
> Here's a snippet showing SEVERE error for "No class name for
> worker..." and WARNING for threadpool.max_threads_too_low (and my
> desperate plea for help):
>
> [#|2012-02-13T09:58:34.900-0800|INFO|glassfish3.1.1|org.glassfish.ha.store.spi.BackingStoreFactoryRegistry|_ThreadID=10;_ThreadName=Thread-2;|Registered
> org.glassfish.ha.store.adapter.cache.ShoalBackingStoreProxy for
> persistence-type = replicated in Bac
>
> kingStoreFactoryRegistry|#]
>
> [#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=13;_ThreadName=Thread-2;|Grizzly
> Framework 1.9.36 started in: 48ms - bound to [0.0.0.0:8080]|#]
>
> [#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=12;_ThreadName=Thread-2;|Grizzly
> Framework 1.9.36 started in: 15ms - bound to [0.0.0.0:3700]|#]
>
> [#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=14;_ThreadName=Thread-2;|Grizzly
> Framework 1.9.36 started in: 26ms - bound to [0.0.0.0:4850]|#]
>
> [#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=11;_ThreadName=Thread-2;|Grizzly
> Framework 1.9.36 started in: 10ms - bound to [0.0.0.0:7676]|#]
>
> [#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=15;_ThreadName=Thread-2;|Grizzly
> Framework 1.9.36 started in: 31ms - bound to [0.0.0.0:8181]|#]
>
> [#|2012-02-13T09:58:35.747-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.admin.adapter|_ThreadID=10;_ThreadName=Thread-2;|The
> Admin Console is already installed, but not yet loaded.|#]
>
> [#|2012-02-13T09:58:36.098-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0169:
> Created HTTP listener [http-listener-1] on host/port [0.0.0.0:8080]|#]
>
> [#|2012-02-13T09:58:36.111-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0169:
> Created HTTP listener [http-listener-2] on host/port [0.0.0.0:8181]|#]
>
> [#|2012-02-13T09:58:36.121-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0169:
> Created HTTP listener [admin-listener] on host/port [0.0.0.0:4850]|#]
>
> [#|2012-02-13T09:58:36.140-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0170:
> Apache mod_jk/jk2 attached to virtual-server [server] listening on
> port [8,009]|#]
>
> [#|2012-02-13T09:58:36.178-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0171:
> Created virtual server [server]|#]
>
> [#|2012-02-13T09:58:36.181-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0171:
> Created virtual server [__asadmin]|#]
>
> [#|2012-02-13T09:58:36.829-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0172:
> Virtual server [server] loaded default web module []|#]
>
> [#|2012-02-13T09:58:37.005-0800|SEVERE|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|No
> class name for worker.worker1 worker|#]
>
> [#|2012-02-13T09:58:37.005-0800|SEVERE|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|No
> class name for worker.worker1 worker|#]
>
> [#|2012-02-13T09:58:37.005-0800|SEVERE|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|No
> class name for worker worker|#]
>
> [#|2012-02-13T09:58:37.006-0800|SEVERE|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|No
> class name for worker.worker1 worker|#]
>
> [#|2012-02-13T09:58:37.006-0800|INFO|glassfish3.1.1|org.apache.jk.common.ChannelSocket|_ThreadID=10;_ThreadName=Thread-2;|JK:
> ajp13 listening on /0.0.0.0:8009|#]
>
> [#|2012-02-13T09:58:37.012-0800|WARNING|glassfish3.1.1|org.apache.tomcat.util.threads.ThreadPool|_ThreadID=10;_ThreadName=Thread-2;|threadpool.max_threads_too_low|#]
>
> [#|2012-02-13T09:58:37.026-0800|INFO|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|Jk
> running ID=0 time=0/32 config=null|#]
>
> [#|2012-02-13T09:58:37.603-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=10;_ThreadName=Thread-2;|core.start_container_done|#]
>
> [#|2012-02-13T09:58:37.892-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.security.com.sun.enterprise.security|_ThreadID=10;_ThreadName=Thread-2;|SEC1002:
> Security Manager is OFF.|#]
>

929 Guest
Offline
Joined: 2012-02-13

Thanks Amy, REALLY appreciate your input here. One question before I go through this process again... can you help me straighten out the use of workers.properties and/or glassfish.jk-properties files? This is my thinking process:

The Administrator Guide (see http://docs.oracle.com/cd/E18930_01/html/821-2416/ and click on the PDF link, turn to page 151, specifically step 2 and bullet #2) sa ys " apache2/conf/workers.properties or domain-dir /conf/glassfish-jk.properties (to use non-default values of attributes described at http://tomcat.apache.org/tomcat-5.5-doc/config/ajp.html )". This could be interpreted two ways:

Way 1:

Configure apache2/conf/workers.properties file. Or, if you want to use non-default values of attributes described at http://tomcat.apache.org/tomcat-5.5-doc/config/ajp.html , then configure domain-dir /conf/glassfish-jk.p roperties instead.

Way 2:

If you want to use non-default values of attributes described at http://tomcat.apache.org/tomcat-5.5-doc/config/ajp.html , then configure either domain-dir /conf/glassfish-jk.properties or apache2/conf/workers.properties file.

I interpreted this as Way 1, and since I want to adjust the default value of "maxThreads" described at http://tomcat.apache.org/tomcat-5.5-doc/config/ajp.html from 200 to 256, I am using glassfish-jk.properties file (and NOT using workers.properties file).

Here's my glassfish-jk.properties file:

worker.list=worker1

worker.worker1.type=ajp13

worker.worker1.host=localhost

worker.worker1.port=8009

maxThreads = 256

This glassfish-jk.properties file is located in the domain-dir /conf directory. I don't have any other properties files nor is this glassfish-jk.properties file located in the apache/conf directory or anywhere else. It is referenced in httpd.conf file here:

LoadModule jk_module modules/mod_jk.so

JkWorkersFile /home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties

JkLogFile /etc/httpd/logs/mod_jk.log JkLogLevel warn

JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "

JkOptions +ForwardKeySize +ForwardURICompat -ForwardDirectories

JkRequestLogFormat "%w %V %T"

Finally, when I bring up the domain again, based on your input below, I'll plan to use the following commands:

asad min> delete-http-listener jk-connector
asadmin> create-network-listener --protocol http-listener-1 --listenerport 8009 --jkenabled true jk-connector --port 4850
asadmin> set server-config.network-config.network-listeners.network-listener.jk-connector.jk-configuration-file=/home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties --port 4850

(note: I didn't set --listeneraddress 0.0.0.0, etc. when issuing create-network-listener, but let me know if I should)

Does this look OK? If not, what would you change? Then, I'll try again.

Thanks, GKK

----- Original Message -----
From: "Amy Roh"
To: users@glassfish.java.net
Sent: Monday, February 13, 2012 1:33:30 PM
Subject: Re: how to eliminate SEVERE errors (No class name for worker...) when starting up domain?

On 2/13/12 11:40 AM, modjklist@comcast.net wrote:

Hello, I just joined the mailing list and coincidently saw one of my forum posting appear at users@glassfish.java.net after I edited it. I now realize people on the mailing list may reply to the forum posting having only viewed the last posting in the forum. Thus I'm writing this email to try to summarize the complete question in one email. I'll continue to update my forum posting based on whatever I learn. One thing I don't know is if this email will trigger a new forum posting (in which case I'll close the original forum posting).

I have a new CentOS 6.2 server with fresh installs of GlassFish 3.1.1, Apache 2.2.21, mod_jk 1.2.32, and using the bug fix grizzly tar file ( see here ) to get mod_jk working. I'm using the recommended hello.war file to verify correct operation. This application runs fine when accessed externally over the internet.

However, I notice one type of SEVERE error in my server.log file, which occurs multiple times. The error appears every time I restart the domain (that is, asadmin> restart-domain --port 4850). At the bottom of this email, I cut-and-pasted a snippet of the server.log file showing this error, and I've attached the domain.xml file as well in case it helps.

QUESTION 1: How to eliminate the SEVERE errors for...
No class name for worker.worker1 worker

QUESTION 2: How to remove the WARNING related to:
threadpool.max_threads_too_low .

Which thread pool are they referring to? If I type: # asadmin> list-threadpools server admin-thread-pool
http-thread-pool
thread-pool-1 I changed the http-thread-pool max size from 5 to 200 in the admin web-console then restarted the domain, but this had no effect on the WARNING message in server.log shown below. How to remove this warning?

QUESTION 3: The official Administration Guide uses the following lines to bring up GlassFish:

asadmin> deploy /path/to/file/hello.war --port 4850
asadmin> create-http-listener --listenerport 8009 --listeneraddress 0.0.0.0 --defaultvs server gf_listener --port 4850
asadmin> create-network-listener --protocol http-listener-1 --listenerport 8009 --jkenabled true jk-connector --port 4850
asadmin> set server-config.network-config.network-listeners.network-listener.jk-connector.jk-configuration-file=/home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties --port 4850
asadmin> restart-domain --port 4850 I obtained the above lines from: go to http://docs.oracle.com/cd/E18930_01/html/821-2416/ and click on the PDF link, turn to page 151 and see Steps 5 and 6, which shows the above sequence. However, Amy's blog ( http://weblogs.java.net/blog/amyroh/archive/2009/06/running_glassfi.html ) only creates http-listener (not a network-listener), and the set command is different between the two. I assume the 3.1.1 documentation to be more relevant than Amy's blog, since this blog was written in 2009. Would LOVE to know which method is officially recommended. Here is Amy's sequence:

asadmin> deploy /path/to/file/hello.war --port 4850
asadmin> create-http-listener --listenerport 8009 --listeneraddress 0.0.0.0 --defaultvs server jk-connector --port 4850
asadmin> set configs.config.server-config.network-config.network-listeners.network-listener.jk-connector.jk-enabled=true --port 4850
asadmin> restart-domain --port 4850

I read the doc again and I agree it could be misleading to use both create-http-listener and create-network-listener. You should use either and not both. I've talked to the doc person and he will update this section to be more clear in the 3.1.2 release.

All you need to do is the following with 3.1.1 if you're not using glassfish-jk.properties file.

(1) asadmin create-network-listener --protocol http-listener-1 --listenerport 8009 --jkenabled true jk-connector
(2) restart GF

That's it.

If I use the 3.1.1 documentation, I'm not quite sure why I need to issue a create-http-listener as well as a create-network-listener. Could someone explain when one is used versus the other and if they're always both required, etc.? I couldn't find information regarding this anywhere, so I'm following the 3.1.1 Administrative Guide document to the letter. Anyway, I tried both methods, and they both result in the same problems noted above, except the 3.1.1 documentation's method duplicates the SEVERE errors twice (once for each of http-listener and network-listener), whereas Amy's method simply has SEVERE errors for the http-listener.

Here's what I placed in httpd.conf:
LoadModule jk_module /etc/httpd/modules/mod_jk.so
JkWorkersFile /home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties
JkLogFile /etc/httpd/logs/mod_jk.log
JkLogLevel debug
JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "
JkOptions +ForwardKeySize +ForwardURICompat -ForwardDirectories
JkRequestLogFormat "%w %V %T"
...
Listen 0.0.0.0:80

The glassfish-jk.properties file is: worker.list=worker1
worker.worker1.type=ajp13
worker.worker1.host=localhost
worker.worker1.port=8009
maxThreads=256

I didn't see that you set network-listener.jk-configuration-file=glassfish-jk.properties above. This isn't necessary and you can just put workers info in apache/conf.

Do you have the following workers.properties in apache/conf?
worker.list=worker1
worker.worker1.type=ajp13
worker.worker1.host=localhost
worker.worker1.port=8009
I'd suggest the following -

• Copy the above workers.properties in apache/conf
• Restart Apache
• Delete all jk listeners you created (or start with clean domain.xml)
• asadmin create-network-listener --protocol http-listener-1 --listenerport 8009 --jkenabled true jk-connector
• Restart GF

Let me know if you still get errors.

Amy

I followed Amy's method to bring up the GlassFish domain (see above), and as soon as GlassFish comes up, I look at the server.log file. Here's a snippet showing SEVERE error for "No class name for worker..." and WARNING for threadpool.max_threads_too_low (and my desperate plea for help):

[#|2012-02-13T09:58:34.900-0800|INFO|glassfish3.1.1|org.glassfish.ha.store.spi.BackingStoreFactoryRegistry|_ThreadID=10;_ThreadName=Thread-2;|Registered org.glassfish.ha.store.adapter.cache.ShoalBackingStoreProxy for persistence-type = replicated in Bac

kingStoreFactoryRegistry|#]

[#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=13;_ThreadName=Thread-2;|Grizzly Framework 1.9.36 started in: 48ms - bound to [0.0.0.0:8080]|#]

[#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=12;_ThreadName=Thread-2;|Grizzly Framework 1.9.36 started in: 15ms - bound to [0.0.0.0:3700]|#]

[#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=14;_ThreadName=Thread-2;|Grizzly Framework 1.9.36 started in: 26ms - bound to [0.0.0.0:4850]|#]

[#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=11;_ThreadName=Thread-2;|Grizzly Framework 1.9.36 started in: 10ms - bound to [0.0.0.0:7676]|#]

[#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=15;_ThreadName=Thread-2;|Grizzly Framework 1.9.36 started in: 31ms - bound to [0.0.0.0:8181]|#]

[#|2012-02-13T09:58:35.747-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.admin.adapter|_ThreadID=10;_ThreadName=Thread-2;|The Admin Console is already installed, but not yet loaded.|#]

[#|2012-02-13T09:58:36.098-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0169: Created HTTP listener [http-listener-1] on host/port [0.0.0.0:8080]|#]

[#|2012-02-13T09:58:36.111-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0169: Created HTTP listener [http-listener-2] on host/port [0.0.0.0:8181]|#]

[#|2012-02-13T09:58:36.121-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0169: Created HTTP listener [admin-listener] on host/port [0.0.0.0:4850]|#]

[#|2012-02-13T09:58:36.140-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0170: Apache mod_jk/jk2 attached to virtual-server [server] listening on port [8,009]|#]

[#|2012-02-13T09:58:36.178-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0171: Created virtual server [server]|#]

[#|2012-02-13T09:58:36.181-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0171: Created virtual server [__asadmin]|#]

[#|2012-02-13T09:58:36.829-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0172: Virtual server [server] loaded default web module []|#]

[#|2012-02-13T09:58:37.005-0800|SEVERE|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|No class name for worker.worker1 worker|#]

[#|2012-02-13T09:58:37.005-0800|SEVERE|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|No class name for worker.worker1 worker|#]

[#|2012-02-13T09:58:37.005-0800|SEVERE|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|No class name for worker worker|#]

[#|2012-02-13T09:58:37.006-0800|SEVERE|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|No class name for worker.worker1 worker|#]

[#|2012-02-13T09:58:37.006-0800|INFO|glassfish3.1.1|org.apache.jk.common.ChannelSocket|_ThreadID=10;_ThreadName=Thread-2;|JK: ajp13 listening on /0.0.0.0:8009|#]

[#|2012-02-13T09:58:37.012-0800|WARNING|glassfish3.1.1|org.apache.tomcat.util.threads.ThreadPool|_ThreadID=10;_ThreadName=Thread-2;|threadpool.max_threads_too_low|#]

[#|2012-02-13T09:58:37.026-0800|INFO|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|Jk running ID=0 time=0/32 config=null|#]

[#|2012-02-13T09:58:37.603-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=10;_ThreadName=Thread-2;|core.start_container_done|#]

[#|2012-02-13T09:58:37.892-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.security.com.sun.enterprise.security|_ThreadID=10;_ThreadName=Thread-2;|SEC1002: Security Manager is OFF.|#]

amyroh
Offline
Joined: 2004-05-06

On 2/13/12 2:14 PM, modjklist@comcast.net wrote:
> Thanks Amy, REALLY appreciate your input here. One question before I
> go through this process again... can you help me straighten out the
> use of workers.properties and/or glassfish.jk-properties files? This
> is my thinking process:
>
> The Administrator Guide
> (seehttp://docs.oracle.com/cd/E18930_01/html/821-2416/
> and
> click on the PDF link, turn to page 151, specifically step 2 and
> bullet #2) says "apache2/conf/workers.properties or
> /domain-dir//conf/glassfish-jk.properties (to use non-default values
> of attributes described at
> http://tomcat.apache.org/tomcat-5.5-doc/config/ajp.html)". This could
> be interpreted two ways:
>
> Way 1:
>
> Configure apache2/conf/workers.properties file. Or, if you want to use
> non-default values of attributes described at
> http://tomcat.apache.org/tomcat-5.5-doc/config/ajp.html, then
> configure /domain-dir//conf/glassfish-jk.properties instead.
>
> Way 2:
>
> If you want to use non-default values of attributes described at
> http://tomcat.apache.org/tomcat-5.5-doc/config/ajp.html, then
> configure either /domain-dir//conf/glassfish-jk.properties
> or apache2/conf/workers.properties file.
>
> I interpreted this as Way 1, and since I want to adjust the default
> value of "maxThreads" described
> athttp://tomcat.apache.org/tomcat-5.5-doc/config/ajp.html from 200 to
> 256, I am using glassfish-jk.properties file (and NOT using
> workers.properties file).
>
> Here's my glassfish-jk.properties file:
>
> worker.list=worker1
>
> worker.worker1.type=ajp13
>
> worker.worker1.host=localhost
>
> worker.worker1.port=8009
>
> maxThreads = 256
>

You should still configure workers.properties file. If you want to
configure additional non-default properties for connector, you can use
glassfish.jk.properties in additional to workers.properties file.

So I'd add workers.properties file with the following which should
remove 'No class name for worker.worker1 worker' error.

worker.list=worker1
worker.worker1.type=ajp13
worker.worker1.host=localhost
worker.worker1.port=800

Can you try 'asadmin set
configs.config.server-config.thread-pools.thread-pool.http-thread-pool.max-thread-pool-size=newvalue'
for the thread-pool warning?

Amy

>
> This glassfish-jk.properties file is located in the /domain-dir//conf
> directory. I don't have any other properties files nor is this
> glassfish-jk.properties file located in the apache/conf directory or
> anywhere else. It is referenced in httpd.conf file here:
>
>
> LoadModule jk_module modules/mod_jk.so
>
> JkWorkersFile
> /home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties
>
>
> JkLogFile /etc/httpd/logs/mod_jk.log
>
> JkLogLevel warn
>
> JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "
>
> JkOptions +ForwardKeySize +ForwardURICompat
> -ForwardDirectories
>
> JkRequestLogFormat "%w %V %T"
>
>
> Finally, when I bring up the domain again, based on your input below,
> I'll plan to use the following commands:
>
> asadmin> delete-http-listener jk-connector
> asadmin> create-network-listener --protocol http-listener-1
> --listenerport 8009 --jkenabled true jk-connector --port 4850
> asadmin> set
> server-config.network-config.network-listeners.network-listener.jk-connector.jk-configuration-file=/home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties
> --port 4850
>
> (note: I didn't set --listeneraddress 0.0.0.0, etc. when issuing
> create-network-listener, but let me know if I should)
>
> Does this look OK? If not, what would you change? Then, I'll try again.
>
> Thanks, GKK
>

929 Guest
Offline
Joined: 2012-02-13

Hi Amy, I'll add a workers.properties file as well (you might make a note to clarify this in the Administration Guide). I guess this opens the question -- should the glassfish-jk.properties file then contain everything the workers.properties file contains PLUS the additional attributes such as maxThreads (or just those additional attributes such as MaxThreads, and not worker.list=worker1, worker.worker1.type=ajp13, etc.)?

Also, I previously used the GlassFish web-console (port 4850 for me) to manually adjust the "max thread pool size" for http-thread-pool from 5 to 200 (which didn't improve the thread size warning). Will your recommended command,

asadmin set configs.config.server-config.thread-pools.thread-pool.http-thread-pool.max-thread-pool-size=newvalue'

attempt to do the same thing (assuming I use 200 for "new value")? The max size for admin-thread-pool is 50 and thread-pool-1 is 200, so none of these 3 thread pools should be the issue (that is, unless the thread pool size is supposed to update from default values at a time later than the warning message issues).

Lastly, I'll use the following commands as mentioned below unless you recommend otherwise:

asad min> delete-http-listener jk-connector
asadmin> create-network-listener --protocol http-listener-1 --listenerport 8009 --jkenabled true jk-connector --port 4850
asadmin> set server-config.network-config.network-listeners.network-listener.jk-connector.jk-configuration-file=/home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties --port 4850

Thanks, GKK

----- Original Message -----
From: "Amy Roh"
To: modjklist@comcast.net
Cc: users@glassfish.java.net
Sent: Monday, February 13, 2012 3:18:40 PM
Subject: Re: how to eliminate SEVERE errors (No class name for worker...) when starting up domain?

On 2/13/12 2:14 PM, modjklist@comcast.net wrote:

Thanks Amy, REALLY appreciate your input here. One question before I go through this process again... can you help me straighten out the use of workers.properties and/or glassfish.jk-properties files? This is my thinking process:

The Administrator Guide (see http://docs.oracle.com/cd/E18930_01/html/821-2416/ and click on the PDF link, turn to page 151, specifically step 2 and bullet #2) says " apache2/conf/workers.properties or domain-dir /conf/glassfish-jk.properties (to use non-default values of attributes described at http://tomcat.apache.org/tomcat-5.5-doc/config/ajp.html )". This could be interpreted two ways:

Way 1:

Configure apache2/conf/workers.properties file. Or, if you want to use non-default values of attributes described at http://tomcat.apache.org/tomcat-5.5-doc/config/ajp.html , then configure domain-dir /conf/glassfish-jk.properties instead.

Way 2:

If you want to use non-default values of attributes described at http://tomcat.apache.org/tomcat-5.5-doc/config/ajp.html , then configure either domain-dir /conf/glassfish-jk.properties or apache2/conf/workers.properties file.

I interpreted this as Way 1, and since I want to adjust the default value of "maxThreads" described at http://tomcat.apache.org/tomcat-5.5-doc/config/ajp.html from 200 to 256, I am using glassfish-jk.properties file (and NOT using workers.properties file).

Here's my glassfish-jk.properties file:

worker.list=worker1

worker.worker1.type=ajp13

worker.worker1.host=localhost

worker.worker1.port=8009

maxThreads = 256

You should still configure workers.properties file. If you want to configure additional non-default properties for connector, you can use glassfish.jk.properties in additional to workers.properties file.

So I'd add workers.properties file with the following which should remove 'No class name for worker.worker1 worker' error. worker.list=worker1
worker.worker1.type=ajp13
worker.worker1.host=localhost
worker.worker1.port=800
Can you try 'asadmin set configs.config.server-config.thread-pools.thread-pool.http-thread-pool.max-thread-pool-size=newvalue' for the thread-pool warning?

Amy

This glassfish-jk.properties file is located in the domain-dir /conf directory. I don't have any other properties files nor is this glassfish-jk.properties file located in the apache/conf directory or anywhere else. It is referenced in httpd.conf file here:

LoadModule jk_module modules/mod_jk.so

JkWorkersFile /home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties

JkLogFile /etc/httpd/logs/mod_jk.log JkLogLevel warn

JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "

JkOptions +ForwardKeySize +ForwardURICompat -ForwardDirectories

JkRequestLogFormat "%w %V %T"

Finally, when I bring up the domain again, based on your input below, I'll plan to use the following commands:

asad min> delete-http-listener jk-connector
asadmin> create-network-listener --protocol http-listener-1 --listenerport 8009 --jkenabled true jk-connector --port 4850
asadmin> set server-config.network-config.network-listeners.network-listener.jk-connector.jk-configuration-file=/home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties --port 4850

(note: I didn't set --listeneraddress 0.0.0.0, etc. when issuing create-network-listener, but let me know if I should)

Does this look OK? If not, what would you change? Then, I'll try again.

Thanks, GKK

----- Original Message -----
From: "Amy Roh"
To: users@glassfish.java.net
Sent: Monday, February 13, 2012 1:33:30 PM
Subject: Re: how to eliminate SEVERE errors (No class name for worker...) when starting up domain?

On 2/13/12 11:40 AM, modjklist@comcast.net wrote:

Hello, I just joined the mailing list and coincidently saw one of my forum posting appear at users@glassfish.java.net after I edited it. I now realize people on the mailing list may reply to the forum posting having only viewed the last posting in the forum. Thus I'm writing this email to try to summarize the complete question in one email. I'll continue to update my forum posting based on whatever I learn. One thing I don't know is if this email will trigger a new forum posting (in which case I'll close the original forum posting).

I have a new CentOS 6.2 server with fresh installs of GlassFish 3.1.1, Apache 2.2.21, mod_jk 1.2.32, and using the bug fix grizzly tar file ( see here ) to get mod_jk working. I'm using the recommended hello.war file to verify correct operation. This application runs fine when accessed externally over the internet.

However, I notice one type of SEVERE error in my server.log file, which occurs multiple times. The error appears every time I restart the domain (that is, asadmin> restart-domain --port 4850). At the bottom of this email, I cut-and-pasted a snippet of the server.log file showing this error, and I've attached the domain.xml file as well in case it helps.

QUESTION 1: How to eliminate the SEVERE errors for...
No class name for worker.worker1 worker

QUESTION 2: How to remove the WARNING related to:
threadpool.max_threads_too_low .

Which thread pool are they referring to? If I type: # asadmin> list-threadpools server admin-thread-pool
http-thread-pool
thread-pool-1 I changed the http-thread-pool max size from 5 to 200 in the admin web-console then restarted the domain, but this had no effect on the WARNING message in server.log shown below. How to remove this warning?

QUESTION 3: The official Administration Guide uses the following lines to bring up GlassFish:

asadmin> deploy /path/to/file/hello.war --port 4850
asadmin> create-http-listener --listenerport 8009 --listeneraddress 0.0.0.0 --defaultvs server gf_listener --port 4850
asadmin> create-network-listener --protocol http-listener-1 --listenerport 8009 --jkenabled true jk-connector --port 4850
asadmin> set server-config.network-config.network-listeners.network-listener.jk-connector.jk-configuration-file=/home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties --port 4850
asadmin> restart-domain --port 4850 I obtained the above lines from: go to http://docs.oracle.com/cd/E18930_01/html/821-2416/ and click on the PDF link, turn to page 151 and see Steps 5 and 6, which shows the above sequence. However, Amy's blog ( http://weblogs.java.net/blog/amyroh/archive/2009/06/running_glassfi.html ) only creates http-listener (not a network-listener), and the set command is different between the two. I assume the 3.1.1 documentation to be more relevant than Amy's blog, since this blog was written in 2009. Would LOVE to know which method is officially recommended. Here is Amy's sequence:

asadmin> deploy /path/to/file/hello.war --port 4850
asadmin> create-http-listener --listenerport 8009 --listeneraddress 0.0.0.0 --defaultvs server jk-connector --port 4850
asadmin> set configs.config.server-config.network-config.network-listeners.network-listener.jk-connector.jk-enabled=true --port 4850
asadmin> restart-domain --port 4850

I read the doc again and I agree it could be misleading to use both create-http-listener and create-network-listener. You should use either and not both. I've talked to the doc person and he will update this section to be more clear in the 3.1.2 release.

All you need to do is the following with 3.1.1 if you're not using glassfish-jk.properties file.

(1) asadmin create-network-listener --protocol http-listener-1 --listenerport 8009 --jkenabled true jk-connector
(2) restart GF

That's it.

If I use the 3.1.1 documentation, I'm not quite sure why I need to issue a create-http-listener as well as a create-network-listener. Could someone explain when one is used versus the other and if they're always both required, etc.? I couldn't find information regarding this anywhere, so I'm following the 3.1.1 Administrative Guide document to the letter. Anyway, I tried both methods, and they both result in the same problems noted above, except the 3.1.1 documentation's method duplicates the SEVERE errors twice (once for each of http-listener and network-listener), whereas Amy's method simply has SEVERE errors for the http-listener.

Here's what I placed in httpd.conf:
LoadModule jk_module /etc/httpd/modules/mod_jk.so
JkWorkersFile /home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties
JkLogFile /etc/httpd/logs/mod_jk.log
JkLogLevel debug
JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "
JkOptions +ForwardKeySize +ForwardURICompat -ForwardDirectories
JkRequestLogFormat "%w %V %T"
...
Listen 0.0.0.0:80

The glassfish-jk.properties file is: worker.list=worker1
worker.worker1.type=ajp13
worker.worker1.host=localhost
worker.worker1.port=8009
maxThreads=256

I didn't see that you set network-listener.jk-configuration-file=glassfish-jk.properties above. This isn't necessary and you can just put workers info in apache/conf.

Do you have the following workers.properties in apache/conf?
worker.list=worker1
worker.worker1.type=ajp13
worker.worker1.host=localhost
worker.worker1.port=8009
I'd suggest the following -

• Copy the above workers.properties in apache/conf
• Restart Apache
• Delete all jk listeners you created (or start with clean domain.xml)
• asadmin create-network-listener --protocol http-listener-1 --listenerport 8009 --jkenabled true jk-connector
• Restart GF
Let me know if you still get errors.

Amy

I followed Amy's method to bring up the GlassFish domain (see above), and as soon as GlassFish comes up, I look at the server.log file. Here's a snippet showing SEVERE error for "No class name for worker..." and WARNING for threadpool.max_threads_too_low (and my desperate plea for help):

[#|2012-02-13T09:58:34.900-0800|INFO|glassfish3.1.1|org.glassfish.ha.store.spi.BackingStoreFactoryRegistry|_ThreadID=10;_ThreadName=Thread-2;|Registered org.glassfish.ha.store.adapter.cache.ShoalBackingStoreProxy for persistence-type = replicated in Bac

kingStoreFactoryRegistry|#]

[#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=13;_ThreadName=Thread-2;|Grizzly Framework 1.9.36 started in: 48ms - bound to [0.0.0.0:8080]|#]

[#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=12;_ThreadName=Thread-2;|Grizzly Framework 1.9.36 started in: 15ms - bound to [0.0.0.0:3700]|#]

[#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=14;_ThreadName=Thread-2;|Grizzly Framework 1.9.36 started in: 26ms - bound to [0.0.0.0:4850]|#]

[#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=11;_ThreadName=Thread-2;|Grizzly Framework 1.9.36 started in: 10ms - bound to [0.0.0.0:7676]|#]

[#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=15;_ThreadName=Thread-2;|Grizzly Framework 1.9.36 started in: 31ms - bound to [0.0.0.0:8181]|#]

[#|2012-02-13T09:58:35.747-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.admin.adapter|_ThreadID=10;_ThreadName=Thread-2;|The Admin Console is already installed, but not yet loaded.|#]

[#|2012-02-13T09:58:36.098-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0169: Created HTTP listener [http-listener-1] on host/port [0.0.0.0:8080]|#]

[#|2012-02-13T09:58:36.111-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0169: Created HTTP listener [http-listener-2] on host/port [0.0.0.0:8181]|#]

[#|2012-02-13T09:58:36.121-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0169: Created HTTP listener [admin-listener] on host/port [0.0.0.0:4850]|#]

[#|2012-02-13T09:58:36.140-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0170: Apache mod_jk/jk2 attached to virtual-server [server] listening on port [8,009]|#]

[#|2012-02-13T09:58:36.178-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0171: Created virtual server [server]|#]

[#|2012-02-13T09:58:36.181-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0171: Created virtual server [__asadmin]|#]

[#|2012-02-13T09:58:36.829-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0172: Virtual server [server] loaded default web module []|#]

[#|2012-02-13T09:58:37.005-0800|SEVERE|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|No class name for worker.worker1 worker|#]

[#|2012-02-13T09:58:37.005-0800|SEVERE|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|No class name for worker.worker1 worker|#]

[#|2012-02-13T09:58:37.005-0800|SEVERE|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|No class name for worker worker|#]

[#|2012-02-13T09:58:37.006-0800|SEVERE|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|No class name for worker.worker1 worker|#]

[#|2012-02-13T09:58:37.006-0800|INFO|glassfish3.1.1|org.apache.jk.common.ChannelSocket|_ThreadID=10;_ThreadName=Thread-2;|JK: ajp13 listening on /0.0.0.0:8009|#]

[#|2012-02-13T09:58:37.012-0800|WARNING|glassfish3.1.1|org.apache.tomcat.util.threads.ThreadPool|_ThreadID=10;_ThreadName=Thread-2;|threadpool.max_threads_too_low|#]

[#|2012-02-13T09:58:37.026-0800|INFO|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|Jk running ID=0 time=0/32 config=null|#]

[#|2012-02-13T09:58:37.603-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=10;_ThreadName=Thread-2;|core.start_container_done|#]

[#|2012-02-13T09:58:37.892-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.security.com.sun.enterprise.security|_ThreadID=10;_ThreadName=Thread-2;|SEC1002: Security Manager is OFF.|#]

amyroh
Offline
Joined: 2004-05-06

On 2/13/12 3:38 PM, modjklist@comcast.net wrote:
> Hi Amy, I'll add a workers.properties file as well (you might make a
> note to clarify this in the Administration Guide). I guess this opens
> the question -- should the glassfish-jk.properties file then contain
> everything the workers.properties file contains PLUS the additional
> attributes such as maxThreads (or just those additional attributes
> such as MaxThreads, and not worker.list=worker1,
> worker.worker1.type=ajp13, etc.)?
glassfish-jk.properties is for Connector attributes only so you
shouldn't put worker info there.

>
> Also, I previously used the GlassFish web-console (port 4850 for me)
> to manually adjust the "max thread pool size" for http-thread-pool
> from 5 to 200 (which didn't improve the thread size warning). Will
> your recommended command,
I didn't see that you already did this. If you'd done admin console to
update then asadmin set isn't necessary.

Amy

>
> asadmin set
> configs.config.server-config.thread-pools.thread-pool.http-thread-pool.max-thread-pool-size=newvalue'
>
> attempt to do the same thing (assuming I use 200 for "new value")? The
> max size for admin-thread-pool is 50 and thread-pool-1 is 200, so none
> of these 3 thread pools should be the issue (that is, unless the
> thread pool size is supposed to update from default values at a time
> later than the warning message issues).
>
> Lastly, I'll use the following commands as mentioned below unless you
> recommend otherwise:
>
> asadmin> delete-http-listener jk-connector
> asadmin> create-network-listener --protocol http-listener-1
> --listenerport 8009 --jkenabled true jk-connector --port 4850
> asadmin> set
> server-config.network-config.network-listeners.network-listener.jk-connector.jk-configuration-file=/home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties
> --port 4850
>
> Thanks, GKK
>

929 Guest
Offline
Joined: 2012-02-13

Hi Amy,

Over the last week I tried to find examples for setting connector attributes using glassfish-jk.properties, but could find much. Most of the time I see things like this (scroll down to bottom):

http://code.google.com/p/eid-archetype/wiki/UsageJavaEE6

where the ONLY thing inside the glassfish-jk.properties file are worker info.

Example 6-5 here http://docs.oracle.com/cd/E18930_01/html/821-2416/gfaad.html is also misleading when it says " This example shows a workers.properties or glassfish-jk.properties file that is set for mod_jk ."

Do you have an example glassfish-jk.properties file you could send me? I want to see the correct syntax for setting attributes.

For example, should the glassfish-jk.properties file be:

protocol=AJP/1.3
maxThread=256

or,

protocol="AJP/1.3"
maxThreads="256"

or something else(?).

Maybe I missed this in the documentation somewhere? Thanks, GKK

----- Original Message -----
From: "Amy Roh"
To: users@glassfish.java.net
Sent: Monday, February 13, 2012 3:56:06 PM
Subject: Re: how to eliminate SEVERE errors (No class name for worker...) when starting up domain?

On 2/13/12 3:38 PM, modjklist@comcast.net wrote:

Hi Amy, I'll add a workers.properties file as well (you might make a note to clarify this in the Administration Guide). I guess this opens the question -- should the glassfish-jk.properties file then contain everything the workers.properties file contains PLUS the additional attributes such as maxThreads (or just those additional attributes such as MaxThreads, and not worker.list=worker1, worker.worker1.type=ajp13, etc.)?

glassfish-jk.properties is for Connector attributes only so you shouldn't put worker info there.

Also, I previously used the GlassFish web-console (port 4850 for me) to manually adjust the "max thread pool size" for http-thread-pool from 5 to 200 (which didn't improve the thread size warning). Will your recommended command,

I didn't see that you already did this. If you'd done admin console to update then asadmin set isn't necessary.

Amy

asadmin set configs.config.server-config.thread-pools.thread-pool.http-thread-pool.max-thread-pool-size=newvalue'

attempt to do the same thing (assuming I use 200 for "new value")? The max size for admin-thread-pool is 50 and thread-pool-1 is 200, so none of these 3 thread pools should be the issue (that is, unless the thread pool size is supposed to update from default values at a time later than the warning message issues).

Lastly, I'll use the following commands as mentioned below unless you recommend otherwise:

asad min> delete-http-listener jk-connector
asadmin> create-network-listener --protocol http-listener-1 --listenerport 8009 --jkenabled true jk-connector --port 4850
asadmin> set server-config.network-config.network-listeners.network-listener.jk-connector.jk-configuration-file=/home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties --port 4850

Thanks, GKK

----- Original Message -----
From: "Amy Roh"
To: modjklist@comcast.net
Cc: users@glassfish.java.net
Sent: Monday, February 13, 2012 3:18:40 PM
Subject: Re: how to eliminate SEVERE errors (No class name for worker...) when starting up domain?

On 2/13/12 2:14 PM, modjklist@comcast.net wrote:

Thanks Amy, REALLY appreciate your input here. One question before I go through this process again... can you help me straighten out the use of workers.properties and/or glassfish.jk-properties files? This is my thinking process:

The Administrator Guide (see http://docs.oracle.com/cd/E18930_01/html/821-2416/ and click on the PDF link, turn to page 151, specifically step 2 and bullet #2) says " apache2/conf/workers.properties or domain-dir /conf/glassfish-jk.properties (to use non-default values of attributes described at http://tomcat.apache.org/tomcat-5.5-doc/config/ajp.html )". This could be interpreted two ways:

Way 1:

Configure apache2/conf/workers.properties file. Or, if you want to use non-default values of attributes described at http://tomcat.apache.org/tomcat-5.5-doc/config/ajp.html , then configure domain-dir /conf/glassfish-jk.properties instead.

Way 2:

If you want to use non-default values of attributes described at http://tomcat.apache.org/tomcat-5.5-doc/config/ajp.html , then configure either domain-dir /conf/glassfish-jk.properties or apache2/conf/workers.properties file.

I interpreted this as Way 1, and since I want to adjust the default value of "maxThreads" described at http://tomcat.apache.org/tomcat-5.5-doc/config/ajp.html from 200 to 256, I am using glassfish-jk.properties file (and NOT using workers.properties file).

Here's my glassfish-jk.properties file:

worker.list=worker1

worker.worker1.type=ajp13

worker.worker1.host=localhost

worker.worker1.port=8009

maxThreads = 256

You should still configure workers.properties file. If you want to configure additional non-default properties for connector, you can use glassfish.jk.properties in additional to workers.properties file.

So I'd add workers.properties file with the following which should remove 'No class name for worker.worker1 worker' error. worker.list=worker1
worker.worker1.type=ajp13
worker.worker1.host=localhost
worker.worker1.port=800
Can you try 'asadmin set configs.config.server-config.thread-pools.thread-pool.http-thread-pool.max-thread-pool-size=newvalue' for the thread-pool warning?

Amy

This glassfish-jk.properties file is located in the domain-dir /conf directory. I don't have any other properties files nor is this glassfish-jk.properties file located in the apache/conf directory or anywhere else. It is referenced in httpd.conf file here:

LoadModule jk_module modules/mod_jk.so

JkWorkersFile /home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties

JkLogFile /etc/httpd/logs/mod_jk.log JkLogLevel warn

JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "

JkOptions +ForwardKeySize +ForwardURICompat -ForwardDirectories

JkRequestLogFormat "%w %V %T"

Finally, when I bring up the domain again, based on your input below, I'll plan to use the following commands:

asad min> delete-http-listener jk-connector
asadmin> create-network-listener --protocol http-listener-1 --listenerport 8009 --jkenabled true jk-connector --port 4850
asadmin> set server-config.network-config.network-listeners.network-listener.jk-connector.jk-configuration-file=/home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties --port 4850

(note: I didn't set --listeneraddress 0.0.0.0, etc. when issuing create-network-listener, but let me know if I should)

Does this look OK? If not, what would you change? Then, I'll try again.

Thanks, GKK

----- Original Message -----
From: "Amy Roh"
To: users@glassfish.java.net
Sent: Monday, February 13, 2012 1:33:30 PM
Subject: Re: how to eliminate SEVERE errors (No class name for worker...) when starting up domain?

On 2/13/12 11:40 AM, modjklist@comcast.net wrote:

Hello, I just joined the mailing list and coincidently saw one of my forum posting appear at users@glassfish.java.net after I edited it. I now realize people on the mailing list may reply to the forum posting having only viewed the last posting in the forum. Thus I'm writing this email to try to summarize the complete question in one email. I'll continue to update my forum posting based on whatever I learn. One thing I don't know is if this email will trigger a new forum posting (in which case I'll close the original forum posting).

I have a new CentOS 6.2 server with fresh installs of GlassFish 3.1.1, Apache 2.2.21, mod_jk 1.2.32, and using the bug fix grizzly tar file ( see here ) to get mod_jk working. I'm using the recommended hello.war file to verify correct operation. This application runs fine when accessed externally over the internet.

However, I notice one type of SEVERE error in my server.log file, which occurs multiple times. The error appears every time I restart the domain (that is, asadmin> restart-domain --port 4850). At the bottom of this email, I cut-and-pasted a snippet of the server.log file showing this error, and I've attached the domain.xml file as well in case it helps.

QUESTION 1: How to eliminate the SEVERE errors for...
No class name for worker.worker1 worker

QUESTION 2: How to remove the WARNING related to:
threadpool.max_threads_too_low .

Which thread pool are they referring to? If I type: # asadmin> list-threadpools server admin-thread-pool
http-thread-pool
thread-pool-1 I changed the http-thread-pool max size from 5 to 200 in the admin web-console then restarted the domain, but this had no effect on the WARNING message in server.log shown below. How to remove this warning?

QUESTION 3: The official Administration Guide uses the following lines to bring up GlassFish:

asadmin> deploy /path/to/file/hello.war --port 4850
asadmin> create-http-listener --listenerport 8009 --listeneraddress 0.0.0.0 --defaultvs server gf_listener --port 4850
asadmin> create-network-listener --protocol http-listener-1 --listenerport 8009 --jkenabled true jk-connector --port 4850
asadmin> set server-config.network-config.network-listeners.network-listener.jk-connector.jk-configuration-file=/home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties --port 4850
asadmin> restart-domain --port 4850 I obtained the above lines from: go to http://docs.oracle.com/cd/E18930_01/html/821-2416/ and click on the PDF link, turn to page 151 and see Steps 5 and 6, which shows the above sequence. However, Amy's blog ( http://weblogs.java.net/blog/amyroh/archive/2009/06/running_glassfi.html ) only creates http-listener (not a network-listener), and the set command is different between the two. I assume the 3.1.1 documentation to be more relevant than Amy's blog, since this blog was written in 2009. Would LOVE to know which method is officially recommended. Here is Amy's sequence:

asadmin> deploy /path/to/file/hello.war --port 4850
asadmin> create-http-listener --listenerport 8009 --listeneraddress 0.0.0.0 --defaultvs server jk-connector --port 4850
asadmin> set configs.config.server-config.network-config.network-listeners.network-listener.jk-connector.jk-enabled=true --port 4850
asadmin> restart-domain --port 4850

I read the doc again and I agree it could be misleading to use both create-http-listener and create-network-listener. You should use either and not both. I've talked to the doc person and he will update this section to be more clear in the 3.1.2 release.

All you need to do is the following with 3.1.1 if you're not using glassfish-jk.properties file.

(1) asadmin create-network-listener --protocol http-listener-1 --listenerport 8009 --jkenabled true jk-connector
(2) restart GF

That's it.

If I use the 3.1.1 documentation, I'm not quite sure why I need to issue a create-http-listener as well as a create-network-listener. Could someone explain when one is used versus the other and if they're always both required, etc.? I couldn't find information regarding this anywhere, so I'm following the 3.1.1 Administrative Guide document to the letter. Anyway, I tried both methods, and they both result in the same problems noted above, except the 3.1.1 documentation's method duplicates the SEVERE errors twice (once for each of http-listener and network-listener), whereas Amy's method simply has SEVERE errors for the http-listener.

Here's what I placed in httpd.conf:
LoadModule jk_module /etc/httpd/modules/mod_jk.so
JkWorkersFile /home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties
JkLogFile /etc/httpd/logs/mod_jk.log
JkLogLevel debug
JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "
JkOptions +ForwardKeySize +ForwardURICompat -ForwardDirectories
JkRequestLogFormat "%w %V %T"
...
Listen 0.0.0.0:80

The glassfish-jk.properties file is: worker.list=worker1
worker.worker1.type=ajp13
worker.worker1.host=localhost
worker.worker1.port=8009
maxThreads=256

I didn't see that you set network-listener.jk-configuration-file=glassfish-jk.properties above. This isn't necessary and you can just put workers info in apache/conf.

Do you have the following workers.properties in apache/conf?
worker.list=worker1
worker.worker1.type=ajp13
worker.worker1.host=localhost
worker.worker1.port=8009
I'd suggest the following -

• Copy the above workers.properties in apache/conf
• Restart Apache
• Delete all jk listeners you created (or start with clean domain.xml)
• asadmin create-network-listener --protocol http-listener-1 --listenerport 8009 --jkenabled true jk-connector
• Restart GF
Let me know if you still get errors.

Amy

I followed Amy's method to bring up the GlassFish domain (see above), and as soon as GlassFish comes up, I look at the server.log file. Here's a snippet showing SEVERE error for "No class name for worker..." and WARNING for threadpool.max_threads_too_low (and my desperate plea for help):

[#|2012-02-13T09:58:34.900-0800|INFO|glassfish3.1.1|org.glassfish.ha.store.spi.BackingStoreFactoryRegistry|_ThreadID=10;_ThreadName=Thread-2;|Registered org.glassfish.ha.store.adapter.cache.ShoalBackingStoreProxy for persistence-type = replicated in Bac

kingStoreFactoryRegistry|#]

[#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=13;_ThreadName=Thread-2;|Grizzly Framework 1.9.36 started in: 48ms - bound to [0.0.0.0:8080]|#]

[#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=12;_ThreadName=Thread-2;|Grizzly Framework 1.9.36 started in: 15ms - bound to [0.0.0.0:3700]|#]

[#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=14;_ThreadName=Thread-2;|Grizzly Framework 1.9.36 started in: 26ms - bound to [0.0.0.0:4850]|#]

[#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=11;_ThreadName=Thread-2;|Grizzly Framework 1.9.36 started in: 10ms - bound to [0.0.0.0:7676]|#]

[#|2012-02-13T09:58:35.676-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=15;_ThreadName=Thread-2;|Grizzly Framework 1.9.36 started in: 31ms - bound to [0.0.0.0:8181]|#]

[#|2012-02-13T09:58:35.747-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.admin.adapter|_ThreadID=10;_ThreadName=Thread-2;|The Admin Console is already installed, but not yet loaded.|#]

[#|2012-02-13T09:58:36.098-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0169: Created HTTP listener [http-listener-1] on host/port [0.0.0.0:8080]|#]

[#|2012-02-13T09:58:36.111-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0169: Created HTTP listener [http-listener-2] on host/port [0.0.0.0:8181]|#]

[#|2012-02-13T09:58:36.121-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0169: Created HTTP listener [admin-listener] on host/port [0.0.0.0:4850]|#]

[#|2012-02-13T09:58:36.140-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0170: Apache mod_jk/jk2 attached to virtual-server [server] listening on port [8,009]|#]

[#|2012-02-13T09:58:36.178-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0171: Created virtual server [server]|#]

[#|2012-02-13T09:58:36.181-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0171: Created virtual server [__asadmin]|#]

[#|2012-02-13T09:58:36.829-0800|INFO|glassfish3.1.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=10;_ThreadName=Thread-2;|WEB0172: Virtual server [server] loaded default web module []|#]

[#|2012-02-13T09:58:37.005-0800|SEVERE|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|No class name for worker.worker1 worker|#]

[#|2012-02-13T09:58:37.005-0800|SEVERE|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|No class name for worker.worker1 worker|#]

[#|2012-02-13T09:58:37.005-0800|SEVERE|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|No class name for worker worker|#]

[#|2012-02-13T09:58:37.006-0800|SEVERE|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|No class name for worker.worker1 worker|#]

[#|2012-02-13T09:58:37.006-0800|INFO|glassfish3.1.1|org.apache.jk.common.ChannelSocket|_ThreadID=10;_ThreadName=Thread-2;|JK: ajp13 listening on /0.0.0.0:8009|#]

[#|2012-02-13T09:58:37.012-0800|WARNING|glassfish3.1.1|org.apache.tomcat.util.threads.ThreadPool|_ThreadID=10;_ThreadName=Thread-2;|threadpool.max_threads_too_low|#]

[#|2012-02-13T09:58:37.026-0800|INFO|glassfish3.1.1|org.apache.jk.server.JkMain|_ThreadID=10;_ThreadName=Thread-2;|Jk running ID=0 time=0/32 config=null|#]

[#|2012-02-13T09:58:37.603-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.com.sun.enterprise.v3.services.impl|_ThreadID=10;_ThreadName=Thread-2;|core.start_container_done|#]

[#|2012-02-13T09:58:37.892-0800|INFO|glassfish3.1.1|javax.enterprise.system.core.security.com.sun.enterprise.security|_ThreadID=10;_ThreadName=Thread-2;|SEC1002: Security Manager is OFF.|#]

amyroh
Offline
Joined: 2004-05-06

On 2/13/12 4:37 PM, modjklist@comcast.net wrote:
> Hi Amy,
>
> Over the last week I tried to find examples for setting connector
> attributes using glassfish-jk.properties, but could find much. Most of
> the time I see things like this (scroll down to bottom):
>
> http://code.google.com/p/eid-archetype/wiki/UsageJavaEE6
>
> where the ONLY thing inside the glassfish-jk.properties file are
> worker info.
>
> Example 6-5 here
> http://docs.oracle.com/cd/E18930_01/html/821-2416/gfaad.html is also
> misleading when it says "This example shows a workers.properties*or
> glassfish-jk.properties file*that is set for mod_jk."

I see where you're getting mislead. There should be two properties
files. One for workers (referenced by JkWorkersFilefrom httpd.conf) and
another one for Connector (referenced by
server-config.network-config.network-listeners.network-listener.jk-connector.jk-configuration-file).
The above example uses glassfish-jk.properties as the file name for
JkWorkersFile to define workers info where I was using
glassfish-jk.properties name to refer to the other (Connector attributes).

Try adding the following to apache/conf/httpd.conf and add worker info
in workers.properties

JkWorkersFile conf/workers.properties

Add maxThreads=256 to glassfish-jk.properties and set it either using
admin console or asadmin set command.

set
server-config.network-config.network-listeners.network-listener.jk-connector.jk-configuration-file=/home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties

You can find the format of Properties from
http://docs.oracle.com/javase/6/docs/api/java/util/Properties.html. See
load for key/element examples.

I will relay this input to the docs team to update the docs to be more
clear in the next release.

Thanks,
Amy

>
> Do you have an example glassfish-jk.properties file you could send me?
> I want to see the correct syntax for setting attributes.
>
> For example, should the glassfish-jk.properties file be:
>
> protocol=AJP/1.3
> maxThread=256
>
> or,
>
> protocol="AJP/1.3"
> maxThreads="256"
>
> or something else(?).
>
> Maybe I missed this in the documentation somewhere? Thanks, GKK
>
>

929 Guest
Offline
Joined: 2012-02-13

Hi Amy,

Thanks for all the help! The SEVERE errors disappeared by including the apache/conf/workers.properties file as you expected (yay!).

I even eliminated the WARNING for threadpool.max_threads_too_low because I had mistakenly increased the Default configuration rather than the Server configuration's settings in the web console (after I increased the server configuration's settings the warning went away).

Some follow-up questions:

1. Do my final (and complete) configuration settings below look OK?

asadmin> start-domain --port 4850
asadmin> deploy /home/glassfish/apps/hello.war --port 4850

asadmin> create-net wor k-listener --protocol http-listener-1 --listenerport 8009 --jkenabled true jk-connector --port 4850

asadmin> set server-config.network-config.network-listeners.network-listener.jk-connector.jk-configuration-file=/home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties --port 4850

asadmin> create-jvm-options -Dcom.sun.enterprise.web.connector.enableJK.propertyFile=/home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties --port 4850

asadmin> restart-domain --port 4850

We didn't talk about the 2nd to last line above (e.g. create-jvm-options), but it's mentioned in step 7 here: http://docs.oracle.com/cd/E18930_01/html/821-2416/gfaad.html

2. Can you give specific details on how to exactly set maxThreads using the admin console? For example, how to navigate to the screen where the setting may be input, and which fields to fill out what, etc.?

Thanks so much, -GKK

----- Original Message -----
From: "Amy Roh"
To: users@glassfish.java.net
Sent: Monday, February 13, 2012 5:09:37 PM
Subject: Re: how to eliminate SEVERE errors (No class name for worker...) when starting up domain?

On 2/13/12 4:37 PM, modjklist@comcast.net wrote:

Hi Amy,

Over the last week I tried to find examples for setting connector attributes using glassfish-jk.properties, but could find much. Most of the time I see things like this (scroll down to bottom):

http://code.google.com/p/eid-archetype/wiki/UsageJavaEE6

where the ONLY thing inside the glassfish-jk.properties file are worker info.

Example 6-5 here http://docs.oracle.com/cd/E18930_01/html/821-2416/gfaad.html is also misleading when it says " This example shows a workers.properties or glassfish-jk.properties file that is set for mod_jk ."

I see where you're getting mislead. There should be two properties files. One for workers (referenced by JkWorkersFile from httpd.conf) and another one for Connector (referenced by server-config.network-config.network-listeners.network-listener.jk-connector.jk-configuration-file). The above example uses glassfish-jk.properties as the file name for JkWorkersFile to define workers info where I was using glassfish-jk.properties name to refer to the other (Connector attributes).

Try adding the following to apache/conf/httpd.conf and add worker info in workers.properties

JkWorkersFile conf/workers.properties

Add maxThreads=256 to glassfish-jk.properties and set it either using admin console or asadmin set command.

set server-config.network-config.network-listeners.network-listener.jk-connector.jk-configuration-file=/home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties

You can find the format of Properties from http://docs.oracle.com/javase/6/docs/api/java/util/Properties.html . See load for key/element examples.

I will relay this input to the docs team to update the docs to be more clear in the next release.

Thanks,
Amy

Do you have an example glassfish-jk.properties file you could send me? I want to see the correct syntax for setting attributes.

For example, should the glassfish-jk.properties file be:

protocol=AJP/1.3
maxThread=256

or,

protocol="AJP/1.3"
maxThreads="256"

or something else(?).

Maybe I missed this in the documentation somewhere? Thanks, GKK

----- Original Message -----
From: "Amy Roh"
To: users@glassfish.java.net
Sent: Monday, February 13, 2012 3:56:06 PM
Subject: Re: how to eliminate SEVERE errors (No class name for worker...) when starting up domain?

On 2/13/12 3:38 PM, modjklist@comcast.net wrote:

Hi Amy, I'll add a workers.properties file as well (you might make a note to clarify this in the Administration Guide). I guess this opens the question -- should the glassfish-jk.properties file then contain everything the workers.properties file contains PLUS the additional attributes such as maxThreads (or just those additional attributes such as MaxThreads, and not worker.list=worker1, worker.worker1.type=ajp13, etc.)?

glassfish-jk.properties is for Connector attributes only so you shouldn't put worker info there.

Also, I previously used the GlassFish web-console (port 4850 for me) to manually adjust the "max thread pool size" for http-thread-pool from 5 to 200 (which didn't improve the thread size warning). Will your recommended command,

I didn't see that you already did this. If you'd done admin console to update then asadmin set isn't necessary.

Amy

asadmin set configs.config.server-config.thread-pools.thread-pool.http-thread-pool.max-thread-pool-size=newvalue'

attempt to do the same thing (assuming I use 200 for "new value")? The max size for admin-thread-pool is 50 and thread-pool-1 is 200, so none of these 3 thread pools should be the issue (that is, unless the thread pool size is supposed to update from default values at a time later than the warning message issues).

Lastly, I'll use the following commands as mentioned below unless you recommend otherwise:

asad min> delete-http-listener jk-connector
asadmin> create-network-listener --protocol http-listener-1 --listenerport 8009 --jkenabled true jk-connector --port 4850
asadmin> set server-config.network-config.network-listeners.network-listener.jk-connector.jk-configuration-file=/home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties --port 4850

Thanks, GKK

----- Original Message -----

amyroh
Offline
Joined: 2004-05-06

On 2/13/12 6:18 PM, modjklist@comcast.net wrote:
> Hi Amy,
>
> Thanks for all the help! The SEVERE errors disappeared by including
> the apache/conf/workers.properties file as you expected (yay!).

Great!
>
> I even eliminated the WARNING for threadpool.max_threads_too_low
> because I had mistakenly increased the Default configuration rather
> than the Server configuration's settings in the web console (after I
> increased the server configuration's settings the warning went away).
>
> Some follow-up questions:
>
> 1. Do my final (and complete) configuration settings below look OK?
>
> asadmin> start-domain --port 4850
>
> asadmin> deploy /home/glassfish/apps/hello.war --port 4850
>
> asadmin> create-network-listener --protocol http-listener-1
> --listenerport 8009 --jkenabled true jk-connector --port 4850
>
> asadmin> set
> server-config.network-config.network-listeners.network-listener.jk-connector.jk-configuration-file=/home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties
> --port 4850
>
> asadmin> create-jvm-options
> -Dcom.sun.enterprise.web.connector.enableJK.propertyFile=/home/glassfish/glassfish3/glassfish/domains/domain1/config/glassfish-jk.properties
> --port 4850
>
> asadmin> restart-domain --port 4850
>
>
> We didn't talk about the 2nd to last line above (e.g.
> create-jvm-options), but it's mentioned in step 7 here:
> http://docs.oracle.com/cd/E18930_01/html/821-2416/gfaad.html

You don't need the create-jvm-option step. The jvm-option was needed
before since http-listener (unlike network-listener) didn't support
jk-configuration-file attribute.

>
> 2. Can you give specific details on how to exactly set maxThreads
> using the admin console? For example, how to navigate to the screen
> where the setting may be input, and which fields to fill out what, etc.?

Go to Configurations ->server-config -> Thread Pools -> http-thread-pool
-> and edit Max Thread Pool Size.

Amy

>
> Thanks so much, -GKK
>