Quantcast
Channel: MySQL Forums - Backup
Viewing all 537 articles
Browse latest View live

MySQL Backup Failed (3 replies)

$
0
0
Hi,

MySQL Version: MySQL 5.6-22 for Windows

I have 2 Windows MySQL Servers setup the same way and one has no issues executing MySQl Scheduled backup from MySQL Administrator but the other one failed the scheduled backup job. Running interactive backup on both servers are fine.

Under MySQL Administration General Options “Store passwords” is selected with “Password storage method” as Obscured.

This is the error message I got from the MySQLAdminBackupLog.txt:

2016-06-02 01:00 - Backup started.
Preparing backup for for profile Full_VoipSw1_backup.
Connections loaded from file C:\Users\Administrator\AppData\Roaming\MySQL\mysqlx_user_connections.xml.
Connection Localhost selected.
Cannot connect to MySQL Server. Access denied for user 'root'@'localhost' (using password: NO) (Error Number 1045)

Can anyone able to assist me to resolving this schedule backup issue on the failed server?

Best practices Q: Should the backup/restore programs be version matched to the server version? (5 replies)

$
0
0
Greetings,

Our hosting provider recently added MySQL 5.5 database server to their prior MySQL 5.1 database server offerings.

I find that their backup/restore commands are only the MySQL 5.1 version commands.

> mysql --version
mysql Ver 14.14 Distrib 5.1.73, for debian-linux-gnu (i486) using readline 6.1

> mysqldump --version
mysqldump Ver 10.13 Distrib 5.1.73, for debian-linux-gnu (i486)


I am concerned that the LAMP stack web application may use capabilities of MySQL 5.5 that the MySQL 5.1 tools are not capable of backing up / restoring correctly / safely.

Please provide affirmation or debunk these concerns.

I am thankful,

avoid lock table during LVM snapshut (1 reply)

$
0
0
hi
during recover from snapshot back, way not to use recorded start-position in the error log "InnoDB: Last MySQL binlog file position 0 5585832, file name"

instead of lock the table during the backup .

db var : 5.7
db engin innodb
use sync-binlog=1

Query (4 replies)

$
0
0
Hi,

I have a query :

SELECT id, value1, value2 FROM table;

Now i want to add to the result a new column with TRUE if table.value3 is not null and FALSE if table.value3 is null.

Thx

Why the sqldump export smaller size of database than phpmyadmin (1 reply)

$
0
0
I compared the exported .sql file size from using mysqldump export command line with the one that I exported using phpMyadmin default export option, why the former one is smaller? Any idea? If possible, may I know the equivalent cmd line to the default exporting option in phpMyadmin

Here is the very basic cmd line I use

set path=c:\wamp\bin\mysql\mysql5.1.36\bin

mysqldump -u YourUser -p YourDatabaseName > wantedsqlfile.sql

how to NOT overwrite export sql file using mysqldump line (1 reply)

$
0
0
I currently configure a .bat file using mysqldump line to run auto backup, but it will always overwrite the existing .sql exported file.
What should I write in the .bat file to prevent this?

mysqldump: Got error: 1105: Stopped by user. when executing 'SELECT INTO OUTFILE’" (1 reply)

$
0
0
I'm trying to format the data and export the data it as a flat file to local file system using mysql dump. I'm getting mysqldump: Got error: 1105: Stopped by user. when executing 'SELECT INTO OUTFILE’".

This is on ext4 file system. I see this error when the file size hits around 4.4 GB. Any thoughts on what is causing it?

I’m using following option with mysqldump --tab= --fields-terminated-by=, --fields-enclosed-by='' --fields-escaped-by='\' --lock-tables=false --complete-insert --extended-insert=FALSE

hotbackup displaying many "switching to log file ##' during backup (1 reply)

$
0
0
I am running innodb hotbackup and I ran 2 consecutive backups for only one database which ran successfully. I am using the --include options and have file-per-table enabled. On the second backup, I noticed many many "ibbackup:: switching to log file ##" messages during the verbose output. The backup said it completed successfully.

What is the meaning of that message and why would there suddenly be many of those lines displaying please?

Will this cause problems if I needed to restore this database?

Thank you

Restore incremental image failed (MEB 4.0.3) (no replies)

$
0
0
Hello,
i test the image incremental restore, but i have always an error about LSN.

What i do :

1) Backup image "full" :
mysqlbackup --backup-dir=/data/mysqldump --backup-image=full.bki backup-to-image

ok :
-------------------------------------------------------------
Parameters Summary
-------------------------------------------------------------
Start LSN : 86263200768
End LSN : 86497355612
-------------------------------------------------------------


2) Backup image "incrémental" :
mysqlbackup --incremental --incremental-base=history:last_backup --backup-image=/var/lib/mysqldump/incr_7am.mbi --backup-dir=/var/lib/mysqldump/tmp backup-to-image

ok :
-------------------------------------------------------------
Parameters Summary
-------------------------------------------------------------
Start LSN : 86497355613
End LSN : 86519012050
-------------------------------------------------------------

3) Stop MySQL and remove files from datadir
systemctl stop mysqld
rm -rf /var/lib/mysql/


4) Restore Backup Full :

mysqlbackup --datadir=/var/lib/mysql --backup-image=/var/lib/mysqldump/full.bki --backup-dir=/var/lib/mysqldump copy-back-and-apply-log


ok :
160822 15:17:37 mysqlbackup: INFO: We were able to parse ibbackup_logfile up to
lsn 86497355612.
160822 15:17:37 mysqlbackup: INFO: The first data file is '/var/lib/mysql/ibdata1'
and the new created log files are at '/var/lib/mysql'
mysqlbackup: INFO: MySQL server version is '5.7.12'
mysqlbackup: INFO: Restoring ...5.7.12 version
160822 15:17:37 mysqlbackup: INFO: Apply-log operation completed successfully.
160822 15:17:37 mysqlbackup: INFO: Full Backup has been restored successfully.

mysqlbackup completed OK! with 2 warnings


5) Restore Backup incremental :
mysqlbackup --datadir=/var/lib/mysql --backup-image=/var/lib/mysqldump/incr_7am.mbi --backup_dir=/var/lib/mysqldump/ --incremental copy-back-and-apply-log


==> ERROR :
160822 15:18:49 mysqlbackup: INFO: ibbackup_logfile's creation parameters:
start lsn 86263200768, end lsn 86497355612,
start checkpoint 86263200945.
mysqlbackup: INFO: InnoDB: Doing recovery: scanned up to log sequence number 86263200768.
mysqlbackup: INFO: InnoDB: Starting an apply batch of log records to the database...
.
InnoDB: Progress in percent: 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99
mysqlbackup: INFO: InnoDB: Setting log file size to 2147483648.
mysqlbackup: INFO: InnoDB: Progress in MB:.
100 200 300 400 500 600 700 800 900 1000 1100 1200 1300 1400 1500 1600 1700 1800 1900 2000
mysqlbackup: INFO: InnoDB: Setting log file size to 2147483648.
mysqlbackup: INFO: InnoDB: Progress in MB:.
100 200 300 400 500 600 700 800 900 1000 1100 1200 1300 1400 1500 1600 1700 1800 1900 2000
mysqlbackup: ERROR: We were only able to scan ibbackup_logfile up to
lsn 86263200768, but the log file end is at lsn 86497355612!
The backup prepared for recovery may be corrupt!


Thank you for your help
Thierry

Problem Backup with Automatic Password - mysqldump (2 replies)

$
0
0
Group

See who could help me in doubt below:

a) What could be going on in my routine mysql back up, because when I leave the password blank it asks for a password and it works without any problems.

c:\progra~1\mysql\mysqls~1.1\bin\mysqldump.exe -h 127.0.0.1 -u root -p --hex-blob --databases projeto > c:\bak_sis\backup\projeto.sql

b) But when I put the password, it does not work, giving the following message below.

c:\progra~1\mysql\mysqls~1.1\bin\mysqldump.exe -h 127.0.0.1 -u root -pgf%nm$kj@2 --hex-blob --databases projeto > c:\bak_sis\backup\projeto.sql


Usage: mysqldump [OPTIONS] database [tables]
OR mysqldump [OPTIONS] --databases [OPTIONS] DB1 [DB2 DB3 ...]
OR mysqldump [OPTIONS] --all-databases [OPTIONS]
For more options, use mysqldump --help

mysqlbackup preparing the backup for restore fails (no replies)

$
0
0
Hello,

I'm folloing the instructions from the "MySQL Enterprise Backup 3.12 User's Guide - Chapter 6 Using MySQL Enterprise Backup with Replication"

I'm able to take the successful backup from master & copied it over to the slave. On slave when i'm trying to prepare the backup for restore using apply-log option I'm getting an error as listed below,



[root@mysqlslave x]# mysqlbackup --backup-dir=/usr/x/mysql_backup/ apply-log
MySQL Enterprise Backup version 4.0.3 Linux-3.8.13-118.4.2.el7uek.x86_64-x86_64 [2016/08/04]
Copyright (c) 2003, 2016, Oracle and/or its affiliates. All Rights Reserved.

mysqlbackup: INFO: Starting with following command line ...
mysqlbackup --backup-dir=/usr/xmysql_backup/ apply-log

mysqlbackup: INFO:
IMPORTANT: Please check that mysqlbackup run completes successfully.
At the end of a successful 'apply-log' run mysqlbackup
prints "mysqlbackup completed OK!".

mysqlbackup: [Warning] World-writable config file '/usr/x/mysql_backup/backup-my.cnf' is ignored.
160908 13:52:02 mysqlbackup: INFO: MEB logfile created at /usr/x/mysql_backup/meta/MEB_2016-09-08.13-52-02_apply_log.log

mysqlbackup: ERROR: Mandatory parameter innodb_data_file_path is missing in
backup-my.cnf config file: /usr/x/mysql_backup/backup-my.cnf
mysqlbackup: ERROR: Could not load contents of directory '/usr/x/mysql_backup/'.

mysqlbackup failed with errors!


Could someone guide me if i'm missing anything here...

Thank you.

backup database Event (no replies)

$
0
0
Hola a Todos estoy tratando de crear un evento que respalde la base de datos, de hecho lo he creado, no tiene errores sin embargo no da resultados, este es el codigo:


DELIMITER $$

CREATE DEFINER=`paccds`@`%` EVENT `respaldoinfo` ON SCHEDULE EVERY 1 DAY STARTS '2016-10-14 08:13:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE done INT DEFAULT 0;
DECLARE ruta VARCHAR(250);
DECLARE nombretabla VARCHAR(250);
DECLARE cursor1 CURSOR FOR SELECT table_name FROM information_schema.tables WHERE table_schema='empresax' AND TABLE_TYPE ='BASE TABLE';
DECLARE CONTINUE HANDLER FOR NOT FOUND SET done = 1;
OPEN cursor1;
read_loop: LOOP
FETCH cursor1 INTO nombretabla;

IF done THEN
LEAVE read_loop;
END IF;


SET @ruta = CONCAT('c:/conta/respaldos/',nombretabla,'.bkp');


SET @cadenaSql = CONCAT("SELECT * FROM ", nombretabla, " INTO OUTFILE ", @ruta, " FIELDS TERMINATED BY '|' ENCLOSED BY ';' LINES TERMINATED BY '\r\n'");
PREPARE s1 FROM @cadenaSql;
EXECUTE s1;
DEALLOCATE PREPARE s1;

END LOOP;
CLOSE cursor1;

END$$

DELIMITER ;

Purging MySQL Backups (no replies)

$
0
0
I am looking for a way to purge mysql backups every 2 weeks. I am using mysql enterprise backup in a windows environment (windows server 2012 r2)..

ERROR 1146 (42S02) During Database restore. Ver: 5.1.54-community (no replies)

$
0
0
I have a MYSQL server with multiple databases, I use a batch file + task scheduler to back up my databases on daily basis. During restore of one of the database using Mysql Workbench on a new server with same MYSQL server version (5.1.54-community) I encountered ERROR 1146 (42S02) at line 18819: Table 'DB2.rhicd5_hic_desc' doesn't exist
This is wired as DB2 is not the database I was restoring. Somehow DB1 (database being restored) has reference to 'DB2.rhicd5_hic_desc' (a view from second database on my old server).
Command to backup database:
C:\Program Files\MySQL\MySQL Server 5.1\bin\mysqldump.exe" --user=%dbuser% --password=%dbpass% --databases %db% > "%db%.%backupdate%.sql"

Someone please help me understand why this is happening and how can I do a clean backup.

Server 1 OS : windows 2012
MYSQL ver : 5.1.54-community
Server 2 OS : windows 2012
MYSQL ver : 5.1.54-community

backup history (1 reply)

$
0
0
Hello,

I am using mysql 5.7.14 - MySQL Community Server (GPL). How can I get a backup history of backups done for databases on this server?

Backup data error? (1 reply)

$
0
0
I have problems when backing up data, what should I do?

Cross platform backup and restore (no replies)

$
0
0
Hi all,

We are running MySQL 5.5 on Solaris 10 and are looking to migrate to CentOS. I am looking whether we can run mysqldump from Solaris and restore the backup file to Linux (on the same version 5.5) Whether there will be a problem during the restore. If not, what would be the best way to do such a migration.

thank you

benny

Not able to create log-bin file (no replies)

$
0
0
i tried to create log-bin with the following code in my.ini

[mysqld]
log-bin=mysql-bin.0000143
binlog-do-db=new11

but it is not creating mysql-bin.0000143, do guide me on this to achieve the incremental backup..

from MySQLDUMP File Remove USE (no replies)

$
0
0
I am trying to take records from multiple databases and storing into single database, for that i am taking backup using mysqldump like this ..

mysqldump.exe --user=root --password=root --no-create-db --no-create-info --databases shipdb1 shipdb2 > "D:\dump\six.sql"

then restore.. but in the six.sql(dump file) i am getting USE databasename statement. i got the solution like remove --databases it works fine for single db backup, in multiple db backup it shows "mysqldump: Couldn't find table: "shipdb2"

Please help me in this to resolve this error or any other way to take records from multiple databases and storing into single database.

Thanks in advance

MySQL dump truncating backups at ~18GB - RT database (no replies)

$
0
0
I'm having a big problem with my MySQL 5.7.15 server running on Windows Server 2012. We use BestPractical's RT for tickets. The specific install I'm having a problem with has a database of about 20GB worth of data. Sometime between December 18th and January 9th, my mysqldump backups started to get truncated. The problem is coming from the file attachment table in the database which is about 19GB. I can't find anything in any logs or anywhere else and I'm running out of ideas. What would cause the dump to just "stop"? How can I debug this?

I did just download the 5.1.17 install, so I will perform the updated this week in hopes that it will help. Thank you.
Viewing all 537 articles
Browse latest View live