[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Sheflug] Clustering



Chris Johnson  wrote:

> Anybody looked into clustering?
> 
> It occurred to me that even when people are doing fairly normal office tasks
> their PCs are under utilised.  I found a knoppix distro called
> ClusterKnoppix that seems to be a project where all PCs on a network work
> cooperatively to acheive a goal of getting things done.


    Clustering is a topic on its own. Over here, we have large sets of
data that need to processed using relatively complex algorithms. This
results in long run times to get the data out of the door (or back
into the program because the speed of light was defined in inches per
lunar month...). In some cases, it is trivial to factor the problem
out into several independent tasks that can each be tackled
individually, and hence, the final answer can be calculated as a sum
of partial answers. An example is Monte Carlo simulations, where you
do a lot of independent trials, and then work out some statistics for
the ensemble. Clearly, if you have 6 identical processing units, you can
(ideally) shave your processing time by 6, as each of these machines
does 1/6 of the problem.

    So far, so good. Easy to understand. However, there are a number
of issues to bear in mind:
(i) If you have loads of data going to and fro the different
processing units (usually on top of an ethernet cable)
(ii) If the problem involves combining loads of intermidiate results
(same as (i), in a way)
(iii) If your problem is easily "parallelizable"
(iv) If you can be bothered to spend time rewriteing the software for
//ization...

    A number of options to achieve parallelization are available for
Linux. Most of them are oriented to the numerical prcoessing world
(hence, linear algebra, Fourier Transforms and things with
French/German/Russian names in them :D).
-Libraries that distribute the load between several nodes, such as MPI
and PVM.
-Process migration tools, such as OpenMosix

    The first lot imply that your software uses the libraries, that
these are installed in the nodes, and they've been around for a long
time. The second approach takes the view that over several nodes, the
load needs to be balanced: if the load on a node is excessive, any
other processes are migrated to some other node. This can be
accomplished by either migrating threads (programming with threads
seems to be harder than finishing the ISS on budget and on time :-/),
or by forking out processes. This is slightly easier to accoplish than
the first option in a lot of scenarios (eg, the monte carlo example
discussed above).

    Of course, all this assumes that you're willing to write your
software, or that someone has taken care of it for you. some programs
(I seem to remember Matlab on Irix, and Mathematica on Linux) are
written with //ism in mind. Others... well, aren't :-)

    The whole point of the preceding paragraphs is that parallel code
is difficul to write, obtain, maintain, and is usually rather
specialist in its nature. On the other hand, most of the tasks people
carry out with computers do not really benefit form the complexities
of parallelization. Some exceptions:
-Audio/Video encoding
-Distributed compilation (as Gentoo does)
-Seti [at] home and other similar toys :-)

> I might be way off here but if I have 10 People using 80% of their PC power
> does that mean I should be able to add another 2 people using older PCs
> running in the cluster and getting about the same performance?

    Not really. See the above.

> suite to process extending the useful life of the older PCs.  As an
> alternative to LTSP it seems to do away with the requirement of the central
> (high spec) LTSP server.  However you lose the central point of admin.
> Would it be possible (in theory) to use a cluster as an LTSP server?

    Well, the idea is that LTSP has low-end servers acting as X
terminals. The applications are launched in the central server (LTS).
The terminals just get data on the network telling them to draw lines
and stuff like that, so the requirements are small. The LTS, on the
other hand, has to deal with a significant amount of load (after all,
you have 32? 64? usess running KDE and OOo and Mozilla and...), so it
needs to be a powerful computer. In this scenario, the idea is to
migrate the tasks that are swamping your LTS to other CPUs, but still
resembling (to the clients) the appearćnce of a single server. 

    The necessary plug here is for Quantian
<http://dirk.eddelbuettel.com/quantian.html>, a version of
ClusterKnoppix with some numerical software prepared for OpenMosix
clustering.

    In your schools context, the benefit of OpenMosix is then to have
several high-end servers that distribute the load from the clients.

    Another interesting application, totally unrelated, and turning
the idea on its head, is to use a powerful workstation to server two
or more users: you get a PS/2 and a USB keyboard, a PS/2 mouse and a
USB mouse, two monitors, two graphic cards. You then get a workstation
with two terminals which users can use independently. You can read
more about it here: <http://bh.udev.org/filez/projects/dual.html>

    I shall be signining copies of my book next week :-)
    Sorry for the long e-mail!
    José


-- 
José L Gómez Dans			PhD student
Tel: +44 114 222 5582			Radar & Communications Group
FAX; +44 870 132 2990			Department of Electronic Engineering
					University of Sheffield UK
___________________________________________________________________

Sheffield Linux User's Group -
http://www.sheflug.co.uk/mailfaq.html

  GNU the choice of a complete generation.