Changeset 4303 for palm/trunk/SCRIPTS


Ignore:
Timestamp:
Nov 25, 2019 8:55:18 AM (5 years ago)
Author:
raasch
Message:

Abort if temporary working catalog / SOURCES_FOR_RUN catalog cannot be created

Location:
palm/trunk/SCRIPTS
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • palm/trunk/SCRIPTS/palmbuild

    r4082 r4303  
    2727# -----------------
    2828# $Id$
     29# Abort if SOURCES_FOR_RUN catalog cannot be created
     30#
     31# 4082 2019-07-10 14:42:00Z raasch
    2932# bugfix for executing module commands and for interpreting linker options
    3033# on local machines
     
    682685          printf "\n  *** copy MAKE_DEPOSITORY_${configuration_identifier} on remote host to $sources_for_run_catalog \n"
    683686       fi
    684        ssh  -q  $ssh_key  ${remote_username}@${remote_ip}  "rm -rf ${fast_io_catalog}/${sources_for_run_catalog}; mkdir -p ${fast_io_catalog}/${sources_for_run_catalog}; cp ${make_depository}/${program_name}_current_version.tar  ${fast_io_catalog}/${sources_for_run_catalog}; cd ${fast_io_catalog}/${sources_for_run_catalog}; tar xf ${program_name}_current_version.tar"  2>&1
     687       ssh  -q  $ssh_key  ${remote_username}@${remote_ip}  "rm -rf ${fast_io_catalog}/${sources_for_run_catalog}; mkdir -p ${fast_io_catalog}/${sources_for_run_catalog}; [[ \$? != 0 ]] && exit 1; cp ${make_depository}/${program_name}_current_version.tar  ${fast_io_catalog}/${sources_for_run_catalog}; cd ${fast_io_catalog}/${sources_for_run_catalog}; tar xf ${program_name}_current_version.tar"  2>&1
     688       if [[ $? != 0 ]]
     689       then
     690          printf "\n  +++ SOURCES_FOR_RUN catalog cannot be created."
     691          printf "\n      Check setting of variable fast_io_catalog in your config file."
     692          locat=temporary_working_directory
     693          exit
     694       fi
    685695
    686696
     
    916926       rm -rf ${fast_io_catalog}/${sources_for_run_catalog}
    917927       mkdir -p ${fast_io_catalog}/${sources_for_run_catalog}
     928       if [[ $? != 0 ]]
     929       then
     930          printf "\n  +++ SOURCES_FOR_RUN catalog cannot be created."
     931          printf "\n      Check setting of variable fast_io_catalog in your config file."
     932          locat=execution
     933          exit
     934       fi
    918935       cp ${make_depository}/${program_name}_current_version.tar  ${fast_io_catalog}/${sources_for_run_catalog}
    919936       cd $fast_io_catalog/${sources_for_run_catalog}
  • palm/trunk/SCRIPTS/palmrun

    r3982 r4303  
    2727# -----------------
    2828# $Id$
     29# Abort if temporary working catalog cannot be created
     30#
     31# 3982 2019-05-16 11:07:31Z raasch
    2932# bugfix: -b is not added in automatically generated batch jobs for remote hosts
    3033#
     
    19891992          # CREATE THE DIRECTORY
    19901993       mkdir -p  $tempdir
     1994       if [[ $? != 0 ]]
     1995       then
     1996          printf "\n  +++ temporary working directory cannot be created."
     1997          printf "\n      Check setting of variable fast_io_catalog in your config file."
     1998          locat=execution
     1999          exit
     2000       fi
    19912001       chmod  go+rx  $tempdir
    19922002       cd  $tempdir
     
    29953005    then
    29963006       echo  "mkdir  $tempdir"           >>  $jobfile
     3007       echo  "if [[ \$? != 0 ]]"         >>  $jobfile
     3008       echo  "then"                      >>  $jobfile
     3009       echo  "   echo \"+++ temporary working directory cannot be created.\" "  >>  $jobfile
     3010       echo  "   echo \"    Check setting of variable fast_io_catalog in your config file.\" "  >>  $jobfile
     3011       echo  "   exit"                   >>  $jobfile
     3012       echo  "fi"                        >>  $jobfile
    29973013       echo  "chmod  go+rx  $tempdir"    >>  $jobfile
    29983014    else
     
    30013017          # BATCH DIRECTIVE -wd AND MUST ALREADY EXIST WHEN THE JOB IS SUBMITTED)
    30023018       mkdir  $tempdir
     3019       if [[ $? != 0 ]]
     3020       then
     3021          printf "\n  +++ temporary working directory cannot be created."
     3022          printf "\n      Check setting of variable fast_io_catalog in your config file."
     3023          locat=execution
     3024          exit
     3025       fi
    30033026       chmod  go+rx  $tempdir
    30043027    fi
Note: See TracChangeset for help on using the changeset viewer.