You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by h iroshan <ir...@gmail.com> on 2009/06/16 20:43:47 UTC

mod_proxy_balancer dynamic change properties

Hi All,

I want to know whether the mod_proxy_balancer can dynamically change there
propertis during the run time. For ex- can we change lbfactor's values for
workers periodically according to there work load.

If it is ok, is it possible to do that by updating theworkers  lbfactor
values in the scoreboard.
Please help me.

Regards
Iroshan
4th year under graduate in computer science
University Of Colombo
Sri Lanka

Re: mod_proxy_balancer dynamic change properties

Posted by h iroshan <ir...@gmail.com>.
Hi jean-frederic clere,

Thanks lot, Is there any technical documentation for these modules,Such as
mod_cluster,mod_proxy_balaner.

Regards,
Iroshan

Re: mod_proxy_balancer dynamic change properties

Posted by jean-frederic clere <jf...@gmail.com>.
h iroshan wrote:
> Hi Rüdiger,
> 
> thanks lot ,
> 
> I  already followed the source code of the mod_cluster. Its uses another 
> shared memory implementation called slotmem rather than using scoreboard.

A slotmem code is already in httpd-trunk.

> Are you sure is it possible to change this scorebord lbfactor property 
> dynamically and it will affect the request distribution according to 
> that dynamically updated lbfactor value.

Please read the code, try the stuff and have fun.

Cheers

Jean-Frederic

Re: mod_proxy_balancer dynamic change properties

Posted by Kevac Marko <ma...@kevac.org>.
On Wed, Jun 17, 2009 at 12:39 PM, h iroshan<ir...@gmail.com> wrote:
> Hi kevac Marko,
>
> Thank you very much .I just want to do the same thing  here. My workers are
> Tomcat and I am going to change lbfactor  according to there Memory
> usage.Can we use normal socket connection to retrieve information from the
> workers or is there any simple way to communicate with worker node?.

If you are using Java stuff, than you should look at mod_cluster.

We read load information from shared memory. Load information is
written there via separate program.

-- 
Marko Kevac

Re: mod_proxy_balancer dynamic change properties

Posted by h iroshan <ir...@gmail.com>.
Hi kevac Marko,

Thank you very much .I just want to do the same thing  here. My workers are
Tomcat and I am going to change lbfactor  according to there Memory
usage.Can we use normal socket connection to retrieve information from the
workers or is there any simple way to communicate with worker node?.

Currently I am doing ,when the balancer init the workers ,I initialise
another thread with socket server wich is listining  for the Worker node.
Worker node also have Socket client it send there Memeory usage to  the
Server Side. But I know thuis is not the way to do that.

I want to do this in a satnderd way please help me..

Thank you,

Regards
Iroshan
4th year under graduate in computer science
University Of Colombo
Sri Lanka

Re: mod_proxy_balancer dynamic change properties

Posted by Kevac Marko <ma...@kevac.org>.
Yes, you can do that. We wrote module that changes loadfactor in
accordance to machine load.

On Wed, Jun 17, 2009 at 12:12 AM, h iroshan<ir...@gmail.com> wrote:
> Hi Rüdiger,
>
> thanks lot ,
>
> I  already followed the source code of the mod_cluster. Its uses another
> shared memory implementation called slotmem rather than using scorebord.
> Are you sure is it possible to change this scorebord lbfactor property
> dynamically and it will affect the request distribution according to that
> dynamically updated lbfactor value.Please help me.
>
>
> Regards
> Iroshan
> 4th year under graduate in computer science
> University Of Colombo
> Sri Lanka
>



-- 
Marko Kevac

Re: mod_proxy_balancer dynamic change properties

Posted by h iroshan <ir...@gmail.com>.
 Hi Rüdiger,

thanks lot ,

I  already followed the source code of the mod_cluster. Its uses another
shared memory implementation called slotmem rather than using scorebord.
Are you sure is it possible to change this scorebord lbfactor property
dynamically and it will affect the request distribution according to that
dynamically updated lbfactor value.Please help me.


Regards
Iroshan
4th year under graduate in computer science
University Of Colombo
Sri Lanka

Re: mod_proxy_balancer dynamic change properties

Posted by Ruediger Pluem <rp...@apache.org>.

On 06/16/2009 09:20 PM, h iroshan wrote:
> Hi Rüdiger and all,
> 
> Actually I want to know  ,can't we done it by changing the source code of
> mode proxy balancer.Because properties of the mod_proxy_balancer gets from
> the config. After first time set values for the scoreboard properties by
> config file , mod_proxy_balancer uses this scoreboard lbfactor value.
> lbfactor value never updated again and again
> 
> So is it possible to update scoreboard lbfactor by source code periodically
> in order to provide  dyanamic load balancing mechanism to this module.

Yes it can be changed dynamically. Please see the implementation of the balancer-manager
handler. I guess another good source for you could be

http://jfclere.blogspot.com/

which talks about mod_cluster (actutally Jean-Frederic is the author of mod_cluster).

Regards

Rüdiger



Re: mod_proxy_balancer dynamic change properties

Posted by h iroshan <ir...@gmail.com>.
Hi Rüdiger and all,

Actually I want to know  ,can't we done it by changing the source code of
mode proxy balancer.Because properties of the mod_proxy_balancer gets from
the config. After first time set values for the scoreboard properties by
config file , mod_proxy_balancer uses this scoreboard lbfactor value.
lbfactor value never updated again and again

So is it possible to update scoreboard lbfactor by source code periodically
in order to provide  dyanamic load balancing mechanism to this module.

please help me

Regards,
Iroshan
4th year under graduate in computer science
University Of Colombo
Sri Lanka

Re: mod_proxy_balancer dynamic change properties

Posted by Ruediger Pluem <rp...@apache.org>.

On 06/16/2009 08:43 PM, h iroshan wrote:
> Hi All,
> 
> I want to know whether the mod_proxy_balancer can dynamically change there
> propertis during the run time. For ex- can we change lbfactor's values for
> workers periodically according to there work load.
> 
> If it is ok, is it possible to do that by updating theworkers  lbfactor
> values in the scoreboard.
> Please help me.

Maybe the below is what you are looking for:

http://httpd.apache.org/docs/2.2/en/mod/mod_proxy_balancer.html#enable

Regards

Rüdiger