From 70f5d393d232e421c71076ce728faa176e4628a8 Mon Sep 17 00:00:00 2001 From: "edward.safford" Date: Fri, 14 Jul 2023 17:01:43 +0000 Subject: [PATCH 1/4] Ref #92 Update transfer to work on hera. --- .../image_gen/ush/RunTransfer.sh | 12 +++++-- .../image_gen/ush/transfer.sh | 32 +++++++++++++++++-- 2 files changed, 38 insertions(+), 6 deletions(-) diff --git a/src/Radiance_Monitor/image_gen/ush/RunTransfer.sh b/src/Radiance_Monitor/image_gen/ush/RunTransfer.sh index f7ef1f91..cd354764 100755 --- a/src/Radiance_Monitor/image_gen/ush/RunTransfer.sh +++ b/src/Radiance_Monitor/image_gen/ush/RunTransfer.sh @@ -79,7 +79,8 @@ fi transfer_queue=dev_transfer jobname=transfer_${RADMON_SUFFIX} -export WEBDIR=${WEBDIR}/${RADMON_SUFFIX}/pngs +#export WEBDIR=${WEBDIR}/${RADMON_SUFFIX}/pngs +export WEBDIR=${WEBDIR}/${RADMON_SUFFIX} echo WEBDIR = $WEBDIR echo IMGNDIR = $IMGNDIR @@ -92,8 +93,13 @@ cmdfile="${transfer_work_dir}/transfer_cmd" echo "${IG_SCRIPTS}/transfer.sh" >$cmdfile chmod 755 $cmdfile +if [[ ${MY_MACHINE} = "hera" ]]; then + ${SUB} --account ${ACCOUNT} --ntasks=1 --mem=500M --time=45:00 -J ${jobname} \ + --partition service -o ${transfer_log} ${IG_SCRIPTS}/transfer.sh -$SUB -q $transfer_queue -A $ACCOUNT -o ${transfer_log} -e ${transfer_err} \ - -V -l select=1:mem=500M -l walltime=45:00 -N ${jobname} ${cmdfile} +elif [[ ${MY_MACHINE} = "wcoss2" ]]; then + $SUB -q $transfer_queue -A $ACCOUNT -o ${transfer_log} -e ${transfer_err} \ + -V -l select=1:mem=500M -l walltime=45:00 -N ${jobname} ${cmdfile} +fi exit diff --git a/src/Radiance_Monitor/image_gen/ush/transfer.sh b/src/Radiance_Monitor/image_gen/ush/transfer.sh index dd01e522..1fae59bb 100755 --- a/src/Radiance_Monitor/image_gen/ush/transfer.sh +++ b/src/Radiance_Monitor/image_gen/ush/transfer.sh @@ -1,9 +1,35 @@ #!/bin/bash -if [[ ${IMGNDIR} != "/" ]]; then +if [[ ${TANKimg} != "/" && -d ${TANKimg} ]]; then + + WEBSVR=${WEBSVR}.ncep.noaa.gov + + #---------------------------------------------------------- + # If the destination directory exists (on the server) then + # sync the html there with the $TANKimg directory so we + # have a backup copy. Note the pngs subdirectory is + # skipped -- we only want to update the html and related + # site files in $TANKimg, not the files in /pngs. Also + # note that the use of the --update option means that if a + # file exists in both places the destination file is not + # updated if it's newer. + # + # Else create the destintation directory on the server. + #---------------------------------------------------------- + + if ssh ${WEBUSER}@${WEBSVR} "[ -d ${WEBDIR} ]"; then + /usr/bin/rsync -ave ssh --exclude 'pngs/' --update \ + ${WEBUSER}@${WEBSVR}:${WEBDIR}/ ${TANKimg} + else + ssh ${WEBUSER}@${WEBSVR} "mkdir -p ${WEBDIR}" + fi + /usr/bin/rsync -ave ssh --exclude *.ctl.${Z} \ - --exclude 'horiz' --exclude *.png --delete-during ${IMGNDIR}/ \ - ${WEBUSER}@${WEBSVR}.ncep.noaa.gov:${WEBDIR}/ + --exclude 'horiz' --exclude *.png --delete-during --update ${TANKimg}/ \ + ${WEBUSER}@${WEBSVR}:${WEBDIR}/ + +else + echo "Unable to run rsync, TANKimg has bad/no value of: ${TANKimg}" fi exit From 1b5c41bcac907e5ed6d7a1a479768e350d383e7b Mon Sep 17 00:00:00 2001 From: "Edward.Safford" Date: Fri, 14 Jul 2023 18:19:23 +0000 Subject: [PATCH 2/4] Ref #92 Rm comments. --- src/Radiance_Monitor/image_gen/ush/RunTransfer.sh | 1 - 1 file changed, 1 deletion(-) diff --git a/src/Radiance_Monitor/image_gen/ush/RunTransfer.sh b/src/Radiance_Monitor/image_gen/ush/RunTransfer.sh index cd354764..86b79f79 100755 --- a/src/Radiance_Monitor/image_gen/ush/RunTransfer.sh +++ b/src/Radiance_Monitor/image_gen/ush/RunTransfer.sh @@ -79,7 +79,6 @@ fi transfer_queue=dev_transfer jobname=transfer_${RADMON_SUFFIX} -#export WEBDIR=${WEBDIR}/${RADMON_SUFFIX}/pngs export WEBDIR=${WEBDIR}/${RADMON_SUFFIX} echo WEBDIR = $WEBDIR echo IMGNDIR = $IMGNDIR From 3038854c48bf3c76a230e2255c68316fcae2fe59 Mon Sep 17 00:00:00 2001 From: "Edward.Safford" Date: Tue, 18 Jul 2023 13:39:54 +0000 Subject: [PATCH 3/4] Ref #92 Add queue plots from hera, update documentation. --- src/Radiance_Monitor/README | 6 +++--- src/Radiance_Monitor/image_gen/ush/RadMon_IG_glb.sh | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Radiance_Monitor/README b/src/Radiance_Monitor/README index 7438a8be..98c97988 100644 --- a/src/Radiance_Monitor/README +++ b/src/Radiance_Monitor/README @@ -69,9 +69,9 @@ and run: comrot/$PSLOT directory. This is only needed if your extraction was via global-workflow and NOT copied to $TANKDIR. -6. Move the data and html files to the web server (emcrzdm). If you're on wcoss2 and -have set up password free access to web server for your account, RadMon_IG_glb.sh will -queue the transfer script and move the files to the server. +6. Move the data and html files to the web server (emcrzdm). If you're on wcoss2 or +hera and have set up password free access to web server for your account, RadMon_IG_glb.sh +will queue the transfer script and move the files to the server. Alternately the transfer script, RunTransfer.sh, can be run from the command line: diff --git a/src/Radiance_Monitor/image_gen/ush/RadMon_IG_glb.sh b/src/Radiance_Monitor/image_gen/ush/RadMon_IG_glb.sh index 9cc5e812..9e4499ac 100755 --- a/src/Radiance_Monitor/image_gen/ush/RadMon_IG_glb.sh +++ b/src/Radiance_Monitor/image_gen/ush/RadMon_IG_glb.sh @@ -324,7 +324,7 @@ ${IG_SCRIPTS}/rm_img_files.pl --dir ${TANKimg}/pngs --nfl 30 #---------------------------------------------------------------------- if [[ $RUN_TRANSFER -eq 1 ]]; then - if [[ $MY_MACHINE = "wcoss2" ]]; then + if [[ $MY_MACHINE = "wcoss2" || $MY_MACHINE = "hera" ]]; then cmin=`date +%M` # minute (MM) ctime=`date +%G%m%d%H` # YYYYMMDDHH rtime=`$NDATE +1 $ctime` # ctime + 1 hour From a4484b5fcfa275e0c9a02980fa789029bda5244c Mon Sep 17 00:00:00 2001 From: "Edward.Safford" Date: Tue, 18 Jul 2023 14:14:30 +0000 Subject: [PATCH 4/4] Ref #92 Maybe fix the intel ci error. --- .github/workflows/intel.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/intel.yml b/.github/workflows/intel.yml index 0ff5c739..28018a95 100644 --- a/.github/workflows/intel.yml +++ b/.github/workflows/intel.yml @@ -9,7 +9,7 @@ defaults: # Set I_MPI_CC/F90 so Intel MPI wrapper uses icc/ifort instead of gcc/gfortran env: - cache_key: intel4 # The number (#) following the cache_key "intel" is to flush Action cache. + cache_key: intel5 # The number (#) following the cache_key "intel" is to flush Action cache. CC: icc FC: ifort CXX: icpc @@ -33,7 +33,7 @@ env: jobs: setup: - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest steps: # Cache spack, compiler and dependencies @@ -79,7 +79,7 @@ jobs: build: needs: setup - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest steps: - name: checkout-gsi-monitor