Full and Incremental backups to Remote Host

  • Filter
  • Time
  • Show
Clear All
new posts

  • Full and Incremental backups to Remote Host


    I am currently using innobackupex and the --remote-host to send the backup data to a remote host. But how do I do an incremental backup with the data remote as the incremental backup requires a basedir to start. Is there someway to tell it that the basedir is on a remote host as well?


  • #2
    I saw this in another posting....

    "You can read to_lsn from xtrabackup_checkpoints and use its value as an argument to --incremental-lsn as described here: http://www.percona.com/doc/percona-xtrabackup/innobackupex/i ncremental_backups_innobackupex.html

    Which is easier than recreating the directory structure and copying the entire file."

    However this still results in a full backup to the remote host?

    #innobackupex --user=xtrabkp --password=***** --no-timestamp --remote-host=remotehost /MysqlBackup/current/base

    Incr - when the lsn is derived from the to_lsn in the xtrabackup_checkpoints file in the base dir.
    #innobackupex --user=xtrabkp --password=***** --remote-host=remotehost --incremental --incremental-lsn=226576624494 /MysqlBackup/current/


    • #3
      sorry forgot to put the version xtrabackup 1.6.3-292.lenny


      • #4
        Same problem here.

        Is it even possible to use --remote-host together with --incremental?
        Can't get it to work.


        • #5
          Has anyone figured this out? Seems like if a documented option isn't working then it's a bug or the documentation needs updating.

          I've been able to perform a full backup followed by an incremental when creating a local backup on the MySQL server. To create the incremental backup I used the following.

          xtrabackup --backup --incremental-lsn=8319504 --target-dir=/path/to/backupdir/incr

          I've noticed that if using innobackupex command to create a local backup copy it puts the start lsn#:final lsn#. For instance If doing a full backup it would show 0:8319504 if starting at 0 and going to 8319504. I'm not even able to point xtrabackup or innobackupex at this xtrabackup_checkpoints file to perform an incremental backup. If I use xtrabackup it excludes the 0: or start lsn#":" from from the file.

          File created by xtrabackup
          backup_type = incremental
          from_lsn = 8319504
          to_lsn = 8319504
          last_lsn = 8319504

          File created by innobackupex.
          backup_type = incremental
          from_lsn = 0:8319504
          to_lsn = 0:8319504
          last_lsn = 0:8319504

          The innobackupex command I've tried to use is as follows.

          innobackupex --incremental --incremental-lsn=8319504 --stream=tar /path/to/tmpdir > somefile.tar

          Which produces the above xtrabackup_checkpoint file and a full backup. If anyone has gotten this to work with innobackupex or knows how to do similar type command using xtrabackup sending the data to stdout, please do share.


          • #6
            It seems like this is not possible using the --stream=tar option and if the databases are myisam.

            http://www.percona.com/doc/percona-xtrabackup/innobackupex/i ncremental_backups_innobackupex.html


            This procedure only affects XtraDB or InnoDB-based tables. Other tables with a different storage engine, e.g. MyISAM, will be copied entirely each time an incremental backup is performed.

            So I guess for me incremental backups of my databases are not going to be possible. Also I've been told by Percona that there is a new bug in creating incremental backups using the --stream=tar option. This is documented to be fixed in the 1.9.1 (2.0 Beta) but it also doesn't work for me. Might be due to Warning above. Documented features/fixes in 1.9.1.

            http://www.percona.com/doc/percona-xtrabackup/release-notes/ 2.0/1.9.1.html