Skip to content
Snippets Groups Projects
Commit e0a24bdd authored by Karl-Hermann Wieners's avatar Karl-Hermann Wieners
Browse files

mkexp: added tool 'duexp' to show disk usage by the given experiment

parent 80fa7b2b
No related branches found
No related tags found
No related merge requests found
......@@ -15,6 +15,7 @@ Global
* Added creation of config dump to mkexp (including backup)
* Changed mkexp namelist formatting to add multi-group identifiers as comment
* Changed merge of process environment ('DEFAULT' section) to be sorted
* Added tool 'duexp' to show disk usage by the given experiment
Release 1.0.0
=============
......
This diff is collapsed.
No preview for this file type
duexp 0 → 100755
#! /bin/sh
#
# Show disk usage for experiment using config information.
#
# $Id$
#
PROGRAM=`basename $0`
BINDIR=`dirname $0`
PATH="$BINDIR:$PATH"
die () {
echo "$@" >&2
exit 1
}
[ "x$1" = x ] && die "Oops: invalid number of parameters
Usage: $PROGRAM config_file [key=value...]"
CONFIG=$1
shift
eval `getexp -v "$CONFIG" "$@" || echo '
' exit $?`
du -ch --time \
$WORK_DIR \
$RESTART_DIR \
$SCRIPT_DIR \
$LOG_DIR \
$DATA_DIR \
$MON_DIR/$EXP_ID \
2> /dev/null |
sed "
s,$WORK_DIR,\$WORK_DIR,
s,$RESTART_DIR,\$RESTART_DIR,
s,$SCRIPT_DIR,\$SCRIPT_DIR,
s,$LOG_DIR,\$LOG_DIR,
s,$DATA_DIR,\$DATA_DIR,
s,$MON_DIR/$EXP_ID,\$MON_DIR/\$EXP_ID,
"
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment