Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
en:use_case:how_to_perform_system_backup [2015/03/16 01:55]
solo created
en:use_case:how_to_perform_system_backup [2017/12/12 03:05] (current)
Line 1: Line 1:
 ====== How to perform asterCC system backup ====== ====== How to perform asterCC system backup ======
 +<note tip>You need to ssh to your server for the following operation</​note>​
 ===== Database Backup ===== ===== Database Backup =====
 <​code>​ <​code>​
 mysqldump -uroot -p astercc10 | gzip > astercc_db.sql.gz mysqldump -uroot -p astercc10 | gzip > astercc_db.sql.gz
 </​code>​ </​code>​
-System will prompt for database root password, you can find it in /​etc/​astercc.conf if you don't know+System will prompt for database root password, you can find it in /​etc/​astercc.conf if you don't know
 +<note warning>​Note:​If you see "​mysqldump:​ Got error: 2002: Can't connect to local MySQL server through socket '/​var/​run/​mysqld/​mysqld.sock'​ (2) when trying to connect"​,you should use <​code>​ mysqldump -h127.0.0.1 -uroot -p astercc10 | gzip > astercc_db.sql.gz </​code>​ </​note>​
 ===== File Backup ===== ===== File Backup =====
 +<​code>​
 +sudo tar czfP astercc_files.tar.gz /​etc/​asterisk /​etc/​astercc.conf /​opt/​asterisk/​scripts/​astercc /​var/​lib/​asterisk /​var/​spool/​asterisk /​var/​www/​html  ​
 +</​code>​
 +===== Download Backup files=====
 +Now you have two files astercc_db.sql.gzip and astercc_files.tar.gz,​ you can download via ftp/sftp tools, or move the file to http folder so you can download from browser
 +<​code>​
 +sudo mv astercc_files.tar.gz astercc_db.sql.gzip /​var/​www/​html/​asterCC/​app/​webroot/ ​
 +</​code>​
 +Then you can download by visiting
 +
 + ​http://​your ip/​astercc_files.tar.gz
 +
 +and
 +
 + ​http://​your ip/​astercc_db.sql.gzip
 +
 +<note tip>If you use CentOS,you can download by "wget http://your ip/​astercc_files.tar.gz" ​ and  "wget http://your ip/​astercc_db.sql.gzip"​ </​note>​
en/use_case/how_to_perform_system_backup.1426470954.txt.gz · Last modified: 2017/12/12 03:11 (external edit)
Recent changes RSS feed Debian Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki