The command below will create a version-agnostic backup of the database, to a file badger.bak in the current working directory

    See for more details.

    We recommend all users to use the Backup and APIs and tools. However, Badger is also rsync-friendly because all files are immutable, barring the latest value log which is append-only. So, rsync can be used as rudimentary way to perform a backup. In the following script, we repeat rsync to ensure that the LSM tree remains consistent with the MANIFEST file while doing a full backup.