Skip to content

Vacuuming the node backup #2879

@shawn-zil

Description

@shawn-zil

When a backup of a full node is taken, it ZIPs up the contents of the data directory as-is. There is an opportunity to use VACUUM, which is an opportunity to clean up and defragment the database.

The cons is that it will require more disk-space i.e. the free-space must be able to hold the entire defragmented database; and that it will take more time - factoring in the vacuuming.

The pros is that any node restored from this backup will have a, slightly smaller and more efficient database, clean of cruft.

An alternative argument could be made to vacuum at restore, rather than at backup. That depends on our use case for backup/restore operations e.g. disaster recovery, preventive maintenance, etc.


I will do a quick test with prototestnet data to see if it is worth the trouble.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions