Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is sqlite locked during .backup

While a backup of a sqlite db is going on (via the .backup command), is the sqlite db locked to prevent writes?

This answer seems to suggest that the db is not locked.

sqlite3 shell command '.backup' and transaction

However, I could not find a definite source in the documentation.

like image 591
james Avatar asked Dec 17 '25 17:12

james


1 Answers

According to the documentation a shared (read-only) lock is acquired.

http://www.sqlite.org/backup.html

like image 68
TheDude Avatar answered Dec 19 '25 23:12

TheDude