Gnu Queue: Linux Clustering Made Easy

Farm those jobs out with Gnu queue!
Examples and Options

Here are some simple examples:

> queue -i -w -n -- hostname<\n>
> queue -i -r -n -- hostname

For a more sophisticated example, try suspending and resuming it with Control-Z and fg:

> queue -i -w -p -- emacs -nw
If this example works on the localhost, you will want to add additional hosts to the host access control list in share (or --datadir) and start up queued on these.

This line:

> queue -i -w -p -h hostname -- emacs
-nw

will run Emacs on host name. Without the -h argument, it will run the job on the best or least-loaded host in the Access Control List file. There is also a -H hostname option, which causes hostname to be preferred, but the job will run on other hosts if hostname is unavailable.

At this point, you might be wondering what some of the other options for queue do. ./queue --help gives a list of options to Queue. The “--” separates GNU Queue options from the options to be given to the command to be run. -i stands for immediate; it places the job to be run in the “now” batch queue. -w invokes the proxy job system, as opposed to -r, which causes output to be returned to the user via e-mail (traditional batch processing mode). -n turns off virtual terminal support. Most users will probably only use -i -w -p (full virtual terminal support, for interactive jobs like Emacs) and -i w -n (no virtual terminal support, for noninteractive jobs).

More details on the protocol GNU Queue uses for host selection can be found in the on-line manual and the on-line Internet draft protocol at http://www.gnuqueue.org/.

Segregating Jobs Using Spool Directories

You can also create additional queues for use with the -q and -d spooldir options. They might be used to specify different queuing behavior for different classes of jobs. Each spooldir must have a profile associated with it. The profile determines queuing behavior for jobs running in that spooldir. See the on-line manual for more details.

Fine-Tuning Cluster Performance

That's all there is to it! Of course, for GNU Queue to work well there needs to be some sort of file sharing between nodes in the cluster (for example, NFS, the Network File System). If you have the same home directory, regardless of which machine you log into, your system administrator has somehow configured your home directory to be shared across all cluster nodes. You want to make sure that enough of the file system is shared (i.e., is the same) between cluster nodes so that your programs don't get confused when they run. Typically, you'll want system temporary directories (/tmp and /usr/tmp) to be non-shared, but everything else (except maybe the root file system containing kernel images and basic commands) to be shared. Because this configuration is so common to UNIX and Linux clusters, we've assumed here that this is the case, but it isn't necessarily so; so check with your system administrator if you have questions about how files are shared across your network cluster.

Documentation and Mailing Lists

Documentation about GNU Queue is also available off the web site, including an Internet draft on the protocol GNU Queue uses to farm out jobs. While you're there, you'll probably want to sign up for one of the three mailing lists (queue-announce, queue-developers and queue-support) so that you can learn of new features as they're announced and interact with other GNU Queue users. At the time of writing, queue-developers is by far the most active list, with lively discussion of improvements to GNU Queue's many features and suggested ports to new platforms. You can obtain advice for any problems you encounter from the queue-support mailing list.

CVS Repository: Joining the Developer Community

Another SourceForge feature mentioned on the home page is the CVS repository for GNU Queue. Interested readers can obtain the latest prerelease development code, containing the latest features (and bugs) as they are added by developers, by unpacking the GNU Queue distribution and running the command cvs update inside the top-level directory. If you're actively making changes to GNU Queue, you can apply for write access to the CVS directory and instantly publish your changes via the cvs ci command. If you can get other developers interested in your work (via the queue-developers mailing list, of course), you can bounce code changes back and forth amongst yourselves via repeated cycles of cvs, ci and cvs update. All of this assumes you have cvs installed, which is the default with many Linux distributions.

Code isn't the only way interested readers can contribute to GNU Queue. There are many ways to contribute to the GNU Queue effort on SourceForge. With a login on SourceForge, one of the project administrators can give you editor privileges for the documentation tree, moderator privileges in the discussion forums, or administrative privileges in the bug tracking and patch database sections of the site.

______________________

Comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

cluster

abner's picture

me podria ayudar a configurar un cluster en linux, los pasos a seguir

alternative to GNU Queue

Roger's picture

Beware that this is a pre-alpha release. The original GNU Queue code hadn't been supported in some time - the project was restarted last summer with a new re-write which is this current release. I would therefore be leery using this current code for anything more than experimentation, certainly not in a production environment.

An alternative, also free and open source, is Sun's Grid Engine project (http://gridengine.sunsource.net/). It works on Linux, Solaris, Windows, Mac OS X, and probably most versions of Unix. Grid Engine is probably an order of magnitude more complex to configure than GNU Queue but it has many more capabilities. For your home computer network it is undoubtedly overkill but for any other environment it is seriously worth considering.

White Paper
Linux Management with Red Hat Satellite: Measuring Business Impact and ROI

Linux has become a key foundation for supporting today's rapidly growing IT environments. Linux is being used to deploy business applications and databases, trading on its reputation as a low-cost operating environment. For many IT organizations, Linux is a mainstay for deploying Web servers and has evolved from handling basic file, print, and utility workloads to running mission-critical applications and databases, physically, virtually, and in the cloud. As Linux grows in importance in terms of value to the business, managing Linux environments to high standards of service quality — availability, security, and performance — becomes an essential requirement for business success.

Learn More

Sponsored by Red Hat

White Paper
Private PaaS for the Agile Enterprise

If you already use virtualized infrastructure, you are well on your way to leveraging the power of the cloud. Virtualization offers the promise of limitless resources, but how do you manage that scalability when your DevOps team doesn’t scale? In today’s hypercompetitive markets, fast results can make a difference between leading the pack vs. obsolescence. Organizations need more benefits from cloud computing than just raw resources. They need agility, flexibility, convenience, ROI, and control.

Stackato private Platform-as-a-Service technology from ActiveState extends your private cloud infrastructure by creating a private PaaS to provide on-demand availability, flexibility, control, and ultimately, faster time-to-market for your enterprise.

Learn More

Sponsored by ActiveState