Changeset 1094 for palm/trunk/SCRIPTS/mrun
- Timestamp:
- Feb 3, 2013 1:52:12 AM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
palm/trunk/SCRIPTS/mrun
r1091 r1094 22 22 # Current revisions: 23 23 # ------------------ 24 # 24 # explicit ssh/scp port can be set in config file with environment variable 25 # scp_port. This port is handled to all ssh/scp/batch_scp calls. 25 26 # 26 27 # Former revisions: … … 1100 1101 1101 1102 1103 # Set port number option for calls of ssh/scp, subjob and batch_scp scripts 1104 if [[ "$scp_port" != "" ]] 1105 then 1106 PORTOPT="-P $scp_port" 1107 SSH_PORTOPT="-p $scp_port" 1108 fi 1109 1110 1102 1111 # FALLS NICHT VORGEGEBEN, DEFAULT-QUEUE AUF DER ZIELMASCHINE FESTLEGEN 1103 1112 if [[ $queue = none ]] … … 2741 2750 then 2742 2751 # init_cmds was ". /SX/opt/etc/initsx.sh;" 2743 ssh 136.172.44.192 -l $usern "$init_cmds $module_calls cd \$HOME/work/${usern}.$kennung; sxmake $mopts -f Makefile PROG=a.out F90=$compiler_name COPT=\"$cpp_options\" F90FLAGS=\"$fopts\" LDFLAGS=\"$lopts\" "2752 ssh $SSH_PORTOPT 136.172.44.192 -l $usern "$init_cmds $module_calls cd \$HOME/work/${usern}.$kennung; sxmake $mopts -f Makefile PROG=a.out F90=$compiler_name COPT=\"$cpp_options\" F90FLAGS=\"$fopts\" LDFLAGS=\"$lopts\" " 2744 2753 cp $TEMPDIR_COMPILE/a.out . 2745 2754 [[ $? != 0 ]] && compile_error=true … … 2748 2757 then 2749 2758 printf " compiler is called via ssh on \"plogin1\" \n" 2750 ssh plogin1 -l $usern "$init_cmds export PATH=/sw/ibm/xlf/13.1.0.8/usr/bin:$PATH; $module_calls cd $TEMPDIR; make $mopts -f Makefile PROG=a.out F90=$compiler_name COPT=\"$cpp_options\" F90FLAGS=\"$fopts\" LDFLAGS=\"$lopts\" "2759 ssh $SSH_PORTOPT plogin1 -l $usern "$init_cmds export PATH=/sw/ibm/xlf/13.1.0.8/usr/bin:$PATH; $module_calls cd $TEMPDIR; make $mopts -f Makefile PROG=a.out F90=$compiler_name COPT=\"$cpp_options\" F90FLAGS=\"$fopts\" LDFLAGS=\"$lopts\" " 2751 2760 [[ ! -f a.out ]] && compile_error=true 2752 2761 continue # ANDERENFALLS IST STATUS=1, FALLS A.OUT VORHANDEN … … 2754 2763 then 2755 2764 printf " compiler is called via ssh on \"bicegate0\" \n" 2756 ssh bicegate0 -l $usern "$init_cmds $module_calls cd $TEMPDIR; make $mopts -f Makefile PROG=a.out F90=$compiler_name COPT=\"$cpp_options\" F90FLAGS=\"$fopts\" LDFLAGS=\"$lopts\" "2765 ssh $SSH_PORTOPT bicegate0 -l $usern "$init_cmds $module_calls cd $TEMPDIR; make $mopts -f Makefile PROG=a.out F90=$compiler_name COPT=\"$cpp_options\" F90FLAGS=\"$fopts\" LDFLAGS=\"$lopts\" " 2757 2766 [[ ! -f a.out ]] && compile_error=true 2758 2767 continue # ANDERENFALLS IST STATUS=1, FALLS A.OUT VORHANDEN … … 2760 2769 then 2761 2770 printf " compiler is called via ssh on \"hicegate0\" \n" 2762 ssh hicegate0 -l $usern "$init_cmds $module_calls cd $TEMPDIR; make $mopts -f Makefile PROG=a.out F90=$compiler_name COPT=\"$cpp_options\" F90FLAGS=\"$fopts\" LDFLAGS=\"$lopts\" 2>&1 "2771 ssh $SSH_PORTOPT hicegate0 -l $usern "$init_cmds $module_calls cd $TEMPDIR; make $mopts -f Makefile PROG=a.out F90=$compiler_name COPT=\"$cpp_options\" F90FLAGS=\"$fopts\" LDFLAGS=\"$lopts\" 2>&1 " 2763 2772 [[ ! -f a.out ]] && compile_error=true 2764 2773 continue # ANDERENFALLS IST STATUS=1, FALLS A.OUT VORHANDEN … … 2766 2775 then 2767 2776 printf " compiler is called via ssh on \"flow\" \n" 2768 ssh flow02.hpc.uni-oldenburg.de -l $usern "$init_cmds $module_calls cd $TEMPDIR; make $mopts -f Makefile PROG=a.out F90=$compiler_name COPT=\"$cpp_options\" F90FLAGS=\"$fopts\" LDFLAGS=\"$lopts\" "2777 ssh $SSH_PORTOPT flow02.hpc.uni-oldenburg.de -l $usern "$init_cmds $module_calls cd $TEMPDIR; make $mopts -f Makefile PROG=a.out F90=$compiler_name COPT=\"$cpp_options\" F90FLAGS=\"$fopts\" LDFLAGS=\"$lopts\" " 2769 2778 [[ ! -f a.out ]] && compile_error=true 2770 2779 continue # ANDERENFALLS IST STATUS=1, FALLS A.OUT VORHANDEN … … 2971 2980 if [[ $localhost = lcsgih ]] 2972 2981 then 2973 ssh $ usern@hicedata.hlrn.de "cp $PERM/${frelin[$i]} $PWD"2982 ssh $SSH_PORTOPT $usern@hicedata.hlrn.de "cp $PERM/${frelin[$i]} $PWD" 2974 2983 else 2975 ssh $ usern@bicedata.hlrn.de "cp $PERM/${frelin[$i]} $PWD"2984 ssh $SSH_PORTOPT $usern@bicedata.hlrn.de "cp $PERM/${frelin[$i]} $PWD" 2976 2985 fi 2977 2986 else … … 2981 2990 if [[ $localhost = lcsgih ]] 2982 2991 then 2983 ssh $ usern@hicedata.hlrn.de "cd $PWD; tar xf $PERM/${frelin[$i]}/${frelin[$i]}.node_$inode.tar"2992 ssh $SSH_PORTOPT $usern@hicedata.hlrn.de "cd $PWD; tar xf $PERM/${frelin[$i]}/${frelin[$i]}.node_$inode.tar" 2984 2993 else 2985 ssh $ usern@bicedata.hlrn.de "cd $PWD; tar xf $PERM/${frelin[$i]}/${frelin[$i]}.node_$inode.tar"2994 ssh $SSH_PORTOPT $usern@bicedata.hlrn.de "cd $PWD; tar xf $PERM/${frelin[$i]}/${frelin[$i]}.node_$inode.tar" 2986 2995 fi 2987 2996 (( inode = inode + 1 )) … … 3940 3949 printf "\n ${pathout[$i]}/${localhost}_${fname}${endout[$i]}$cst" 3941 3950 printf "\n or higher cycle\n" 3942 echo "batch_scp $ cps -b -m -u $return_username $return_addres $file_to_transfer \"${pathout[$i]}\" ${localhost}_${fname}${endout[$i]} ${extout[$i]}" >> transfer_${localout[$i]}3951 echo "batch_scp $PORTOPT $cps -b -m -u $return_username $return_addres $file_to_transfer \"${pathout[$i]}\" ${localhost}_${fname}${endout[$i]} ${extout[$i]}" >> transfer_${localout[$i]} 3943 3952 3944 3953 echo "[[ \$? = 0 ]] && rm $file_to_transfer" >> transfer_${localout[$i]} … … 3946 3955 if [[ $localhost = nech ]] 3947 3956 then 3948 subjob -d -c /pf/b/$usern/job_queue -v -q pp -X 0 -m 1000 -t 900 transfer_${localout[$i]}3957 subjob -d -c /pf/b/$usern/job_queue -v -q pp -X 0 -m 1000 -t 900 $PORTOPT transfer_${localout[$i]} 3949 3958 else 3950 3959 if [[ "$LOGNAME" = b323013 ]] 3951 3960 then 3952 subjob -v -q c1 -X 0 -m 1000 -t 900 -c $job_catalog transfer_${localout[$i]}3961 subjob -v -q c1 -X 0 -m 1000 -t 900 -c $job_catalog $PORTOPT transfer_${localout[$i]} 3953 3962 else 3954 subjob -d -v -q c1 -X 0 -m 1000 -t 900 -c $job_catalog transfer_${localout[$i]}3963 subjob -d -v -q c1 -X 0 -m 1000 -t 900 -c $job_catalog $PORTOPT transfer_${localout[$i]} 3955 3964 fi 3956 3965 fi … … 3962 3971 printf "\n >>> OUTPUT: ${localout[$i]}$cst by SCP to" 3963 3972 printf "\n ${pathout[$i]}/${localhost}_${fname}${endout[$i]}$cst\n" 3964 batch_scp $ cps -b -m -u $return_username $return_addres ${localout[$i]} "${pathout[$i]}" ${localhost}_${fname}${endout[$i]} ${extout[$i]}3973 batch_scp $PORTOPT $cps -b -m -u $return_username $return_addres ${localout[$i]} "${pathout[$i]}" ${localhost}_${fname}${endout[$i]} ${extout[$i]} 3965 3974 [[ $? != 0 ]] && transfer_failed=true 3966 3975 … … 4015 4024 printf "\n ${pathout[$i]}/${localhost}_${fname}${endout[$i]}" 4016 4025 printf "\n or higher cycle\n" 4017 echo "batch_scp -A -b -m -u $return_username $return_addres $file_to_transfer \"${pathout[$i]}\" ${localhost}_${fname}${endout[$i]} ${extout[$i]}" >> transfer_${localout[$i]}4026 echo "batch_scp $PORTOPT -A -b -m -u $return_username $return_addres $file_to_transfer \"${pathout[$i]}\" ${localhost}_${fname}${endout[$i]} ${extout[$i]}" >> transfer_${localout[$i]} 4018 4027 4019 4028 echo "[[ \$? = 0 ]] && rm $file_to_transfer" >> transfer_${localout[$i]} … … 4021 4030 if [[ $localhost = nech ]] 4022 4031 then 4023 subjob -d -c /pf/b/$usern/job_queue -v -q pp -X 0 -m 1000 -t 900 transfer_${localout[$i]}4032 subjob -d -c /pf/b/$usern/job_queue -v -q pp -X 0 -m 1000 -t 900 $PORTOPT transfer_${localout[$i]} 4024 4033 else 4025 4034 if [[ $LOGNAME = b323013 ]] 4026 4035 then 4027 subjob -v -q c1 -X 0 -m 1000 -t 900 -c $job_catalog transfer_${localout[$i]}4036 subjob -v -q c1 -X 0 -m 1000 -t 900 -c $job_catalog $PORTOPT transfer_${localout[$i]} 4028 4037 else 4029 subjob -d -v -q c1 -X 0 -m 1000 -t 900 -c $job_catalog transfer_${localout[$i]}4038 subjob -d -v -q c1 -X 0 -m 1000 -t 900 -c $job_catalog $PORTOPT transfer_${localout[$i]} 4030 4039 fi 4031 4040 fi … … 4037 4046 printf "\n >>> OUTPUT: ${localout[$i]} append by SCP to" 4038 4047 printf "\n ${pathout[$i]}/${localhost}_${fname}${endout[$i]}\n" 4039 batch_scp -A -b -m -u $return_username $return_addres ${localout[$i]} "${pathout[$i]}" ${localhost}_${fname}${endout[$i]} ${extout[$i]}4048 batch_scp $PORTOPT -A -b -m -u $return_username $return_addres ${localout[$i]} "${pathout[$i]}" ${localhost}_${fname}${endout[$i]} ${extout[$i]} 4040 4049 [[ $? != 0 ]] && transfer_failed=true 4041 4050 … … 4215 4224 if [[ $localhost = lcsgih || $localhost = lcsgib ]] 4216 4225 then 4217 # subjob -d -v -q cdata -X 0 -m 1000 -t 43200 -c $job_catalog archive_${frelout[$i]}4218 subjob -v -q permq -X 1 -T 1 -m 1000 -t 172800 -c $job_catalog archive_${frelout[$i]}4226 # subjob -d -v -q cdata -X 0 -m 1000 -t 43200 -c $job_catalog $PORTOPT archive_${frelout[$i]} 4227 subjob -v -q permq -X 1 -T 1 -m 1000 -t 172800 -c $job_catalog $PORTOPT archive_${frelout[$i]} 4219 4228 elif [[ $localhost = nech ]] 4220 4229 then 4221 subjob -d -c /pf/b/$usern/job_queue -v -q pp -X 0 -m 1000 -t 7200 archive_${frelout[$i]}4230 subjob -d -c /pf/b/$usern/job_queue -v -q pp -X 0 -m 1000 -t 7200 $PORTOPT archive_${frelout[$i]} 4222 4231 fi 4223 4232 printf " Archiving of $tmp_data_catalog/${frelout[$i]} initiated (batch job submitted)\n" … … 4340 4349 fi 4341 4350 4342 subjob -v -d -q cdata -X 0 -m 1000 -t 43200 -c $job_catalog archive_${frelout[$i]}4351 subjob -v -d -q cdata -X 0 -m 1000 -t 43200 -c $job_catalog $PORTOPT archive_${frelout[$i]} 4343 4352 printf " Archiving of $tmp_data_catalog/${frelout[$i]} initiated (batch job submitted)\n" 4344 4353 file_saved=true … … 4374 4383 fi 4375 4384 4376 subjob -v -c /pf/b/$usern/job_queue -d -q pp -X 0 -m 1000 -t 7200 archive_${frelout[$i]}4385 subjob -v -c /pf/b/$usern/job_queue -d -q pp -X 0 -m 1000 -t 7200 $PORTOPT archive_${frelout[$i]} 4377 4386 printf " Archiving of $tmp_data_catalog/${frelout[$i]} initiated (batch job submitted)\n" 4378 4387 file_saved=true … … 4527 4536 if [[ $(echo $return_addres | grep -c "130.75.105") = 1 ]] 4528 4537 then 4529 ssh $ return_addres -l $return_username "PATH=\$PATH:$LOCAL_MRUN_PATH;. /muksoft/packages/intel/bin/compilervars.sh intel64;export PALM_BIN=$LOCAL_MRUN_PATH;cd $LOCAL_PWD; $mc "4538 ssh $SSH_PORTOPT $return_addres -l $return_username "PATH=\$PATH:$LOCAL_MRUN_PATH;. /muksoft/packages/intel/bin/compilervars.sh intel64;export PALM_BIN=$LOCAL_MRUN_PATH;cd $LOCAL_PWD; $mc " 4530 4539 else 4531 4540 if [[ $localhost = ibmkisti ]] 4532 4541 then 4533 ssh $ usern@gaiad "ssh$return_addres -l $return_username \"PATH=\\\$PATH:$LOCAL_MRUN_PATH;export PALM_BIN=$LOCAL_MRUN_PATH;cd $LOCAL_PWD; $mc\" "4542 ssh $SSH_PORTOPT $usern@gaiad "ssh $SSH_PORTOPT $return_addres -l $return_username \"PATH=\\\$PATH:$LOCAL_MRUN_PATH;export PALM_BIN=$LOCAL_MRUN_PATH;cd $LOCAL_PWD; $mc\" " 4534 4543 else 4535 ssh $ return_addres -l $return_username "PATH=\$PATH:$LOCAL_MRUN_PATH;export PALM_BIN=$LOCAL_MRUN_PATH;cd $LOCAL_PWD; $mc "4544 ssh $SSH_PORTOPT $return_addres -l $return_username "PATH=\$PATH:$LOCAL_MRUN_PATH;export PALM_BIN=$LOCAL_MRUN_PATH;cd $LOCAL_PWD; $mc " 4536 4545 fi 4537 4546 fi … … 4557 4566 if [[ $localhost = lcfimm ]] 4558 4567 then 4559 ssh $ return_addres -l $return_username "PATH=\$PATH:$LOCAL_MRUN_PATH;export PALM_BIN=$LOCAL_MRUN_PATH;cd $LOCAL_PWD; $mc "4568 ssh $SSH_PORTOPT $return_addres -l $return_username "PATH=\$PATH:$LOCAL_MRUN_PATH;export PALM_BIN=$LOCAL_MRUN_PATH;cd $LOCAL_PWD; $mc " 4560 4569 else 4561 4570 eval $mc # ' MUESSEN AUSGEWERTET WERDEN … … 4708 4717 if [[ $host != ibmkisti ]] 4709 4718 then 4710 echo "scp -r$return_username@$return_addres:$working_directory/SOURCES_FOR_RUN_$fname ." >> $jobfile4719 echo "scp $PORTOPT -r $return_username@$return_addres:$working_directory/SOURCES_FOR_RUN_$fname ." >> $jobfile 4711 4720 else 4712 4721 # on KISTI's IBM firewall is only opened on interactive node 4713 4722 echo "localdir=\`pwd\`" >> $jobfile 4714 echo "ssh $ remote_username@gaiad \"cd \$localdir; scp-r $return_username@$return_addres:$working_directory/SOURCES_FOR_RUN_$fname .\" " >> $jobfile4723 echo "ssh $SSH_PORTOPT $remote_username@gaiad \"cd \$localdir; scp $PORTOPT -r $return_username@$return_addres:$working_directory/SOURCES_FOR_RUN_$fname .\" " >> $jobfile 4715 4724 fi 4716 4725 fi … … 4800 4809 echo "%END%" >> $jobfile 4801 4810 else 4802 echo "batch_scp -b -o -g -s -u $return_username $return_addres ${remotepathin[$i]} \"${pathin[$i]}\" ${frelin[$i]}" >> $jobfile4811 echo "batch_scp $PORTOPT -b -o -g -s -u $return_username $return_addres ${remotepathin[$i]} \"${pathin[$i]}\" ${frelin[$i]}" >> $jobfile 4803 4812 fi 4804 4813 … … 4850 4859 fi 4851 4860 4852 subjob $job_on_file -h $host -u $remote_username -g $group_number -q $queue -m $memory -N $node_usage -t $cpumax $XOPT $TOPT $OOPT -n $fname -v -c $job_catalog -e $email_notification $ jobfile4861 subjob $job_on_file -h $host -u $remote_username -g $group_number -q $queue -m $memory -N $node_usage -t $cpumax $XOPT $TOPT $OOPT -n $fname -v -c $job_catalog -e $email_notification $PORTOPT $jobfile 4853 4862 rm -rf $jobfile 4854 4863
Note: See TracChangeset
for help on using the changeset viewer.