I'm trying to program an application to tag directories on my nas server, since I wanted to be able to access to it from windows/linux and multiple pcs it seemed logical to just have a SQLite database file inside the folder.
Apparently the database gets locked and I can't use it, AFAIK this is to prevent multiple processes from using the data at the same time, but I'm not planning on accessing it from more than 1 process at the same time. Can I disable all locking and concurrency so that the database works correctly on an NFS server?
The strace from a create command gives me this:
nanosleep({0, 15000000}, NULL) = 0
fcntl(3, F_SETLK, {type=F_RDLCK, whence=SEEK_SET, start=1073741824, len=1}) = -1 ENOLCK (No locks available)
Is SQLite not right for this usecase? The database being located on the NFS server is a must. I'm using the python bindings, do I have to write to a local database and keep the other file synced or some workaround like that?
Aucun commentaire:
Enregistrer un commentaire