Project

General

Profile

« Previous | Next » 

Revision 8933

Added by Jing Tao about 10 years ago

Added the code to check if the metacat backup file exists.
Added the code "exist 0" at the end of the scripts.

View differences:

src/scripts/bash/install-java7-tomcat7.sh
157 157

  
158 158
sudo /etc/init.d/apache2 start
159 159
sudo /etc/init.d/tomcat7 start
160

  
161
exit 0
src/scripts/bash/restore-dumped-data-to-pg9.3.sh
34 34
fi
35 35
METACAT_BACKUP_FILE_NAME=$1
36 36
echo "the backup file name is $METACAT_BACKUP_FILE_NAME"
37

  
38
if [ -f $METACAT_BACKUP_DIR/$METACAT_BACKUP_FILE_NAME ]; then
39
    echo "the metacat backup file $METACAT_BACKUP_DIR/$METACAT_BACKUP_FILE_NAME exists.";
40
else 
41
    echo "the metacat backup file $METACAT_BACKUP_DIR/$METACAT_BACKUP_FILE_NAME doesn't exist, please double check the name.";
42
    exit 1;
43
fi
44

  
37 45
DECOMPRESS_DIR_NAME=${METACAT_BACKUP_FILE_NAME%%.*}
38 46
echo "the decmporessed dir is $DECOMPRESS_DIR_NAME"
39 47

  
......
77 85
su - postgres  -c "/usr/lib/postgresql/$NEW_DB_VERSION/bin/vacuumdb --all"
78 86
echo "end to vacuum the db at "
79 87
echo `date`
80

  
88
exit 0

Also available in: Unified diff