Re: Piranha

Sébastien Bonnet <[email protected]>
Newsgroups gmane.linux.redhat.piranha
Message-ID <[email protected]>
> Hi Mustapha,

> We would like to change the wlc scheduling algorithm to take
> into account, CPU loads, memory usages, and network load of the
> real servers.

OK.

> The approach is to periodically cheek these parameters, and
> update the weight assigned to each real server, according to a
> given function.

So, your problem/question is not about a scheduler but more likely about
the monitoring tools. LVS by itself does *never* change RS weights. It
*can* be the monitoring tools' job.

> A first such approach has been made by Jeremy Kerr, that take
> into account CPU loads, in LVS.

Yes, I know. What I've understood from what he said is that is
developping a framework that will help anybody easily plug his own
program do monitor as wanted.

> Yes,  I have to include monitoring tools in the Piranha software.
> This is why I am looking to the source files in order to have a
> global comprehensive view of the software.

OK, now it sounds clear :)

> So, could you please be more accurate ?. In particular, about the
> relation between the different components of the software.

OK, I'll give it a try. When pulse is started, it tries and sees if
another pulse is running on the other box. If not, it then starts lvs,
which then starts one nanny for each RS.

By the same time, lvs adds all active virtual servers (not RS) to IPVS.

Nanny polls a real server and add it to (remove it from) IPVS, and
regularly adjusts its weight based on CPU load.

This is where you should hack (see getRemoteLoad in nanny.c). Usually,
the load command is uptime, rup or ruptime, but you can specify whatever
you want as long as the output is similar to what uptime provides.

The function takes the load as : load average.*:.*(\d\.)+[, ] (if you
are fluent with regular expressions)

If your remoteload "pluggin" does not produce this, you'll have to
chance the way getRemoteLoad looks for the load.

If you're willing to code that, I'd propose you use regular expression
patterns along the remoteload command, which would greatly improve the
ability to use almost any load reporting program.

Good luck :)

-- 
Sébastien Bonnet
  Centre de contacts - Experian France
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.