Gproc is a new system, written in Go, that combines features of the
LANL version of bproc (http://sourceforge.net/projects/bproc/) and the
xcpu software (xcpu.org). Unlike bproc, gproc requires no kernel
patch. Like both of them, it provides a process startup mechanism for
lightweight cluster nodes which have only a small ramdisk as the root
file system, with no local disks or NFS root at all. Lightweight
cluster nodes can be very easy to manage if configured correctly (see,
e.g., http://portal.acm.org/citation.cfm?id=1132314).
Gproc provides a system for running programs across clusters. A
command and a set of nodes upon which to run it are specified at the
command line; the binary, any required libraries, and any additional
files specified at the command line are packaged up and sent out to
the selected nodes for execution. The libraries need for the binary
are determined by gproc programatically. The outputs are then
forwarded back to the control node. Currently, we do not support stdin
for the tree of processes as bproc did; it's coming but we have not
needed it yet.
The source is available at http://bitbucket.org/rminnich/gproc. We
have updated the code to work with changeset 8101:6aa7ab6b6a9d (a
recent weekly release) of Go; see the INSTALL file for information on
getting it compiled.
The README file should help you get started using gproc, if you have a
cluster or even a set of computers which might pass as a cluster. You
can even test it on just one computer, using the "local" locale, like
so:
% sudo rm -rf /tmp/g && ./gproc_linux_amd64 -locale=local m
master : 2011/04/20 17:21:40 -cmdport=0.0.0.0:39563
# open a new terminal
# look at the port in the "cmdport=" output from the previous command,
use that as our -cmdport argument
# we have to do this because everything is running on one machine,
it's not necessary otherwise
% sudo ./gproc_linux_amd64 -locale=local -cmdport=39563 s
slave : 2011/04/20 17:21:53 -cmdport=0.0.0.0:41412
# open a third terminal
% ./gproc_linux_amd64 e . /bin/date
Wed Apr 20 17:21:59 PDT 2011
As you might have guessed, gproc is a huge security hole, so you
should be careful when running it. If you look... this allows any user
to run any program as root. Useful for a supercomputer, but something
to be wary of on a regular machine.
The authors of gproc are: Ron Minnich, Noah Evans, Jason Dreisbach,
and John Floren. Be gentle, this was our first major Go project!
John Floren
First problem: we don't really support OSX as a slave node -- we have
no OSX clusters. (BTW, this master/slave terminology is from bproc. I
hope it doesn't upset anyone, if it does we can change it). But you
might be able to make it work ...
set -p=false and -localbin=true on all your commands.
Also, note, I said something wrong: it's not that everything runs as
root, it runs as the user who starts the gproc s. Easy to fix, we just
have not had the time.
> Will dig into codes.
Very kind of you! If you want to fork it at bitbucket we will gladly
take pull requests. We also take programming advice :-)
There is a gproc developers list; contact john if you would like to be on it.
Also,please note, some of these design decisions may seem unusual,
just contact us if you're wondering but believe me, there is a reason
for them :-)
ron
Juat a note here, we're not running the ldd program, rather the ldd
is done with bitbucket.org/npe/ldd.
I wonder if we could extend that code to support equivalent functions on OSX?
And, even better, if we could get npe/ldd type capability integrated
into standard go libraries :-)
thanks
ron