Вы находитесь на странице: 1из 27

Workreport

Clusters with ELX

Daniel Kratschmar
Flughafenstr. 13
76149 Karlsruhe
(0721) 4847824
daniel@level7.de
Matrikelnr: 13261

October 2003 to March 2004


Contents

1 Introduction/Preface 3
1.1 The whole scope . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
1.2 Middleware . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
1.3 Single System Image . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5

2 OpenMosix 6
2.1 A Short Introduction to OpenMosix . . . . . . . . . . . . . . . . . . . . . . . 6
2.2 Installation and Configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
2.3 How to use your Cluster . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
2.4 Additional Software . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
2.4.1 OpenMosix Userland Tools . . . . . . . . . . . . . . . . . . . . . . . . 8
2.4.2 OpenMosixview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
2.4.3 OpenMosixprocs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
2.4.4 OpenMosixcollector . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
2.4.5 OpenMosixanalyzer . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
2.4.6 OpenMosixmigmon . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
2.5 Diskless Nodes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
2.5.1 What is it? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
2.5.2 Plump-OS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
2.5.3 ClusterKnoppix . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
2.5.4 CHAOS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
2.5.5 Dynebolic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11

3 OpenSSI 13
3.1 A Short Introduction to OpenSSI . . . . . . . . . . . . . . . . . . . . . . . . . 13
3.2 Installation and Configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
3.3 Single System Image . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14

4 OpenMosix and OpenSSI compared 15


4.1 OpenMosix vs. OpenSSI . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
4.2 Conclusion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15

A Booting over Network 17


A.1 DHCP server . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
A.2 TFTP server . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18

1
CONTENTS 2

B Kernel 20
B.1 Building a Kernel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20

C RPM 23
C.1 What is RPM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
C.2 A few examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
Chapter 1

Introduction/Preface

It’s an old saying that your lifestyle expands to meet your available income. The same can
be said of computer processing trends: computing problems always seem to meet or exceed
available computing resources. There is always a need for more proccesing power, more
network bandwidth, and more disk space.
This is a circular problem in information processing. As technology advances, we can do
more with our computers, which heightens expectations of what can be done, which in turn
pushes the leading edge of technology to create faster computers to push the leading edge
of what we can do with our computers. This need for speed has prompted the development
of a whole new class of machines: supercomputers.
This kind of computer is used in different manners. They are used by scientiest for
simulations and development of new technologies. Artists use it for generating and rendering
images and even movies. Economiest do their researches and data-mining with the help of
computers. There is almost no part of today’s life that is not influenced by computers.
One of the problems with computer-driven activity is that it requires a lot of computer
horsepower. That usually means a commercial supercomputer. Supercomputers are, by
their very nature, extremely expensiv. After all, they do represent the very leading edge of
technology, and they have traditionally been very costly to develop, maintain and program.
This brings us to an interesting confluence of events that is changing the way people look
at high-performance computing and causing a fundamental shift in the economics of these
powerful pieces of technology.
Back in 1994 a couple of NASA scientists was in need of a supercomputer. The limit
of their budget forced them to find another solution. What they were looking for was a
low-cost, yet efficient system for processing large space-science data sets. So they built out
of a few ordinary computers, connected by a network a quite effective parallel processing
computer. The world’s first cluster, which become legendary by the name ”Beowulf”.
Nowadays clusters have become a fast growing alternative to supercomputers - a lot
of the world’s most powerful computers are cluster systems. With the popularity came
specialization to certain tasks. This report won’t cover the whole scope, we will concentrate
on two Cluster-Middlewares OpenMosix and OpenSSI.

3
CHAPTER 1. INTRODUCTION/PREFACE 4

1.1 The whole scope


If you dig deeper in the subject of clustering you will be able to distinguish five kinds of
clusters. The difference in between them is the task for which they are built.

• High Performance Clusters


This is probabely the type most people will think of, when talking about Clusters. A
Supercomputer in it’s natural way, with - as the name already says - a high perfor-
mance. They are used for calculations, that would need a very long time on a single
computer or even would never finish.
How does this cluster reach it’s performance? The main thought behind High Perfor-
mance Clusters is the Single System Image, which will create the imagination, that
all the computers of the cluster are on big computer. This will enable the cluster to
shift or in the terms of clustering, migrate tasks and processes between it’s computers.
That’s called Load Balancing, as any node with to much load can be freed of a piece
of it’s task and this piece can be handed to another node which isn’t busy at that
moment, the load is balanced.
• Webserving Clusters
Big Homepages are also in need of a certain kind of clusters. The Webserving Cluster
will split it computers in two groups. The first type are the computers that will
interact with the visitor or respectively with their browsers. They’ll accept request
for the homepage and will return the data. In behind they will communicate with
the other kind, the computers that will run the scripts and process the data, which is
requested by the visitors.
• Storage Clusters
Any feature you’ll find at the RAID-technology can be transformed into bigger scale.
Storage Clusters can be used to create really huge harddisks with a incredible fast
response time and the feature of backing up the data in realtime. And they are doing
it the same way as a RAID. The data is splitted into small packages and stored on
different computers to gain speed. By connecting several computers the size of the
harddisk increases. Last but not least it is possible to keep a mirror of any data in
the system, so that in the case of emergency no data will be lost.
• Database Clusters
Database Clusters are a speziallisation of Storage Clusters. They will do all the same
but with an optimization for databases.
• High Availability Clusters
The most sophisticated kind of Clusters are the High Availability or Fail-Safe Clusters.
This represent the computers that need to have an uptime of 24 hours on 7 days the
week. Like Storage Clusters the will keep their data redundant, but further more they
will do the same with anything. In case of any failure the cluster will notice, that
something is wrong and will from now on use another of the redudant resources to go
on providing the service which has failed at that moment.
CHAPTER 1. INTRODUCTION/PREFACE 5

As the heading promises to cover the whole scope there is one more type to mention. By
now all the clusters had one thing in common, their computers are located beside each other
and the accomplish their tasks in realtime. Nevertheless there’s one more type of clusters
which should not be forgotten, as it will gain more importance in future.

• Distributed Clusters
A Distributed Cluster is made out of a server and many clients. The clients will ask
the server to provide some work and will be handed over some packages to process.
Whenever the client has finished it’s task it will contact the server again and submit
the results. The advantage of this kind of clusters is their high scalability and even
more interesting that the computers can be distributed all over the world.
Today Distributed Clusters are used preponderantly by scientiests for their researches
and the clients are private volunteers. In my opinion this scenario will change in
future. Companies will pay for calculating the packages they provide and submitting
the results back to them.

1.2 Middleware
Like any computer needs an Operating System to run, clusters are also in need of some
software to run. This software is called Middleware. A Middleware is very similare to an
Operating System, as it determines how available resources are handled, which process gets
computing time and how the user can influence all these things.

1.3 Single System Image


The most interesting part of any Middleware is how it creates the Single System Image.
But wait what’s this a Single System Image?
To say it in one sentence, it’s ”the illusion, created by software or hardware, that a
collection of computing elements is a single computing resource1 ”.
The thought of the SSI appears in all levels of technology, may it be a clusterwide
filesystem, a process list, that can be seen by every node, devices that can be accessed from
everywhere or any other resource that has become available over the whole cluster.

1 by Gregory Pfister
Chapter 2

OpenMosix

2.1 A Short Introduction to OpenMosix


In the beginnig there was Mosix. Mosix has been an OpenSource Project until the de-
velopers decided to become a commercial software. For this reason and some others one
developer named Moshe Bar split from the development group and startet another Open-
Source Project. This project was based at what was Mosix at that time and it was given
the name OpenMosix [1a]. Development of both projects went on, so that today Mosix and
OpenMosix are two complete different Softwares.
OpenMosix has become a SourceForge-Project and can be reached at www.openmosix.org.
With Moshe Bar as head a big community has grown and the development is heading in
many directions. Beside that you can also find a lot of ”Third Party” Software for Open-
Mosix.

2.2 Installation and Configuration


OpenMosix itself is installed as a patch for the kernel. Patching the kernel is everything else
but fun, so be sure to check out if you can find some precompiled packages for your Linux
Distribution on the OpenMosix Homepage. If your using ELX check out their homepage
for this packages. For all the other users I recommend the OpenMosix-HOWTO [1b] which
also has a section about installation.
For ELX we’ve packed some rpm’s. The installation becomes as easy as falling of a log,
when you use them. The following screenprint shows all that needs to be done.

# rpm -Uvh openmosix-kernel-2.4.20-openmosix3.i386.rpm open


mosix-tools-0.3.4-1.i386.rpm
Preparing... ############################################ [100%]
1:openmosix-tools ############################################ [ 50%]

Edit /etc/openmosix.map if you don’t want to use the autodiscovery daemon.

2:openmosix-kernel ############################################ [100%]

6
CHAPTER 2. OPENMOSIX 7

#
After that you need to create the shared directory, which will be used by openMosix
later on. Therefore you make an entry in your file /etc/fstab
mfs_mnt /mnt/mfs mfs dfsa=1 0 0
ATTENTION: Do not forget to create this directory on you harddisc, otherwise the
kernel won’t boot.
As you can see there will be some tools installed beside the pure openMosix software.
For more detailed information about these tools refer to section 2.4.1, page 8.
Configuration isn’t necessary unless you want to tune your cluster or you’re faced with
serious problems. In this case I recommand the openMosix-HOWTO.
It is already mentioned during the installation, unless you don’t configure anything else,
a autodiscovery daemon will be working. The daemon is called omdiscd (openMosix auto
DISCovery Daemon) and his purpose is to notify all nodes of computers, that join the
cluster. Even more he will distribute the IP-Adress of them, so that every node can keep
it’s liste of nodes up to date.

2.3 How to use your Cluster


Once you rebootet your computer after the installation the cluster will be running. All
you got to do now to benefit from the cluster is to call a programm and enjoy. Of course
you won’t gain any performance during normal work, but as soon as you challange your
computer it will share it’s work with the other computers in the cluster.
Some programs which can be used to challenge the computer - these programs run
smoothly with OpenMosix are:
• Make
• Blender
• PovRay
• BLAST
• Matlab
• FLAC
• John the Ripper
• LAME
• Postfix

2.4 Additional Software


With the installed packages you can run and operate your OpenMosix-Cluster. But some-
times this is not enough.
CHAPTER 2. OPENMOSIX 8

2.4.1 OpenMosix Userland Tools


The openMosix userland tools is a package of software, which is distributed with openMosix.
By the time I write this report attempts are made to take them into the default package for
OpenMosix.

2.4.2 OpenMosixview
Even tough there is a simple, shell based monitor software comeing along with the openMosix
tools, most of the people I’ve seen prefer openMosixview to monitor their cluster.
Monitoring the cluster is highly recommended for people who want to get the best out
of their cluster or for those who are searching for errors or just want to see wether and how
the cluster is working.
Take from the ”proc” filesystem openMosixview will display the current load and CPU-
usage of any active node. Additionally the status of any known node will be shown. This
enables you to use the programm to see wheter all nodes have joined the cluster correctly
or wether there is a problem.

2.4.3 OpenMosixprocs
By the time you use OpenMosix frequently or you want to tweak the system you want
to know what is going on on the cluster. OpenMosixprocs provides you an interface for
watching the running processes and for managing them.

2.4.4 OpenMosixcollector
Another usefull tool when you’re about to optimze the cluster is the openMosixcollector.
This tool is a logfile writer which will generate a logfile about anything you want to know.

2.4.5 OpenMosixanalyzer
As the name already promise is the openMosixanalyzer a programm for analysing your
cluster. Basically it displays the same information as openMosixview does. The important
difference is, that the openMosixanalyzer uses graphics for displaying, so that you have some
kind of realtime history.

2.4.6 OpenMosixmigmon
The most confusing tool of this collection is without doubt the openMosixmigmon. The
tool shows how the processes migrate from or to a specified node of your cluster. This is
done by showing the envolved nodes as circles and the processes as green dots. Whenever a
process migrates the dot will move from one circle to another one and this two points will
be connected by a line. After some time you will have a beautiful, but for the novice very
confusing diagram.
CHAPTER 2. OPENMOSIX 9

2.5 Diskless Nodes


Whenever you have your Cluster running you might want to add more nodes to it. To do so
you need, of course more computers. As life is a cruel thing the most common situation is,
that the computers available are in use by other people, so you can only use them at night
or/and even worse they don’t have OpenMosix installed.
The easiest solution would be in any situation if you were able to add these nodes
temporarily and without having to install any software on these computer. Lucky as you
are, there are several Linux–Distributions around the internet, which where build for exactly
this purpose.

2.5.1 What is it?


Okay, before we have a look at the differences of the distributions, we should have a look
on what the have all in common.
As the name already says the most obvious thing is, that the don’t need a harddisk.
Because the operating needs to be stored somewhere we’re in need of something else to put
it on. Today’s distributions don’t fit any more on a floppy-disk, so the most common storage
will be a CD. But you might think of any other resource you can access at boot-time, like
USB–Devices and Network–drives.
Lets go on and let us see, what is happening, when you switch on your computer, while
having on of these CD’s in your CD–Rom. If you haven’t forgotten to set the BIOS accord-
ingly, the computer while attempt to start from this CD. Depending on the Distribution
you may have several options or there’s only one kernel. However if you lean back and do
nothing the default kernel will be loaded after a short moment. Now you should see lots
of information passing by. When the slideshow is over and the computer has become quite
again you have Linux running on this computer. You might guess it already, the best thing
is, when you boot the computer next time without the CD, you can enjoy your normal
working environement and no change will have been made to it.

2.5.2 Plump-OS
The first distribution you probabely will hear about, when starting with openMosix, is
Plump-OS1 . The only reason for this is, because it is mentioned in the openMosix–HOWTO.
At the boot-screen you have the choice between 10 pre-installed Kernels. By the way
you have the posibility to add your own kernel to this list. Of course this has to be done
before the CD is burnt.
The booting process is done very fast and the CD is ejected as soon as the whole kernel
is loaded into the memory. Plump-OS is a tiny distribution, so don’t be surprised if no
graphical interface is loaded. But the graphical interface won’t be everything you’ll miss.
By typing help at the command–prompt the short list of built-in commands will be shown
to you.
Trying to get the Node in your Cluster you will be faced with several problems:
• First of all you have to configure openMosix to use the autodiscover-daemon, because
there is no way to edit the openmosix.map–file. If you try long enough you might find
1 http://plumpos.sourceforge.net/
CHAPTER 2. OPENMOSIX 10

possibilities to change it tough. But you won’t become luky with it, as the ”filesystem”
of PlumpOS is not capable of making changes to the files.
• The next obstacle you have to get over is the lack of the shortcut Ctrl+C to escape
from running scripts. Did you ever try to test your if it is working without pinging?
And you will only make one attempt to use this command in PlumpOS, because the
only way to stop it is a reboot.
• Finally the autodiscover-daemon of openMosix won’t work with PlumpOS.
I want to finish my review by saying, that I was deeply disappointed by PlumpOS. I
found during several day’s work no way to add the node to the cluster. Once you got
the autodiscover-daemon running and receive requests from the other nodes openMosix re-
fuses to start. The other way round, when you’ve got the feeling, that openMosix is running
all other node will stay in down-status.

2.5.3 ClusterKnoppix
ClusterKnoppix2 comes with much more than you would need to create an additional node.
It is equipped with a graphical interface and lots of programmes.
The most interesting feature of them all is without any doubt the ”Terminalserver”. It
makes a fully equipped Server out of the computer. With just a few clicks you set up a
DHCP–server and with some more it’ll become a server other computer can use for booting
over the network. All these settings can be made even by users with less experience, because
a wizzard is used for the configuration.
The price you have to pay for all this isn’t that high. Decompressed the software would
need more than 2GB. This is an amount most of the workstations don’t offer today. That’s
why you have to keep the CD in the CD-Rom, meening you need for each additional Server
an own CD.
During the boot, which is a little bit to colorful for my opinion, the resolution of the
screen like all of the hardware is recognized automatically. Once you’ve logged in you can
use ClusterKnoppix the way you are used from the ”famouse” distributions like Suse and
RedHat.
Computers that are booted over the network have the same options like the server. Of
course only if the server is configured that way. If the server and the network is powerful
enough you will even merely notice that you only use a client.

2.5.4 CHAOS
The aim of the developpers of CHAOS3 was to create a small and secure distribution. While
keeping the focus on these goals they achieved to create even more than that.
The security playes a big role. IPSec and encrypted data is used for the network connec-
tion. Even more a daemon called certaintyd checkes periodically if the disk-image is altered.
In this case it will cause the system to reboot. By the way intruding into the system isn’t
easy at all, as all packets are filtered and only 80/TCP, 500/UDP and ESP is permitted.
2 http://bofh.be/clusterknoppix/
3 http://itsecurity.mq.edu.au/chaos/
CHAPTER 2. OPENMOSIX 11

Being anoid by the limitations off omdiscd, the developers try to implement a better
daemon. The autodiscover-daemon of CHAOS is called tyd and uses the Terrence and Phillip
principle. This principle is a new invention, so some explanations would be appreciated.
Here’s how the authors use to explain it:

Tyd has two components, Terrence and Phillip. Terrence acts as a client,
interrogating Phillip, the server. On the first node in a cluster, Tyd is executed
without any paramaters, forcing it to run without Terrence; we’ll come back to
Phillip later. On every other node, Tyd is executed with one paramater; an
IP address for another node. Tyd can now tell Terrence where one Phillip is.
Terrence connects to Phillip and, once they have met and exchanged their formal
greeting, Terrence begins to interrogate Phillip.
Terrence is going to be busy for a little while. First, he retrieves the mosix
map from the Phillip he was told about; he updates the local CHAOS node with
this map. Then, he connects to every Phillip in the map (cluster), one by one,
starting with the first (lowest numbered node-id) and moving through to the last.
As he visits each Phillip, Terrence asks him to add the new CHAOS node to his
own map. Phillip does this, and returning the current total number of nodes
to Terrence. If the total number of nodes that a given Phillip knows about, is
more than the total number of nodes Terrence is expecting, then Terrence has
been passed by another Terrence; he aborts his cluster addition interrogation,
and starts again - asking the first node for a new map.
Phillip, relatively speaking, has a much easier job. Once Terrence has been
successful in joining the cluster (map) he goes away, leaving a Phillip in place
on the new CHAOS node. This Phillip is like all or any other; contains a map
of the entire cluster, is ready to serve maps to a passing Terrence, and to add
new Terrences as they occur.

As if the feature-list wasn’t long enough by now CHAOS comes with some more things.
One of the benefits off a small disitribution is the ability to store it completely in the memory,
so that the CD can be removed after booting and it can be used for other nodes. Befor
booting you have the choice between several screen-resolutions and wether you want to use
DHCP, BOOTP or RARP.
All in all this distribution is very good and we wanted to use it for creating large Adhoc-
Clusters, because only one CD is needed for booting all the computers. The only thing
that prevented us from doing so was the network–failures we had every time we started a
computer with CHAOS.

2.5.5 Dynebolic
The makers of dyne:bolic4 claim it to be a free multimedia studio. And that’s exactely
what it is. All the multimedia–software packed on this CD runs under the GNU-License or
something similar. The included software-package is huge, to name only a few programs we
find graphic–editors like Gimp and Blender beside video-programms like FreeJ and audio–
editors like TerminatorX, SoundTracker or Audacity. Pronounced as the main feature of
4 http://www.dynebolic.org/
CHAPTER 2. OPENMOSIX 12

Dynebolic a programm called MuSE is installed, which will you allow to run your own
radio-station over the internet.
For the rest there is nothing special to say about this distribution. The boot–process
will work without problem, beside the recognicion of an old serial mouse we had on one
computer and anothers computers’ tastatur which refused to work. The graphical interface
is well done and provides access to all the programms mentioned above. Again the CD is
filled, so that the CD needs to remain in the CD-Rom and can’t be used for other computers.
All in all I would recommand Dynebolic for people who want to use the software provided
in this distribution. But you never should forget that it’s not possible to write on the
harddisk. That’s why you need at least one ’native’ Linux–computer which you can access
over the network.
Chapter 3

OpenSSI

3.1 A Short Introduction to OpenSSI


The OpenSSI project [2] has set itself the an ambitious aim, it intends to become the
definitive project that unites all the Linux cluster factions.

3.2 Installation and Configuration


The installation of OpenSSI can be divided up into two parts, the installation of the server
and the installation of the clients.
Before we start to have a look on the installation on the server check out, if the following
software is installed on your system, as it is not part of every default distribution:
• nasm
• dhcp
1
• tftp-server
If all this stuff is installed on your server you are ready to install OpenSSI. Download
the latest tar-file from the homepage. Decompress it and run the ./install script. After it
installs your packages, it will ask you a few questions about how you want to configure your
cluster and your server, which will become the first node.
Reboot. You now have a single node cluster.
A new node is added to an OpenSSI cluster using network booting. This lets you avoid
having to install a distribution on more than one node. To network boot a new node, the
network card must have a chipset supported by Etherboot or PXE. If your network card
does not support PXE booting download an appropriate Etherboot image from http://rom-
o-matic.net/5.0.10/
Boot your computer, it should now prompt that it is attempting to boot over network.
After a short delay it should have recognized you DHCP server and got response from the
1 For a short HowTo about the installation of TFTP see page 17.

13
CHAPTER 3. OPENSSI 14

same. After that it will query your TFTP server and request the kernel image, which is
loaded afterwards.
After attempting the first boot with the new node run openssi-config-node on your
server and select ”Add a new node”. After you’ve answered some questions concerning the
configuration select the MAC address of the new node. The programm will list the unknown
MAC addresses of the computers that have recently probed the cluster. That is also the
reason, why you need to boot the new node twice, the first boot will always fail, as the
server doesn’t recognize the MAC and you do not have any possiblity to make him note it
until the computers has probed the cluster.

3.3 Single System Image


The developers of OpenSSI didn’t choose this name by chance. The Single System Image
provided by an OpenSSI-Cluster is highly developed. It provides a better imagination, for
the software, the users and the adminstrator that they are using only one big computer
instead of manny seperate computers joined to the cluster, which they actually are.
To give the child a name, here’s a brief enumeration in which way the Single System
Image is implemented in OpenSSI:
• Single set of User accounts (no NIS)
• Single set of filesystems (no Network mounts)
• Single process list
• Single set of devices
• Single view of networking
• Single install
• Single boot and single copy of kernel
• Single machine management tools
There are plans to spread the Single System Image over even more parts of the computers
world, like a shared swap space. But already today the development has grown so far, that
any program no matter wether it has been concepted for use on a cluster can run on OpenSSI.
Chapter 4

OpenMosix and OpenSSI


compared

4.1 OpenMosix vs. OpenSSI


Comparing OpenMosix and OpenSSI is almost like comparing a Jeep with a Formular 1
machine, each of them is good for the purpose which they are build for. If you like to know
which one is better suited for your personal needs you’ve got to be sure what you want to
do. In this section the advantages of each software will be named, so compare your needs
with these keywords.

Advantages of OpenMosix
• no configuration needed
• does not disturb the normal work
• gives benefit whenever there are free resources

Advantages of OpenSSI
• superior implementation of the Single System Image

• easy administration
• can handle big clusters

4.2 Conclusion
For any private user who posses more than one computer and has connected them to a
network OpenMosix is the right solution. Whenever you need more power, may it be during
the compilation of a new kernel, while encoding ogg-vobis files or anything else, you will
benefit from any free resource on your other machines. On the other hand your work won’t

15
CHAPTER 4. OPENMOSIX AND OPENSSI COMPARED 16

be slowed down by any other user as there will be no resources shared when you need them
locally.
If you want to build bigger cluster, e.g. for a web-server than OpenSSI should be the
software of your choice. It’s easy to add more power to your ”machine” whenever you’re in
need of and what kind of program you ever will run it won’t recongnize that it is run on
more than one computer.
Appendix A

Booting over Network

If you want to boot a computer over network you need a server that provides this service. On
the other hand you are in need of a BIOS and a network card which will allow you to boot
over network. If the computer that is supposed to boot over network isn’t capable of doing so
you can also try to download an image for a bootdisk from http://rom-o-matic.net/5.0.10/
to enable your computer to boot over network.
The booting process should look like this afterwards.
• The client computer is powered on
• The client’s BIOS makes a DHCP request
• The DHCP server answers with the normal informations like IP-address, Netmask,
Gateway, etc. In addition it will pass the information where to find the TFTP server.
• Having recieved the information the client contacts the TFTP server and asks for the
file, which is was told by the DHCP server to ask for. In normal cases this will be the
bootloader file ”pxelinux.0”
• The TFTP server send the file to the client
• The client will execute the file and ask for the configuration file on the TFTP server
and boot with the kernel specified in this file after having recieved this file as well
from the server.
The following instructions1 will tell you how to setup a server with both daemons DHCP
and TFTP running.

A.1 DHCP server


To install the DHCP server download the appropriat source files and compile them. After
that edit or create the file /etc/dhcpd.conf by inserting the following values:
1 taken from http://www.gctglobal.com/Download/PXE Server/pxe server.html

17
APPENDIX A. BOOTING OVER NETWORK 18

allow booting;
allow bootp;
option routers 10.50.0.1;
option subnet-mask 255.255.255.0;
option domain-name "elxlinux.com";
option domain-name-servers 10.50.0.200;
default-lease-time 21600;
max-lease-time 43200;
ddns-update-style ad-hoc;

subnet 10.50.0.0 netmask 255.255.255.0 {


range 10.50.0.1 10.50.1.255;
}
group {
next-server 10.50.0.156; #TFTP Server
#This is the pxe bootloader file
filename "pxelinux.0";
# One host block per client. This network only has one.
host stb1 {
hardware ethernet 00:0D:60:5D:70:A4; #Test client
fixed-address 10.50.0.156;
}
}

After that ensource that the file dhcpd.leases is existent or create it with

# touch /var/state/dhcp/dhcpd.leases

Now you are ready to start the DHCP server by typing

# dhcpd

A.2 TFTP server


I’ve done the installation with tftp-hpa-0.36.tar.gz which is available at :
http://www.kernel.org/pub/software/network/tftp/.
For the kernel I’m using the files that come with the ELX BizDesk 4.0 CD and are stored
in /images/pxeboot.
First you untar it all, configure and install it. After that you can start to customize your
installation.
Create the folder /var/tftpboot and copy the kernel and the root file system into that
folder.
Now you need to ”install” PXELINUX. PXELINUX is a very simple BootLoader. Just
copy the file pxelinux.0 from the SYSLINUX package into the folder /var/tftpboot.
You are almost finished now. Create another folder /var/tftpboot/pxelinux.cfg/ and a
file named ”default” inside. This file represents the default configuration file for PXELINUX.
The content of that file is the following:
APPENDIX A. BOOTING OVER NETWORK 19

# This is the default pxelinux config file.


LABEL linux
KERNEL vmlinuz
APPEND initrd=initrd.img
IPAPPEND 1

Your file structure should look like this now:

/var/tftpboot/
initrd.img
pxelinux.0
vmlinuz
/var/tftpboot/pxelinux.cfg/
default

If it does you can start the server.

# in.tftpd -v -l -s /var/tftpboot/

If probed the server will now answer request from the client and send them the kernel
for booting.
Appendix B

Kernel

The heart of each Linux-Distribution is it’s kernel. Before you compile a kernel you’ve got
to determine what kind of hardware your computer will support later on, how your network
will work and things like this. If anything isn’t supported by your kernel, there will be no
way to make your computer supporting it.

B.1 Building a Kernel


There are several ways you can go in order to build a kernel. For us it is nescessary to
compile it from the sources. So this will be the way explained in the following text. All
the examples will use the version 2.4.22, if you use another version you will therefor need
to replace these numbers by the corresponding ones of you kernel.

Before we start An obvious thing you need to do, before you can start building a kernel
is to download the sourcefiles, unless you have them already stored on your harddisk. This
can be done the easiest way on http://www.kernel.org. If you want to use the kernel we do,
you can download it by typing:

wget http://www.kernel.org/pub/linux/kernel/v2.4/linux-2.4.22.tar.bz2

Please notice, that this package has a size of almost 29MB. So it’s better to ensure
yourself to have a fast enough connection to the internet and enough time.

Unpacking the sources The next step is to uncompress and unpack your source-file.

bunzip2 linux-2.4.22.tar.bz2

tar xvf linux-2.4.22.tar

After that you will have a directory call linux-2.4.22 in your current folder, which holdes
about 14,000 files.

20
APPENDIX B. KERNEL 21

Configuration The Kernel needs really a lot of configurations. It is therefor highly rec-
ommended to use a grapical interface. To do so type:

make menuconfig

If this doesn’t work, good luck. The settings you make during the configuration will
determine, which modules will be compiled afterwards and wether specific hardware or
software will be supported by your system.

Dependency Now that the configuration is ready, you can compile your kernel. You first
need to generate a dependency tree to determine what part of the source code to compile,
based on your configuration. Use the following command:

make dep

Cleaning up To ensure, that your compilation-process will work fine afterwards, it is


recommanded, that you remove any files from a previous compilation from your filesystem.
Use the following command to remove such files:

make clean

Generating the Image We reached again a point where you have more than one possi-
bility to go one. We will build a kernel file now, by using the following command:

make bzImage

Because a lot of things need to be done now don’t be surprised if a lot of output is
generated and it needs time to do so.

Modules The modules specified during the configuration need to be compiled and in-
stalled seperately. Depending on how many of them you selected this will be a quit long
procedure.

make modules

make modules_install

Installing The next step is the installation. The kernel files need to be created and
installed. Use the following command to make your computer doing this for you:

make install
APPENDIX B. KERNEL 22

Boot Loader The last thing you have to do is to configure your Boot Loader accordingly.
I use Lilo as Boot Loader. My configuration file is called /etc/lilo.conf and looks like this
now:

prompt
timeout=50
default=linux
boot=/dev/hda
map=/boot/map
install=/boot/boot.b
message=/boot/message
lba 32

image=/boot/vmlinuz-2.4.20-8elx
label=linux
initrd=/boot/initrd-2.4.20-8elx.img
read-only
append="root=LABEL=/"

image=/boot/vmlinuz-2.4.22
label=newkernel
initrd=/boot/initrd-2.4.22.img
read-only
Appendix C

RPM

C.1 What is RPM


A computer is worthless if there is no software installed on it. Everybody is likely to use
software according to his needs. Sometimes you might want to evaluate programs or to
remove software you’ve installed previously.
For what reason every, you find yourself most of the time installing or removing or
updating the software on your computer. Todays programs are compilicated and might
contain several thousands of files. Because of that you would appreciate it if your computer
would keep a list of all the software, that is installed on your computer and the files that
belonge to each of them.
To enabled your computer to do so you’ll need again some software. One of the programs
that is capable of this is the Package Manager from Red Hat, who is called RPM.
You might guess it already by the name of the software. Every program is handled as
a package of files by RPM. Once you installed a package on your computer, the Package
Manager will keep a reference to all of it’s files in his database. Further more he will pay
attention, wether any of this files is modified or even deleted.
But this are by far not all the features of RPM. Inside a package information about
it’s content is stored. To enumerate only a few things, I want to mention the software’s
name and it’s version, the author and the distributor. The most important thing of all is a
complete list of all the files. Due to this list RPM can be used for automatic installations.
With a single command you’re able to install any software on your computer.

C.2 A few examples


This section should provide you with some practical examples of how to use rpm. Therefor
we’ll have a look on some options of RPM.

Installing packages To install a package you need to call rpm with the -i switch and
determine which package to install. If you’d like to install more than one package at once
just provide several filenames as parameter for the rpm command.

23
APPENDIX C. RPM 24

# rpm -ivh openmosix-kernel-2.4.20-openmosix3.i386.rpm open


mosix-tools-0.3.4-1.i386.rpm
Preparing... ############################################ [100%]
1:openmosix-tools ############################################ [ 50%]

Edit /etc/openmosix.map if you don’t want to use the autodiscovery daemon.

2:openmosix-kernel ############################################ [100%]

The output of the text and the hashes in our example is optional and will only appear
if you use the -v and -h parameter.

Uninstalling packages Uninstalling a package as easy as installing was. Just give the -e
switch to the rpm command and specifiy which packages to uninstall.

# rpm -e openmosix-tools

Getting Information Every package stores some information about the package itself
and it’s author.

# rpm -qi openmosix-tools


Name : openmosix-tools Relocations: (not relocateable)
Version : 0.3.4-1 Vendor: (none)
Release : 1 Build Date: So 30 Nov 2003 23:15:13 CET
Install Date: Mo 10 Nov 2003 12:34:39 CEST Build Host: trane.paruta.net
Group : System Environment/Kernel Source RPM: openmosix-tools-0.3.4-1.i386.rpm
Size : 451538 License: GPL
Signature : (none)
URL : http://openmosix.sourceforge.net/
Summary : The userland tools of the openMosix-system
Description :
openMosix is a Linux kernel extension for single-system image
clustering. This package contains the necessary user-land tools for an
openMosix cluster. It also contains openMosix versions of ps and top
(mps and mtop) that has an additional column which shows on what node
the processes are running.

The file list Very important for maintaining RPM’s database is the file liste which is
provided by each package. Sometimes it is even for the user interesting to know which files
are installed by a certain package. To get the file list of a packages which is not installed
right now you call rpm with the options -qpl.
APPENDIX C. RPM 25

# rpm -qpl openmosix-tools-0.3.4-1.i386.rpm


/bin/cpujob
/bin/fastdecay
/bin/fixvfork.sh
/bin/fixvfork.so
/bin/mosctl
/bin/moslimit
/bin/mosmon
/bin/mosrun

[...]

/usr/share/man/man1/omdiscd.1.gz
/usr/share/man/man1/ompsinfo.1.gz
/usr/share/man/man1/openmosix.1.gz
/usr/share/man/man1/resetgroup.1.gz
/usr/share/man/man1/runhome.1.gz
/usr/share/man/man1/setpe.1.gz
/usr/share/man/man1/showgroup.1.gz
/usr/share/man/man1/slowdecay.1.gz

(The previous output has been truncated.)

Searching for an installed package When searching for a certain package to be installed
you will almost sure be faced with the problem that you need to type in the name of the
package as it is given by the package itself. Normally you don’t know this name or your not
sure how it is written correctly or you make error in typing, as the search is case sensitiv.
At this point you will be very delighted to know a handy trick for searching for packages.
Just let the computer list all of you packages and print out only those who match a search
pattern which is specified by you.

# rpm -qa | grep openmosix


openmosix-tools-0.3.4-1
openmosix-kernel-2.4.20-openmosix3
Bibliography

[1a] openMosix-Homepage, http://openmosix.sourceforge.net/

[1b] openMosix-HOWTO, http://howto.ipng.be/openMosix-HOWTO


[2] OpenSSI-Homepage, http://openssi.org/
[3] Edward C. Bailey, Maximum RPM, Red Hat Software, Inc., 1997
[4a] Introducing the OpenSSI Project, http://www.samag.com/
[4b] The Secrets of openMosix, http://www.samag.com/

26

Вам также может понравиться