XSAN File System

The XSAN filesystem is Apples version of a file system that can be used in a SAN environment. It is apparently based off ADIC StorNext product before. While the idea of a SAN filesystem is typically used in an enterprise environment for storage consolidation, the fact that one has a single storage back end that is accessible in the same way from any node make the same idea good for clusters. However, there are many ways that this can be achieved. Sometimes, via NFS, SAN or Parallel File systems.

XSan Filesystem – The original document form TWiki

Performance Tuning on SNFS

There is quite a fair bit of information in the StorNext file system tuning guide which can be useful. It is attached below for reference.

SNFS Tuning Guide

Ganglia

Taken from http://ganglia.sourceforge.net/.

“Ganglia is a scalable distributed monitoring system for high-performance computing systems such as clusters and Grids. It is based on a hierarchical design targeted at federations of clusters. It leverages widely used technologies such as XML for data representation, XDR for compact, portable data transport, and RRDtool for data storage and visualization. It uses carefully engineered data structures and algorithms to achieve very low per-node overheads and high concurrency. The implementation is robust, has been ported to an extensive set of operating systems and processor architectures, and is currently in use on thousands of clusters around the world. It has been used to link clusters across university campuses and around the world and can scale to handle clusters with 2000 nodes.”

Tools required to build Ganglia

The main tools that are required is as follows:-

  • freetype2
  • libart-2.0
  • libpng
  • rrdtool
  • ganglia

For web based monitoring, PHP is required.

Building Ganglia on OSX

Here is my build configuration for the various tools stated above. I have previously faced difficulty bulding some of these tools in the past using older versions and on thePowerPC? platform. However, when i tried again recently, things seems to be able to build without much problems. The versions and configuration options that i used is as follows:-

  • freetype2 (2.3.4)
    • ./configure –prefix=/usr/local
  • libart-2.0 (2.3.17)
    • ./configure –prefix=/usr/local
  • libpng (1.2.16)
    • ./configure –prefix=/usr/local
  • rrdtool (1.2.19)
    • export LDFLAGS=”-L/usr/local/lib”
    • export CPPFLAGS=”-I/usr/local/include/freetype2 -I/usr/local/include/libart-2.0″
    • ./configure –prefix=/usr/local –disable-ruby –disable-perl –disable-python –disable-tcl
  • ganglia (3.0.4)
    • ./configure –prefix=/usr/local –with-gmetad

Note that the accompanying configuration file for gmond can be obtained by running the following:-

gmond -t > gmond.conf

A default gmetad.conf file is found within the gmetad directory in the ganglia source.

On boot starting on OSX

Here are the example files for launchd starting of Ganglia.

Ganglia launchd startup files

Showing the number of SGE jobs on Ganglia

It is useful to try to push information to be charted into Ganglia so that you can have one simple interface to look at all the various information related to your cluster. Here is a simple script that allows one to be able to see the number of SGE jobs that are in the queue and the number of SGE jobs that are running.

Save the below as a script file and add it into your CRON job to get these information into Ganglia. Simple

#!/bin/sh

GMETRIC="/usr/bin/gmetric"
source /etc/bashrc

# Might have to change path to reflect your SGE install.. 
QSTAT=`qstat | grep -v "$(qstat | head -n2)" | wc -l`
$GMETRIC --name SGEJOBS --type uint16 --units jobs --value $QSTAT

QSTAT=`qstat | grep -v "$(qstat | head -n2)" | grep @ | wc -l`
$GMETRIC --name SGEJOBS_RUNNING --type uint16 --units jobs --value $QSTAT

Setting up DNS on Mac OSX Server

Setting up the DNS service on Mac OSX is really simple. In short, it is using the Server Admin tool and clicking on the DNS selection. A summary of the steos required is as follows.

  1. Login to the system with the admin username and password
  2. Select the “Serveradmin” application in your “Applications” folder.
  3. Make sure that you have your server marked and available in the left plane. If not, select “Add Server” and include the relevant parameters
  4. Select the “DNS” entry and select “Settings” somewhere near the bottom
  5. Create a new zone and enter the following
    • zone name : The domain name you wish the DNS to be a part of
    • Server name : DNS hostname
    • Server IP : Local IP address of the DNS machine
  6. Select “Machines” and add the machine IP addresses and names into the table provided.
    • NOTE: if you have a large number of machines that you need to input into the DNS tables, there is a small “file” icon on the bottom right which you can drag and place in your desktop. This will be a plist file which you can then open by using “Texedit”.
    • Once you have “exported” the .plist file, you can edit the file by hand or via a script such that you can enter many compute nodes at a time. Doing so will be faster for a large cluster of nodes.
    • You can re-import this by dragging the plist file back into the DNS settings window
    • NOTE2: if you want to do a zone transfer or zone forwarding, you need to add entries into the “Secondary Zone” for the queries to be forwarded.
  7. Start the DNS service by selecting start on the top bar
  8. Start the terminal application and ensure that your network interface is activated and up. (use ifconfig or something)
  9. Use “host” or “nslookup” to check for both forward and reverse name resolutions

One thing to note.. unlike linux where you can set up DNS without having a network connection, in MAC, you seem to actually NEED to have a wire connected, so that the interface is brought up, BEFORE you can test the DNS. So ensure that you actually have a physical ethernet connection before you test the DNS.