You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Wesley Schwengle <we...@is.online.nl> on 2009/02/19 14:37:44 UTC

Cannot find workers

Hello to all,

I have a small issue with Apache (2.2.8) and mod_jk (1.2.27).

I moved some jkmount statements from my mod_jk.conf to the virtualhost section
in Apache and it doesn't work as expected. The full log can be seen here:

http://pb.opperschaap.net/117

The problem is this error:

Could not find worker with name 'w_coinmi' in uri map post processing.

mod_jk.conf:

JkWorkersFile /home/wesleys/etc/workers.properties
JkLogFile /var/log/apache2/mod_jk.log
JkLogLevel debug

workers.properties:

workers.list=w_coinmi, w_testme

##
worker.w_coinmi.port=9009
worker.w_coinmi.host=localhost
worker.w_coinmi.type=ajp13

##
worker.w_testme.port=9010
worker.w_testme.host=localhost
worker.w_testme.type=ajp13

vhost config:
<VirtualHost chanadm-devel>
     ServerName name.example.com
     ServerAlias alias.example.com
     DocumentRoot /home/wesleys
     ServerAdmin toor@example.com
     ErrorLog /var/log/apache2/coinmi_error_log
     CustomLog /var/log/apache2/coinmi_access_log common

     # this used to be in mod_jk.conf
     Alias /coinmi /home/wesleys/tomcat/coinmi/tomcat/coinmi/webapps
     JkMount /coinmi/*  w_coinmi

</VirtualHost>

Does anyone know what I'm doing wrong?

Cheers,
Wesley

PS. I'm subscribed to the list, but haven't received a confirmation, please
reply direct to me (and CC the list for the archives :)).

-- 
Online Broadband BV, http://www.online.nl, http://www.euronet.nl
Wesley Schwengle, System Administrator, IT Operations (Development/Integration)
Muiderstraat 1, PO BOX 10241, 1001 EE Amsterdam, T: +31 20 5355555, F: +31 20 5355749

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Cannot find workers

Posted by André Warnier <aw...@ice-sa.com>.
Wesley Schwengle wrote:
> On 19.02.09 16:36 Christopher Schultz wrote:
> 
>> On 2/19/2009 8:37 AM, Wesley Schwengle wrote:
>>> I moved some jkmount statements from my mod_jk.conf to the virtualhost
>>> section
>>> in Apache and it doesn't work as expected.
>>
>> What does it do, and what did you expect?
> 
> It doesn't work, while the previous setup did work ;)
> 
> What I don't get, and I think it is part of the problem, is the error 
> message in
> the mod_jk.log, Could not find worker with name "some name", while you 
> see it
> being mapped.
> 
>> Where does mod_jk.config get included? If it's in another virtual host,
>> then I don't think it will work. You should ensure that the
>> JkWorkersFile directive is at httpd's top-level.
> 
> No, in the main config of Apache (via 
> /etc/apache2/mods-enabled/mod_jk.(load|conf) - Debian/Ubuntu machine).
> The modules are loaded before the virtual host files are loaded.. So that
> should not be a problem.
> 
> The only thing I moved from mod_jk config to the vhost config is the 
> following:
> 
>  Alias /dir /path/to/webapps
>  JkMount /dir/* w_worker
> 
Don't know if this is your problem, but if you do any JkMount's in the 
main Apache configuration, they are not copied by default to the Vhosts. 
You need to use the JkMountCopy directive.

Note something else :
- with your Alias above, and in the absence of any later filtering, you 
are giving users access to your entire webapp directory via Apache, 
including the WEB-INF directory etc..
- that Alias is not normally necessary, unless you want to serve some 
static content with Apache
- the way the JkMount is written, it is only the files "within" the /dir 
directory that are being re-directed, not a request for "/dir" itself. 
Don't know if it matters, but if you have some index script in there, it 
may.
You may want to add a "JkMount /dir w_worker" otherwise.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Cannot find workers

Posted by János Löbb <ja...@yale.edu>.
On Feb 19, 2009, at 12:09 PM, Wesley Schwengle wrote:

> On 19.02.09 16:36 Christopher Schultz wrote:
>
>> On 2/19/2009 8:37 AM, Wesley Schwengle wrote:
>>> I moved some jkmount statements from my mod_jk.conf to the  
>>> virtualhost
>>> section
>>> in Apache and it doesn't work as expected.
>>
>> What does it do, and what did you expect?
>
> It doesn't work, while the previous setup did work ;)
>
> What I don't get, and I think it is part of the problem, is the  
> error message in
> the mod_jk.log, Could not find worker with name "some name", while  
> you see it
> being mapped.
>
>> Where does mod_jk.config get included? If it's in another virtual  
>> host,
>> then I don't think it will work. You should ensure that the
>> JkWorkersFile directive is at httpd's top-level.
>
> No, in the main config of Apache (via /etc/apache2/mods-enabled/ 
> mod_jk.(load|conf) - Debian/Ubuntu machine).
> The modules are loaded before the virtual host files are loaded.. So  
> that
> should not be a problem.
>
> The only thing I moved from mod_jk config to the vhost config is the  
> following:
>
> Alias /dir /path/to/webapps
> JkMount /dir/* w_worker
>
> Cheers,
> Wesley
>

You might want to set JkLogLevel to debug temporary and see how the  
mapping is done in reality.  Then You will have a fairly good idea  
what can be wrong.

János
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Cannot find workers

Posted by Wesley Schwengle <we...@is.online.nl>.
On 19.02.09 16:36 Christopher Schultz wrote:

> On 2/19/2009 8:37 AM, Wesley Schwengle wrote:
>> I moved some jkmount statements from my mod_jk.conf to the virtualhost
>> section
>> in Apache and it doesn't work as expected.
>
> What does it do, and what did you expect?

It doesn't work, while the previous setup did work ;)

What I don't get, and I think it is part of the problem, is the error message in
the mod_jk.log, Could not find worker with name "some name", while you see it
being mapped.

> Where does mod_jk.config get included? If it's in another virtual host,
> then I don't think it will work. You should ensure that the
> JkWorkersFile directive is at httpd's top-level.

No, in the main config of Apache (via /etc/apache2/mods-enabled/mod_jk.(load|conf) - Debian/Ubuntu machine).
The modules are loaded before the virtual host files are loaded.. So that
should not be a problem.

The only thing I moved from mod_jk config to the vhost config is the following:

  Alias /dir /path/to/webapps
  JkMount /dir/* w_worker

Cheers,
Wesley

-- 
Online Broadband BV, http://www.online.nl, http://www.euronet.nl
Wesley Schwengle, System Administrator, IT Operations (Development/Integration)
Muiderstraat 1, PO BOX 10241, 1001 EE Amsterdam, T: +31 20 5355555, F: +31 20 5355749

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Cannot find workers

Posted by Christopher Schultz <ch...@christopherschultz.net>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Wesley,

On 2/19/2009 8:37 AM, Wesley Schwengle wrote:
> I moved some jkmount statements from my mod_jk.conf to the virtualhost
> section
> in Apache and it doesn't work as expected.

What does it do, and what did you expect?

Where does mod_jk.config get included? If it's in another virtual host,
then I don't think it will work. You should ensure that the
JkWorkersFile directive is at httpd's top-level.

- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkmdfHQACgkQ9CaO5/Lv0PCIxQCgrcMVIcFp7a5gusVPJtVkkofD
D0cAnRMLHF4UtRLY4JQs2Vpo+QikaTBz
=7lqC
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Cannot find workers

Posted by Christopher Schultz <ch...@christopherschultz.net>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Martin,

Wow, that's a confusing workers.properties file. You load-balance one
worker and still use it separately... and then never define the second
of the two load-balances workers? The load-balancer isn't even enabled.

- -chris

On 2/19/2009 9:31 AM, Martin Gainty wrote:
> Goddag Wesley 
> 
> here is my list from %TOMCAT_HOME%/conf/workers.properties
> 
> # Add 'inprocess' if you want JNI connector 
> worker.list=ajp12, ajp13
> 
> #------ DEFAULT ajp13 WORKER DEFINITION ------------------------------
> #---------------------------------------------------------------------
> 
> # Defining a worker named ajp13 and of type ajp13
> # Note that the name and the type do not have to match.
> #
> worker.ajp13.port=8009
> worker.ajp13.host=localhost
> worker.ajp13.type=ajp13
> #  ----> Low lbfactor means less work done by the worker.
> worker.ajp13.lbfactor=1
> 
> # The loadbalancer (type lb) workers perform wighted round-robin
> # load balancing with sticky sessions.
> # Note:
> #  ----> If a worker dies, the load balancer will check its state
> #        once in a while. Until then all work is redirected to peer
> #        workers.
> worker.loadbalancer.type=lb
> worker.loadbalancer.balanced_workers=ajp12, ajp13
> 
> Bedankt,
> Martin 
> ______________________________________________ 
> Disclaimer and confidentiality note 
> Everything in this e-mail and any attachments relates to the official business of Sender. This transmission is of a confidential nature and Sender does not endorse distribution to any party other than intended recipient. Sender does not necessarily endorse content contained within this transmission. 
> 
> 
> 
> 
>> Date: Thu, 19 Feb 2009 14:37:44 +0100
>> From: wesley.schwengle@is.online.nl
>> To: users@tomcat.apache.org
>> Subject: Cannot find workers
>>
>>
>> Hello to all,
>>
>> I have a small issue with Apache (2.2.8) and mod_jk (1.2.27).
>>
>> I moved some jkmount statements from my mod_jk.conf to the virtualhost section
>> in Apache and it doesn't work as expected. The full log can be seen here:
>>
>> http://pb.opperschaap.net/117
>>
>> The problem is this error:
>>
>> Could not find worker with name 'w_coinmi' in uri map post processing.
>>
>> mod_jk.conf:
>>
>> JkWorkersFile /home/wesleys/etc/workers.properties
>> JkLogFile /var/log/apache2/mod_jk.log
>> JkLogLevel debug
>>
>> workers.properties:
>>
>> workers.list=w_coinmi, w_testme
>>
>> ##
>> worker.w_coinmi.port=9009
>> worker.w_coinmi.host=localhost
>> worker.w_coinmi.type=ajp13
>>
>> ##
>> worker.w_testme.port=9010
>> worker.w_testme.host=localhost
>> worker.w_testme.type=ajp13
>>
>> vhost config:
>> <VirtualHost chanadm-devel>
>>      ServerName name.example.com
>>      ServerAlias alias.example.com
>>      DocumentRoot /home/wesleys
>>      ServerAdmin toor@example.com
>>      ErrorLog /var/log/apache2/coinmi_error_log
>>      CustomLog /var/log/apache2/coinmi_access_log common
>>
>>      # this used to be in mod_jk.conf
>>      Alias /coinmi /home/wesleys/tomcat/coinmi/tomcat/coinmi/webapps
>>      JkMount /coinmi/*  w_coinmi
>>
>> </VirtualHost>
>>
>> Does anyone know what I'm doing wrong?
>>
>> Cheers,
>> Wesley
>>
>> PS. I'm subscribed to the list, but haven't received a confirmation, please
>> reply direct to me (and CC the list for the archives :)).
>>
>> -- 
>> Online Broadband BV, http://www.online.nl, http://www.euronet.nl
>> Wesley Schwengle, System Administrator, IT Operations (Development/Integration)
>> Muiderstraat 1, PO BOX 10241, 1001 EE Amsterdam, T: +31 20 5355555, F: +31 20 5355749
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>> For additional commands, e-mail: users-help@tomcat.apache.org
>>
> 
> _________________________________________________________________
> Want to do more with Windows Live? Learn “10 hidden secrets” from Jamie.
> http://windowslive.com/connect/post/jamiethomson.spaces.live.com-Blog-cns!550F681DAD532637!5295.entry?ocid=TXT_TAGLM_WL_domore_092008
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkmde3UACgkQ9CaO5/Lv0PBQwwCeOTfGImjcN8nretzK7bc3YCDa
yLwAnRWeNBFOOGBnX0aGpJ0R4DtXM4Dp
=ik8y
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


RE: Cannot find workers

Posted by Martin Gainty <mg...@hotmail.com>.
Goddag Wesley 

here is my list from %TOMCAT_HOME%/conf/workers.properties

# Add 'inprocess' if you want JNI connector 
worker.list=ajp12, ajp13

#------ DEFAULT ajp13 WORKER DEFINITION ------------------------------
#---------------------------------------------------------------------

# Defining a worker named ajp13 and of type ajp13
# Note that the name and the type do not have to match.
#
worker.ajp13.port=8009
worker.ajp13.host=localhost
worker.ajp13.type=ajp13
#  ----> Low lbfactor means less work done by the worker.
worker.ajp13.lbfactor=1

# The loadbalancer (type lb) workers perform wighted round-robin
# load balancing with sticky sessions.
# Note:
#  ----> If a worker dies, the load balancer will check its state
#        once in a while. Until then all work is redirected to peer
#        workers.
worker.loadbalancer.type=lb
worker.loadbalancer.balanced_workers=ajp12, ajp13

Bedankt,
Martin 
______________________________________________ 
Disclaimer and confidentiality note 
Everything in this e-mail and any attachments relates to the official business of Sender. This transmission is of a confidential nature and Sender does not endorse distribution to any party other than intended recipient. Sender does not necessarily endorse content contained within this transmission. 




> Date: Thu, 19 Feb 2009 14:37:44 +0100
> From: wesley.schwengle@is.online.nl
> To: users@tomcat.apache.org
> Subject: Cannot find workers
> 
> 
> Hello to all,
> 
> I have a small issue with Apache (2.2.8) and mod_jk (1.2.27).
> 
> I moved some jkmount statements from my mod_jk.conf to the virtualhost section
> in Apache and it doesn't work as expected. The full log can be seen here:
> 
> http://pb.opperschaap.net/117
> 
> The problem is this error:
> 
> Could not find worker with name 'w_coinmi' in uri map post processing.
> 
> mod_jk.conf:
> 
> JkWorkersFile /home/wesleys/etc/workers.properties
> JkLogFile /var/log/apache2/mod_jk.log
> JkLogLevel debug
> 
> workers.properties:
> 
> workers.list=w_coinmi, w_testme
> 
> ##
> worker.w_coinmi.port=9009
> worker.w_coinmi.host=localhost
> worker.w_coinmi.type=ajp13
> 
> ##
> worker.w_testme.port=9010
> worker.w_testme.host=localhost
> worker.w_testme.type=ajp13
> 
> vhost config:
> <VirtualHost chanadm-devel>
>      ServerName name.example.com
>      ServerAlias alias.example.com
>      DocumentRoot /home/wesleys
>      ServerAdmin toor@example.com
>      ErrorLog /var/log/apache2/coinmi_error_log
>      CustomLog /var/log/apache2/coinmi_access_log common
> 
>      # this used to be in mod_jk.conf
>      Alias /coinmi /home/wesleys/tomcat/coinmi/tomcat/coinmi/webapps
>      JkMount /coinmi/*  w_coinmi
> 
> </VirtualHost>
> 
> Does anyone know what I'm doing wrong?
> 
> Cheers,
> Wesley
> 
> PS. I'm subscribed to the list, but haven't received a confirmation, please
> reply direct to me (and CC the list for the archives :)).
> 
> -- 
> Online Broadband BV, http://www.online.nl, http://www.euronet.nl
> Wesley Schwengle, System Administrator, IT Operations (Development/Integration)
> Muiderstraat 1, PO BOX 10241, 1001 EE Amsterdam, T: +31 20 5355555, F: +31 20 5355749
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
> 

_________________________________________________________________
Want to do more with Windows Live? Learn “10 hidden secrets” from Jamie.
http://windowslive.com/connect/post/jamiethomson.spaces.live.com-Blog-cns!550F681DAD532637!5295.entry?ocid=TXT_TAGLM_WL_domore_092008

Re: Cannot find workers

Posted by Wesley Schwengle <we...@is.online.nl>.
On 20.02.09 14:25 Christopher Schultz wrote:

>> The only thing I moved from mod_jk config to the vhost config is the following:
> "
> Obviously, something else changed, too.

Yes, I've made some changes in a script and guess the change was buggy ;)

I found out when wanted to post both old and new situation, then I saw the
difference... Corrected it, and works fine. Perhaps this could be posted in a
FAQ or something.

Q: Cannot find workers
A: Check your worker.list directive in your mod_jk.conf file.

And you already proposed it:

"Another layer of validation might be to issue a warning that no
worker.list was found."

Would have helped finding the issue earlier.

Cheers,
Wesley

-- 
Online Broadband BV, http://www.online.nl, http://www.euronet.nl
Wesley Schwengle, System Administrator, IT Operations (Development/Integration)
Muiderstraat 1, PO BOX 10241, 1001 EE Amsterdam, T: +31 20 5355555, F: +31 20 5355749

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Cannot find workers

Posted by Christopher Schultz <ch...@christopherschultz.net>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Wesley,

On 2/19/2009 5:49 PM, Wesley Schwengle wrote:
> On 19.02.09 14:37 Wesley Schwengle wrote:
> 
>> Could not find worker with name 'w_coinmi' in uri map post processing.
>>
>> workers.list=w_coinmi, w_testme
> 
> The correct syntax is worker.list. The error is gone.. *bangs head
> against a wall*

Heh. Famous last words:

"
> The only thing I moved from mod_jk config to the vhost config is the following:
"

Obviously, something else changed, too.

- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkmer1MACgkQ9CaO5/Lv0PCpvgCgjcSL4CHz1u6T4EVhD4j1X3Ec
oacAn2YlAsqh2Sw9aKYVm5MgncQ7OtYq
=nuPB
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Cannot find workers

Posted by Christopher Schultz <ch...@christopherschultz.net>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Rainer,

On 2/20/2009 3:58 AM, Rainer Jung wrote:
> Once you manage to start a property with "worker.", there's a validation
> tough. In your case this safety net wasn't enough :(

Another layer of validation might be to issue a warning that no
worker.list was found.

- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkmer40ACgkQ9CaO5/Lv0PC+RACfSi/xfCgTuVSgSBZqZdixgSvH
6MUAoKNIQh3HxWmkkbFi0ZdVO0vR2xaZ
=2Lgs
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Cannot find workers

Posted by Rainer Jung <ra...@kippdata.de>.
On 19.02.2009 23:49, Wesley Schwengle wrote:
> On 19.02.09 14:37 Wesley Schwengle wrote:
>
>> Could not find worker with name 'w_coinmi' in uri map post processing.
>>
>> workers.list=w_coinmi, w_testme
>
> The correct syntax is worker.list. The error is gone.. *bangs head
> against a wall*

Yeah, since the property file is extensible with arbitrary lines of the 
form x=y to define a variable x you can then reference in other lines of 
the file, there is unfortunatelya no strict validation, whether all 
lines use known properties.

Once you manage to start a property with "worker.", there's a validation 
tough. In your case this safety net wasn't enough :(

Regards,

Rainer

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Cannot find workers

Posted by Wesley Schwengle <we...@is.online.nl>.
On 19.02.09 14:37 Wesley Schwengle wrote:

> Could not find worker with name 'w_coinmi' in uri map post processing.
>
> workers.list=w_coinmi, w_testme

The correct syntax is worker.list. The error is gone.. 
*bangs head against a wall*

Cheers,
Wesley

-- 
Online Broadband BV, http://www.online.nl, http://www.euronet.nl
Wesley Schwengle, System Administrator, IT Operations (Development/Integration)
Muiderstraat 1, PO BOX 10241, 1001 EE Amsterdam, T: +31 20 5355555, F: +31 20 5355749

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org