Uploaded image for project: 'Percona XtraBackup'
  1. Percona XtraBackup
  2. PXB-1936

--prepare cannot decrypt table but "completed ok"

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Done
    • Priority: Medium
    • Resolution: Fixed
    • Affects Version/s: 2.4.15
    • Fix Version/s: 2.4.16, 8.0.8
    • Component/s: None
    • Labels:
      None

      Description

      Using keyring_vault plugin and Vault is misconfigured or not accessible when doing --prepare, XtraBackup 2.4.15 reports it cannot decrypt tables but still finishes with "completed OK!" and exit code 0.

      How to repeat: Back up tables encrypted using keyring_vault, then execute xtrabackup -prepare without -keyring-vault-config= and without Vault configuration in my.cnf or backup-my.cnf. Same happens if Vault is offline, with a slightly different error message from XtraBackup.

       

      Log excerpt from xtrabackup --prepare:

       

      Plugin keyring_vault reported: 'File '' not found (Errcode: 2 - No such file or directory)'
      Plugin keyring_vault reported: 'Could not open file with credentials.'
      Plugin keyring_vault reported: 'keyring_vault initialization failure. Please check that the keyring_vault_config_file points to readable keyring_vault configuration file. Please also make sure Vault is running and accessible. The keyring_vault will stay unusable until correct configuration file gets provided.'
      InnoDB: Encryption can't find master key, please check the keyring plugin is loaded.
      InnoDB: Encryption information in datafile: ./test/sample1.ibd can't be decrypted.
      Shutting down plugin 'keyring_vault'
      191003 07:52:22 completed OK! 
      

      Trying to start MySQL with this backup leads to tables not being accessible.

      XtraBackup should exit with an error if it cannot decrypt tables.

       

        Smart Checklist

          Attachments

            Activity

              People

              Assignee:
              Unassigned
              Reporter:
              sami.ahlroos Sami Ahlroos
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - Not Specified
                  Not Specified
                  Logged:
                  Time Spent - 2 days, 5 hours, 8 minutes
                  2d 5h 8m