How to backup sqlite database?
What's the proper way to do it? Do I just copy the .sq3 file? What if there are users on the site and file is being written while it's being copied? Googie The sqlite3 command line tool features the .backup dot command . You can connect to your database with: sqlite3 my_database.sq3 and run the backup dot command with: .backup backup_file.sq3 Instead of the interactive connection to the database, you can also do the backup and close the connection afterwards with sqlite3 my_database.sq3 ".backup 'backup_file.sq3'" Either way the result is a copy named backup_file.sq3 of the database my