oneSIS HOWTO: The simplest setup:
Since one of the major functions of oneSIS is to configure differences
between nodes, the easiest possible setup is when every node is the same.
The only thing we'll have oneSIS do here is configure a
class of nodes
and tell a few directories to live in /ram, the oneSIS RAM disk.
Even when every machine has the same role, it is still good to define the role
(class) of every machine.
For this exercise, we'll just define a single class.
Assume the nodes are named 'node1' through 'node128'. Lets
set up a compute class using one of the
and assign all nodes to it:
One class of diskless nodes
Example 1: Regular expression class definition
NODECLASS_REGEXP node\d+ compute
This directive says that any node matching the regular expression
'node\d+' is a compute node. This regular expression
(regexp) implicity includes the ^ and $ anchors
(ie: /^node\d+$/), so the entire hostname must match. For instance,
a node with the hostname 'node12b' does not match the regexp above, so
it would not be considered a compute node. Look
here for more information on
defining node classes.
If you are running any daemons or applications that need to have
some writable space in the root filesystem, you might still need to add those
to the configuration. For instance, it is necessary in several distributions
to have the ability to write to /var/run and /var/lock/subsys
at boot time. We'll make these directories writable by simply directing them
to live in the RAM disk with some LINKDIR directives. We'll make
/var/log and /tmp writable in the same way.
We'll impose an upper bound on how big our RAM disk can grow though, so it
doesn't get out of control and eat all the memory.
With system logs going to a remote log server, a
RAMSIZE of 10MB is more than enough space.
Example 2: Creating more writeable directories
This will allocate up to 10 megabytes of space on each node for
directories such as /tmp to use. Now, since we have added new
LINK* directives to the configuration, don't forget to run
mk-sysimage on the image.
# mk-sysimage /var/lib/oneSIS/image
oneSIS: Creating LINKDIR: /var/lib/oneSIS/image/var/run
oneSIS: Creating LINKDIR: /var/lib/oneSIS/image/var/lock/subsys
oneSIS: Creating LINKDIR: /var/lib/oneSIS/image/var/log
oneSIS: Creating LINKDIR: /var/lib/oneSIS/image/tmp
Now, since we only have one type of node (ie: a bunch of compute nodes),
thats all that needs to be done! oneSIS isn't needed to configure any
differences between nodes, because there aren't any.
All nodes will come up NFSroot and run any start scripts and daemons that
are configured in the image. You could now boot as many nodes
as you want into this image. All changes to the image are global to all
nodes, and all the nodes will behave in exactly the same way.
Continue on with 'a typical setup for a cluster
image' to learn how to set up multiple classes
of nodes with different behaviors.