AnsweredAssumed Answered

CRONTAB - Backup

Question asked by juztrockwitit on Jul 17, 2009
Latest reply on Jul 17, 2009 by juztrockwitit
Hallo verehrte User,
suche nach einem BRAUCHBAREN Script damit mein Alfresco 3.2 (CE) System (läuft auf nem Ubuntu 9.04 Server Edition)
wöchentlich Sonntag´s um 12 Uhr geBACKUPed wird.

Versuche mich momentan an diesem Script aus dem Englischen Alfresco Forum :

    #!/bin/bash
    Days=`date +%Y%m%d-%H%M%S`;
    Alfresco_root="/opt/alfresco3";
    Alfresco_repository="$Alfresco_root/alfresco_repository/";
    Alfresco_indexes="$Alfresco_root/alfresco_indexes/";
    Alfresco_backup_dir="/opt/Alfresco_Backup_$Days";
    user_mysql="alfresco";
    user_password="alfresco";
    alfresco_db="alfresco";

    echo "=== Stoping Alfresco ==="
    echo $Alfresco_root/alfresco.sh stop
    echo sleep 10;
    echo "=== Making the directory backup $Alfresco_backup_dir ==="
    echo mkdir $Alfresco_backup_dir;
    echo cd $Alfresco_backup_dir;
    echo "=== Make Mysql Backup ==="
    echo mysqldump –user=$user_mysql –password=$user_password $alfresco_db -q –single-transaction -R -t –disable-keys –complete-insert| bzip2 > $alfresco_db_$Days.sql.backup

    echo "=== Creating Aflresco Repository Backup ==="
    echo tar cjfv alfresco_repository_$Days.tar.bz2 $Alfresco_repository
    echo "=== Creating Alfresco Indexes Backup ==="
    echo tar cjfv alfresco_indexes_$Days.tar.bz2 $Alfresco_indexes
    echo "=== Restating Alfresco ==="
    echo $Alfresco_root/alfresco.sh start


ANY IDEAS?!

Outcomes