Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PXB-3320 : prepare_handle_del_files() fails to delete the .meta and .… #1584

Merged

Commits on Jul 15, 2024

  1. PXB-3320 : prepare_handle_del_files() fails to delete the .meta and .…

    …delta files for deleted tablespaces in incremental backup directory
    
    Problem:
    --------
        1. take full backup with --lock-ddl=reduced
    
        2. create table t1(a INT), lets say space_id 10
    
        3. start incremental backup and pause before backup_start() function (we take Bakcup lock here)
    
        4. incremental backup copied t1.ibd.meta and t1.ibd.delta by this time
    
        5. DROP TABLE t1
    
        6. resume the incremental backup. 10.del file is created
    
        7. prepare the full backup with --apply-log-only
    
        8. prepare incremental backup
    
        incremental backup prepare first processes the .del files. before this all tabelspaces are loaded via .ibd scan
    
        since there is no t1.ibd in backup directory( it is only present as meta and delta file) in incremental backup directory, space_id with 10 is not in cache.
    
        Hence prepare_handle_del_files() will not delete the files related to space_id 10.
        We end up with orphan .ibd or .ibu files. Server ignore orphan .ibd
        But if the tablespace is undo tablespace, orphan .ibu are not ignored by server.
        Server discovers them via *.ibu scan. This can lead to assertion failures.
    satya-bodapati committed Jul 15, 2024
    Configuration menu
    Copy the full SHA
    a8eb932 View commit details
    Browse the repository at this point in the history