Sqlite3 db is locked

I'm on Ubuntu10. Create a new db file with

touch development.db

Want my migrations

rake db:migrate

but get a blocked error

SQLite3::BusyException: database is locked

How can this be blocked ?!


update it may be blocked by samba. this is a shared folder

+3
source share
3 answers

I ran into this problem myself. I found that the only way to avoid the lock placed in such a file is to add an option nobrlto your mount. Your entry /etc/fstabmight look something like this:

//<SERVERNAME>/<REMOTEPATH> /<LOCALMOUNTPOINT>/<LOCALPATH> cifs credentials=/home/<LOCALUSERNAME>/.smbcredentials,iocharset=utf8,uid=1000,gid=1000,file_mode=0775,dir_mode=0775,nobrl 0 0

This happens on the following wubuntu wiki page: https://wiki.ubuntu.com/MountWindowsSharesPermanently

+3

rake db:create touch. . , ?

+1

I think it was blocked by samba .

I put development.db in another folder without sharing, and everything works as expected

+1
source

Source: https://habr.com/ru/post/1772399/


All Articles