The name of the sample script shown in Figure 16 is run_spice_job. This script illustrates the following:
All file names that are not fully qualified are relative to the initial working directory /home/loadl/spice. LoadLeveler will send the job steps 0 and 1 of this job to a machine for that has a real memory of 64 MB or more for execution. Job step 2 most likely will be sent to a machine that has more that 128 MB of real memory and has the ESSL library installed since these preferences have been stated using the LoadLeveler preferences keyword. LoadLeveler will send job step 3 to the machine ll5.pok.ibm.com for execution because of the explicit requirement for this machine in the requirements statement.
Figure 16. Job Command File Used as the Executable
#!/bin/ksh # @ job_name = spice_test # @ account_no = 99999 # @ class = small # @ arguments = spice3f5_input_$(stepid) spice3f5_output_$(stepid) # @ input = spice2g6_input_$(stepid) # @ output = $(job_name)_output_$(stepid) # @ error = $(job_name)_error_$(stepid) # @ initialdir = /home/loadl/spice # @ requirements = ((Arch == "R6000") && (OpSys == "AIX43") && (Memory > 64)) # @ queue # @ queue # @ preferences = ((Memory > 128) && (Feature == "ESSL")) # @ queue # @ class = large # @ arguments = spice3f5_input_benchmark1 spice3f5_output_benchmark1 # @ requirements = (Machine == "ll5.pok.ibm.com") # @ input = spice2g6_input_benchmark1 # @ output = $(job_name)_output_benchmark1 # @ error = $(job_name)_error_benchmark1 # @ queue OS_NAME= `uname` case $OS_NAME in AIX) echo "Running $OS_NAME version of spice3f5" > $2 AIX_bin/spice3f5 < $1 >> $2 2>&1 echo "Running $OS_NAME version of spice2g6" AIX_bin/spice2g6 ;; *) echo "spice3f5 for $OS_NAME is not available" > $2 echo "spice2g6 for $OS_NAME is not available" ;; esac |