/[CCFs]/bin/cif_manager
ViewVC logotype

Diff of /bin/cif_manager

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.2 by ccflib, Fri Mar 6 16:06:19 2015 UTC revision 1.3 by ccflib, Mon Mar 9 10:01:59 2015 UTC
# Line 12  Line 12 
12  #  #
13  # This script is run 15 min after the hour for all hours of day by cron.  # This script is run 15 min after the hour for all hours of day by cron.
14  #  #
15  # $Id: cif_manager,v 1.1 2015/03/06 15:38:56 ccflib Exp $  # $Id: cif_manager,v 1.2 2015/03/06 16:06:19 ccflib Exp $
16    
17    
18  # 1) Synchronizes both directories  # 1) Synchronizes both directories
# Line 25  rsync -a -e ssh ccflib@xmm.esac.esa.int: Line 25  rsync -a -e ssh ccflib@xmm.esac.esa.int:
25    
26  for file in `ls -1tr /home/ccflib/ftp-area/download/*xmm-newton.cif`  for file in `ls -1tr /home/ccflib/ftp-area/download/*xmm-newton.cif`
27  do  do
28          file=`basename $file`          filebase=`basename $file`
29          registered=`grep -c "$file" /home/ccflib/ftp-area/download/DELIVERY_LOG`          registered=`grep -c "$filebase" /home/ccflib/ftp-area/download/DELIVERY_LOG`
30          [ "$registered" = "1" ] && continue          [ "$registered" = "1" ] && continue
31          mtime=`stat --printf=%y $file | awk -F"." '{print $1}'`          mtime=`stat --printf=%y $file | awk -F"." '{print $1}'`
32          printf "%-40s %-10s %-10s\n" $file $mtime          printf "%-40s %-10s %-10s\n" $filebase $mtime
33  done >> /home/ccflib/ftp-area/download/DELIVERY_LOG  done >> /home/ccflib/ftp-area/download/DELIVERY_LOG
34    
35  # 3) Runs on xvsoc01 through ssh the clean_cif_files and clean_uploaded_files scripts  # 3) Runs on xvsoc01 through ssh the clean_cif_files and clean_uploaded_files scripts

Legend:
Removed from v.1.2  
changed lines
  Added in v.1.3

  ViewVC Help
Powered by ViewVC 1.1.27