Page 1 of 1

Mysql Database copy error

PostPosted: Mon Aug 29, 2011 12:31 pm
by chasejordan1
I am trying to copy Mysql database backup using Winscp and am getting this error while trying to copy. Side note never had this problem before. And maybe there is a way to FTP the backup, since I do have ftp set up for the recordings.

SERVER UNEXPECTEDLY CLOSED NETWORK CONNECTION

Copying file 'backupfile.sql.gz' fatally failed.
Copying files from remote side failed.

I have rebooted the server several times and no joy, any suggestions???






Goautodial
VERSION: 2.2.1-237
BUILD: 100510-2015
asterisk version
1.4.27

ftp backup

PostPosted: Mon Aug 29, 2011 12:54 pm
by striker
/usr/share/astguiclient/ADMIN_backup.pl --ftp-transfer

change the ftp ip and login detials in the /etc/astguiclient.conf
under

# REPORT server connection information
VARREPORT_host => 10.0.0.4
VARREPORT_user => cron
VARREPORT_pass => test
VARREPORT_port => 21
VARREPORT_dir => REPORTS

PostPosted: Mon Aug 29, 2011 1:44 pm
by chasejordan1
Thank You, but where do the reports go, meaning when I backup mysql it goes in root which is where anaconda-ks.cfg is stored along with install.log and install.log.syslog.

PostPosted: Mon Aug 29, 2011 7:20 pm
by williamconley
if you did not create the backup with ADMIN_backup.pl ... how did you create it? It is possible that you put it in a location too small to hold it. (and then no wonder it doesn't completely transfer if it isn't all there)

try
Code: Select all
/usr/share/astguiclient/ADMIN_backup.pl --help
which will write data to /var/log/astguiclient/archive or
Code: Select all
mysqldump asterisk > /var/log/astguiclient/2011-08-29_1234_asterisk.sql -p
the -p is only necessary if you have a root mysql password.

you can also use the described ftp method, but that will send to an ftp server (which obviously requires you to have an ftp server to send to!)

PostPosted: Tue Aug 30, 2011 4:30 pm
by chasejordan1
I log in as root via putty and type this

mysqldump -u root -pvicidialnow asterisk | gzip -9 > 08_29.sql.gz

this is how I save the data then I use Winscp and copy it to local pc.

I do have ftp server that the recordings go to. As a work around I moved the sql backup to /var/spool/asterisk/monitorDONE/GSM and then 3 minutes later it was sent to my ftp server.

Thank You.

PostPosted: Tue Aug 30, 2011 9:09 pm
by williamconley
right ... but when you do that, where are you in the file structure? if you are in the wrong location ... well, try this:

Code: Select all
df -h
this will show you drive usage of all drives. be sure you aren't placing the zip file in a location that is smaller than it is.

also: if it is failing the way you are doing it ... why not try the stock method, just for fun? 8-) (if it makes a file you CAN download, you can work out why yours didn't work later ...)