Next: 9 The Graphical User
Up: UsersGuide
Previous: 7 Common Aborts, Errors,
  Contents
Subsections
A number of supporting scripts are included in the CCSM2.0 release.
Some of these scripts are found in the scripts/test.a1 directory and
others are located in the scripts/tools directory. Scripts in the
test.a1 directory are experiment-specific and may need to be changed on
an experiment by experiment basis. Scripts in the tools serve as a
suite of utilities that are intended to be experiment- and machine-independent.
The $SCRIPTS/ccsm_archive and $SCRIPTS/test.a1.har scripts are supporting
scripts to the main CCSM run script . Both of these scripts are
run from the main script, $SCRIPTS/test.a1.run. By default,
calls to these scripts are currently commented out. These scripts are
used mainly for production runs. In addition, there is normally a
script call ccsm_joe that is created by the main script, test.a1.run,
to store job operating environment (joe)
variables and make them available to other supporting scripts.
- $SCRIPTS/ccsm_archive is executed in the main script, test.a1.run,
after the CCSM has finished running. The purpose of this script is
to move data from the executable directories to a separate directory
in order to stage the data for harvesting. In particular, the archiving
process moves data from $EXEROOT to $ARCROOT. ccsm_archive gets many of
the environment variables from ccsm_joe. Then, on a model-by-model
and file-by-file basis, ccsm_archive copies or moves data from the
executable directories to the archive directories. Users may need to
change the filenames to be archived for the different
models depending on the particular CASE setups.
- $SCRIPTS/test.a1.har is the ccsm harvester script and it is
submitted from the main script as a single-processor, serial, job. It
can also be run interactively. test.a1.har checks to see
whether a file has been harvested by first acquiring the file from the local
mass store and then differencing it with the local copy in the archive
directory. test.a1.har then either removes the local file or
copies the local copy of the file to the mass store. It also has the
ability to copy files to another location via the Unix copy (cp or scp)
commands.
- $SCRIPTS/ccsm_joe. which contains many experiment dependent variables
for use by other scripts. is generated by the main script,
$SCRIPTS/test.a1.run, every time it's executed. It also serves as a
point of reference for checking important environment variables. The
ccsm_joe script is generated by executing
scripts/tools/ccsm_checkenvs.
Under the scripts directory is a tools directory. There are several
generic utility scripts in this directory. The purpose of these scripts
is to provide a generic interface to mass storage systems at different
sites, to encapsulate a suite of commands into one utility, to provide a
hierarchical search capability for files, and to provide
machine-specific commands or notes necessary for running the code at
other sites. Scripts in the tools directory are meant to be completely
case independent. Some of the scripts require case-specific
information, which is provided by the ccsm_joe script. As mentioned
above, these utility scripts are meant to be generic. However, they
have been tested on a limited subset of the current available hardware
and therefore some limited modifications may be necessary. In
particular, the interface to the local mass storage system may need to
be altered in these scripts in order for them to work properly for new
hardware.
A brief description of the scripts in the tools directory is provided
below. The scripts are also self-commenting to help the user understand
and modify them.
- ccsm_checkenvs
Echos environment variables associated with a CCSM run. This script is used
to create the ccsm_joe file in the main run script. This script has no arguments.
- ccsm_cpdata [machine1:][dir1/]file1 [machine2:][dir2/][file2]
Generic utility to copy a file. Can identify whether cp or scp is
required based on an optional machine argument. Takes one or two
arguments.
- ccsm_getfile [dir1/]file1 [dir2/][file2]
Hierarchical search for a file. Search for a file in several sources
including locally, on the mass store, and on other machines. Copy
that file into dir2/file2. Takes one or two arguments.
- ccsm_getinput [dir1/]file1 [dir2/][file2]
Hierarchical search for a ccsm input file. Assumes the file will
exist under the specific directory "inputdata". dir1 represents
the directory path under inputdata to search for the file. Searches
locally, in the local inputdata file system, on the local mass store,
then at other sites for the file. Takes one or two arguments.
- ccsm_getrestart
Copies restart files from a specific restart archive directory into the working directories
of the components. This will eventually be configured to look for restart files
on the local mass store as well. No arguments.
- ccsm_msmkdir mssdir
Creates a directory on the local mass store. Takes one argument.
- ccsm_msread [mssdir/]file1 [locdir/][file2]
Copies a file from the local mass store to the local disk. Takes one
or two arguments.
- ccsm_mswrite [locdir/]file1 mssdir/[file2]
Copies a file to the local mass store from the local disk. Takes two
arguments.
- ccsm_splitdf [-d]/[-f]/[-h] dir/file
Returns the directory path or the filename for an argument like
dir/file. Can handle very general cases. -d returns the directory. -f returns the file. -h is help.
-f is the default return argument. Takes one argument.
- modules.*.*
Machine-specific setup scripts to run ccsm. No arguments. Called
specifically by the main ccsm script.
- test.a1.mods.*
These are notes about how to change the main test script to get it running
on other machines.
Next: 9 The Graphical User
Up: UsersGuide
Previous: 7 Common Aborts, Errors,
  Contents
csm@ucar.edu