Read Me

## Grid Engine cluster configuration

Grid Engine root directory (`$SGE_ROOT`) | ${cfg.sge.root}
Cell name (`$SGE_CELL`) | ${cfg.cell.name}
Cluster name (`$SGE_CLUSTER_NAME`) | ${cfg.sge.cluster.name}
qmaster port (`$SGE_QMASTER_PORT`) | ${cfg.sge.qmaster.port}
execd port (`$SGE_EXECD_PORT`) | ${cfg.sge.execd.port}
Group id range | ${cfg.gid.range}
qmaster spool directory | ${cfg.qmaster.spool.dir}
Global execd spool directory | ${cfg.execd.spool.dir}
Spooling method | ${cfg.spooling.method}
Spooling directory | ${cfg.db.spooling.dir}
JMX port | ${cfg.sge.jmx.port}
JVM library path | ${cfg.sge.jvm.lib.path}
JMX SSL server keystore path | ${cfg.sge.jmx.ssl.keystore}
Administrator mail | ${cfg.admin.mail}

| Succeded | Failed
Qmaster host | ${add.qmaster.host} | ${add.qmaster.host.failed}
Execution host(s) | ${cfg.exec.host.list} | ${add.exec.host.list.failed}
Shadow host(s) | ${cfg.shadow.host} | ${add.shadow.host.failed}
Berkeley db host | ${cfg.db.spooling.server} | ${add.db.spooling.server.failed}
Admin host(s) | ${cfg.admin.host.list} | ${add.admin.host.list.failed}
Submit host(s) | ${cfg.submit.host.list} | ${add.submit.host.list.failed}

## Getting started with Grid Engine

### Setting the environment

- if you are a csh/tcsh user:
  `source ${cfg.sge.root}/${cfg.cell.name}/common/settings.csh`
- if you are a sh/bash/ksh user:
  `. ${cfg.sge.root}/${cfg.cell.name}/common/settings.sh`
- This will set or expand the following environment variables:
  - `$SGE_ROOT` (always necessary)
  - `$SGE_CELL` (if you are using a cell other than `default`)
  - `$SGE_CLUSTER_NAME` (always necessary)
  - `$SGE_QMASTER_PORT` (if you haven't added the service `sge_qmaster`)
  - `$SGE_EXECD_PORT` (if you haven't added the service `sge_execd`)
  - `$PATH/$path` (to find the Grid Engine binaries)
  - `$MANPATH` (to access the manual pages)

### Submitting your first Grid Engine job

- Submit one of the sample scripts contained in the `$SGE_ROOT/examples/jobs` directory. Example:
  `qsub $SGE_ROOT/examples/jobs/sleeper.sh`

### Monitoring your Grid Engine jobs

- Use the qstat command to monitor the job's behavior.
  `qstat`

### Job output

- After the job finishes executing, check your home directory for the redirected stdout/stderr files `script-name.e`job-id and `script-name.o`job-id.

## Administering Grid Engine

Component | Startup Script | actions
qmaster | `${cfg.sge.root}/${cfg.cell.name}/common/sgemaster` | `start/stop`
execd | `${cfg.sge.root}/${cfg.cell.name}/common/sgeexecd` | `start/stop`

Startup messages can be found in SMF service log files.
You can get the name of the log file by calling svcs -l <SERVICE_NAME>
E.g.: `svcs -l svc:/application/sge/qmaster:${cfg.sge.cluster.name}`

Component | Log File Location
qmaster | `${cfg.qmaster.spool.dir}/messages`
execd | `<execd_spool_dir>/<hostname>/messages`

## Useful links

Oracle Grid Engine Documentation | http://docs.oracle.com/cd/E24901_01/index.htm
Grid Engine project home | http://gridscheduler.sourceforge.net/