Ignore:
Timestamp:
Sep 8, 2017 8:25:41 AM (7 years ago)
Author:
raasch
Message:

new palm-scripts set to version number 1.0, further check for consistent restart settings

File:
1 edited

Legend:

Unmodified
Added
Removed
  • palm/trunk/SCRIPTS/palmrun

    r2420 r2422  
    2929# initial revision
    3030#
    31 # 2405 2017-09-05 11:17:46Z raasch
    32 #
    33 #
    3431#--------------------------------------------------------------------------------#
    3532# palmrun - script for running PALM jobs on local and remote hosts
     
    115112 user_source_path=""
    116113 use_openmp=false
    117  version="palmrun  0.9 Rev$Rev: 2303 $"
     114 version="palmrun  1.0 Rev$Rev: 2303 $"
    118115 working_directory=`pwd`
    119116 write_binary=""
     
    15091506    else
    15101507       printf "\n\n  *** creating executable and other sources for the local host"
     1508    fi
     1509
     1510       # FIRST CHECK, IF A MAKE DEPOSITORY EXISTS, AND IF NOT, ASK THE USER IF
     1511       # IT SHALL BE CREATED
     1512    ask_for_make_depository=false
     1513    if [[ $create_remote_batch_job = true ]]
     1514    then
     1515
     1516       line=`grep %base_directory $config_file`
     1517       make_depository=`echo $line | cut -d" " -s -f2`/MAKE_DEPOSITORY_${host_identifier}
     1518       echo "make_depository=$make_depository"
     1519       echo  "[[ ! -d ${make_depository} ]]  &&  echo depository not found" | ssh  -q  $ssh_key  ${remote_username}@${remote_ip} 2>&1  | tee ${host_identifier}_last_make_protokoll
     1520
     1521       if [[ $(grep -c "depository not found" ${host_identifier}_last_make_protokoll) != 0 ]]
     1522       then
     1523          printf "\n\n  +++ make depository \"${make_depository}\""
     1524          printf "\n      on remote host not found!"
     1525          ask_for_make_depository=true
     1526       fi
     1527       rm ${host_identifier}_last_make_protokoll
     1528
     1529    else
     1530
     1531          # CHECK FOR MAKE_DEPOSITORY ON THE LOCAL HOST
     1532       make_depository=${base_directory}/MAKE_DEPOSITORY_${host_identifier}
     1533       if [[ ! -d ${make_depository} ]]
     1534       then
     1535          printf "\n\n  +++ make depository \"${make_depository}\""
     1536          printf "\n      on local host not found!"
     1537          ask_for_make_depository=true
     1538       fi
     1539
     1540    fi
     1541
     1542    if [[ $ask_for_make_depository = true ]]
     1543    then
     1544
     1545       antwort=dummy
     1546       printf "\n\n"
     1547       printf "  >>> Create a new one (y/n) ?  "
     1548       while  read antwort
     1549       do
     1550          if [[ "$antwort" != y  &&  "$antwort" != Y  &&  "$antwort" != n  &&  "$antwort" != N ]]
     1551          then
     1552             printf "  >>> Create a new one (y/n) ?  "
     1553          else
     1554             break
     1555          fi
     1556       done
     1557       if [[ $antwort = n  ||  $antwort = N ]]
     1558       then
     1559          locat=user_abort; (( iec = 0 )); exit
     1560       fi
     1561
     1562       palmbuild  -v  -h $host_identifier
     1563
     1564       if [[ $? != 0 ]]
     1565       then
     1566   
     1567              # ABORT IN CASE OF COMPILATION PROBLEMS
     1568          printf "\n  +++ error while compiling for the MAKE_DEPOSITORY"
     1569          locat=make_depository
     1570          exit
     1571       else
     1572          echo "  *** now continue with creating executable and other sources"
     1573       fi
     1574
    15111575    fi
    15121576
Note: See TracChangeset for help on using the changeset viewer.