![]() ![]() |
![]() |
File: [Development] / JSOC / gen_sumcf.csh
(download)
/
(as text)
Revision: 1.1, Thu Apr 23 04:51:13 2009 UTC (14 years, 1 month ago) by rick Branch: MAIN script for SUMS_MANAGER to generate initial template sum_rm.cf |
# check that local config file has been edited appropriately if ($#LOCAL_CONFIG_SET == 1) then if ($LOCAL_CONFIG_SET =~ "NO") then echo "Error: local configuration file $LOCALINF must be edited" echo " After editing the file appropriately, rerun this script ($0)" exit endif endif if ($#SUMS_LOG_BASEDIR != 1) then echo "Error: $SUMS_LOG_BASEDIR undefined in local configuration file $LOCALINF" exit endif if ($#SUMS_MANAGER != 1) then echo "Error: SUMS_MANAGER undefined in local configuration file $LOCALINF" exit endif set SUMRM_CONFIG = $SUMS_LOG_BASEDIR/sum_rm.cf if (-e $SUMRM_CONFIG) then echo "A sum_rm.cf configuration file already exists in $SUMS_LOG_BASEDIR" echo " Edit it at any time to modify the configuration" exit endif echo "# configuration file for sum_rm program" >> $SUMRM_CONFIG echo "#" >> $SUMRM_CONFIG echo "# You may edit this file any time, it is read each time sum_rm is run," >> $SUMRM_CONFIG echo "# which will occur at the intervals specified by the SLEEP parameter" >> $SUMRM_CONFIG echo "#" >> $SUMRM_CONFIG echo "# when sum_rm finishes, sleep for n seconds before re-running" >> $SUMRM_CONFIG echo "SLEEP=3600" >> $SUMRM_CONFIG echo "# delete until this many Megabytes are free on the specified SUMS disk" >> $SUMRM_CONFIG echo "# partitions (one entry, numbered 0-n, for each partition" >> $SUMRM_CONFIG echo "MAX_FREE_0=100000" >> $SUMRM_CONFIG echo "# name of the log file (opened at startup; date and pid are appended to this" >> $SUMRM_CONFIG echo "# name); do not change the directory without changing SUMS_LOG_BASEDIR in" >> $SUMRM_CONFIG echo "# the config.local and rebuilding sums" >> $SUMRM_CONFIG echo "LOG=$SUMS_LOG_BASEDIR/sum_rm.log" >> $SUMRM_CONFIG echo "# whom to bother when there's a notable problem" >> $SUMRM_CONFIG echo "MAIL=$SUMS_MANAGER" >> $SUMRM_CONFIG echo "# to prevent sum_rm from doing anything set non-zero (for testing)" >> $SUMRM_CONFIG echo "NOOP=0" >> $SUMRM_CONFIG echo "# sum_rm can only be enabled for a single user" >> $SUMRM_CONFIG echo "USER=$SUMS_MANAGER" >> $SUMRM_CONFIG echo "# dont run sum_rm between these NORUN hours of the day (0-23)" >> $SUMRM_CONFIG echo "# comment out to ignore or set them both to the same hour" >> $SUMRM_CONFIG echo "# The NORUN_STOP must be >= NORUN_START" >> $SUMRM_CONFIG echo "# dont run when the hour first hits NORUN_START" >> $SUMRM_CONFIG echo "NORUN_START=7" >> $SUMRM_CONFIG echo "# start running again when the hour first hits NORUN_STOP" >> $SUMRM_CONFIG echo "NORUN_STOP=7" >> $SUMRM_CONFIG echo "A sum_rm.cf configuration file with default values has been generated" echo " in $SUMS_LOG_BASEDIR" echo "Review and edit the values as appropriate; in particular, if there is" echo " more than one SUMS disk partition, add the appropriate number of" echo " MAX_FREE_n lines and values"
Karen Tian |
Powered by ViewCVS 0.9.4 |