-
Notifications
You must be signed in to change notification settings - Fork 368
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'ACME-Climate/jgfouca/cime/perf_data_fixes' (PR #1201)
Provide several fixes for the performance archiving to work with CIME5 Timing directory in RUNDIR needs to have lid appended Create timing.$LID.saved Do not include full directory hierarchy in tar files Copy all timing files to performance archive Restore support for mach_syslog In the case timing subdirectory, stop compressing the performance summary file and start compressing the raw global statistics timing data. For create_test, if save_timing is false, be sure to set SAVE_TIMING to False Fixes #1177 [BFB]
- Loading branch information
Showing
13 changed files
with
202 additions
and
68 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
#!/bin/csh -f | ||
# cori-haswell syslog script: | ||
# mach_syslog <sampling interval (in seconds)> <job identifier> <time stamp> <run directory> <timing directory> <output directory> | ||
|
||
set sec = 0 | ||
set sample_interval = $1 | ||
set jid = $2 | ||
set lid = $3 | ||
set run = $4 | ||
set timing = $5 | ||
set dir = $6 | ||
|
||
# wait until job mapping information is output before saving output file | ||
# (note that calling script 'touch'es the acme log file before spawning this script, so that 'wc' does not fail) | ||
set nnodes = `sqs -f $jid | grep NumNodes | sed 's/^ *NumNodes= *\([0-9]*\).*/\1/' ` | ||
set outlth = 0 | ||
while ($outlth < $nnodes) | ||
sleep 10 | ||
set outlth = `wc \-l $run/acme.log.$lid | sed 's/ *\([0-9]*\) *.*/\1/' ` | ||
end | ||
|
||
set TimeLimit = `sqs -f $jid | grep TimeLimit | sed 's/^ *RunTime=.*TimeLimit=\([0-9]*:[0-9]*:[0-9]*\) .*/\1/' ` | ||
set limit_hours = `echo $TimeLimit | sed 's/^0*\([0-9]*\):0*\([0-9]*\):0*\([0-9]*\)/\1/' ` | ||
set limit_mins = `echo $TimeLimit | sed 's/^0*\([0-9]*\):0*\([0-9]*\):0*\([0-9]*\)/\2/' ` | ||
set limit_secs = `echo $TimeLimit | sed 's/^0*\([0-9]*\):0*\([0-9]*\):0*\([0-9]*\)/\3/' ` | ||
if ("X$limit_hours" == "X") set limit_hours = 0 | ||
if ("X$limit_mins" == "X") set limit_mins = 0 | ||
if ("X$limit_secs" == "X") set limit_secs = 0 | ||
@ limit = 3600 * $limit_hours + 60 * $limit_mins + $limit_secs | ||
|
||
set RunTime = `sqs -f $jid | grep RunTime | sed 's/^ *RunTime=\([0-9]*:[0-9]*:[0-9]*\) .*/\1/' ` | ||
set runt_hours = `echo $RunTime | sed 's/^0*\([0-9]*\):0*\([0-9]*\):0*\([0-9]*\)/\1/' ` | ||
set runt_mins = `echo $RunTime | sed 's/^0*\([0-9]*\):0*\([0-9]*\):0*\([0-9]*\)/\2/' ` | ||
set runt_secs = `echo $RunTime | sed 's/^0*\([0-9]*\):0*\([0-9]*\):0*\([0-9]*\)/\3/' ` | ||
if ("X$runt_hours" == "X") set runt_hours = 0 | ||
if ("X$runt_mins" == "X") set runt_mins = 0 | ||
if ("X$runt_secs" == "X") set runt_secs = 0 | ||
@ runt = 3600 * $runt_hours + 60 * $runt_mins + $runt_secs | ||
|
||
@ remaining = $limit - $runt | ||
cat > $run/Walltime.Remaining <<EOF1 | ||
$remaining $sample_interval | ||
EOF1 | ||
/bin/cp --preserve=timestamps $run/acme.log.$lid $dir/acme.log.$lid.$remaining | ||
|
||
while ($remaining > 0) | ||
grep -a -i -e "nstep" -e "model date" $run/*atm.log.$lid | tail > $dir/atm.log.$lid.nstep.$remaining | ||
# grep -a -i "nstep" $run/acme.log.$lid | tail > $dir/acme.log.$lid.nstep.$remaining | ||
grep -a -i -e "timestep" -e "model date" $run/*lnd.log.$lid | tail > $dir/lnd.log.$lid.timestep.$remaining | ||
grep -a -i -e "timestep" -e "Step number" -e "model date" $run/*ocn.log.$lid | tail > $dir/ocn.log.$lid.stepnum.$remaining | ||
grep -a -i -e "timestep" -e "istep" -e "model date" $run/*ice.log.$lid | tail > $dir/ice.log.$lid.istep.$remaining | ||
grep -a -i "model date" $run/*cpl.log.$lid | tail > $dir/cpl.log.$lid.modeldata.$remaining | ||
/bin/cp --preserve=timestamps -u $timing/* $dir | ||
# xtnodestat > $dir/xtnodestat.$lid.$remaining | ||
sqs -w -a > $dir/sqsw.$lid.$remaining | ||
chmod a+r $dir/* | ||
sleep $sample_interval | ||
set RunTime = `sqs -f $jid | grep RunTime | sed 's/^ *RunTime=\([0-9]*:[0-9]*:[0-9]*\) .*/\1/' ` | ||
set runt_hours = `echo $RunTime | sed 's/^0*\([0-9]*\):0*\([0-9]*\):0*\([0-9]*\)/\1/' ` | ||
set runt_mins = `echo $RunTime | sed 's/^0*\([0-9]*\):0*\([0-9]*\):0*\([0-9]*\)/\2/' ` | ||
set runt_secs = `echo $RunTime | sed 's/^0*\([0-9]*\):0*\([0-9]*\):0*\([0-9]*\)/\3/' ` | ||
if ("X$runt_hours" == "X") set runt_hours = 0 | ||
if ("X$runt_mins" == "X") set runt_mins = 0 | ||
if ("X$runt_secs" == "X") set runt_secs = 0 | ||
@ runt = 3600 * $runt_hours + 60 * $runt_mins + $runt_secs | ||
@ remaining = $limit - $runt | ||
cat > $run/Walltime.Remaining << EOF2 | ||
$remaining $sample_interval | ||
EOF2 | ||
|
||
end | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.