Mercurial > backup
comparison backup-6.034.sh @ 22:d3b029607539
resurrected old backup script from 6.034.
author | Robert McIntyre <rlm@mit.edu> |
---|---|
date | Mon, 10 Jun 2013 08:48:20 -0400 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
21:20bdc7c84c64 | 22:d3b029607539 |
---|---|
1 #!/bin/sh | |
2 | |
3 TARGET_DIR=`date +%Y.%m.%d-%H.%M` | |
4 | |
5 mkdir /home/r/proj/6.034/archive/$TARGET_DIR | |
6 | |
7 cd /home/r/proj/6.034/archive/$TARGET_DIR | |
8 | |
9 | |
10 python2 /home/r/bin/gcp.py -f csv -p 68686960606- bortreb@gmail.com:/all/all/6.034* . | |
11 python2 /home/r/bin/gcp.py -p 68686960606- bortreb@gmail.com:/all/all/6.034* . | |
12 | |
13 echo "Backup tester DB" | |
14 | |
15 mysqldump -h sql.mit.edu -ptU45~br8nz -u \ | |
16 6.034 6034+fall12_tester > ./6.034-tester.sql | |
17 | |
18 echo "Backup wiki DB" | |
19 | |
20 mysqldump -h sql.mit.edu -ptU45~br8nz -u \ | |
21 6.034 6034+fall12_wiki > ./6.034-wiki.sql | |
22 | |
23 echo "Backup all-databases" | |
24 | |
25 mysqldump -h sql.mit.edu -ptU45~br8nz -u \ | |
26 6.034 --all-databases > ./6.034-all-databases.sql | |
27 | |
28 du -shc ./* | |
29 |