Re: [sqlite] WAL mode readonly errors to SELECT statements

2019-01-24 Thread Peter da Silva
The sensible permissions in this case would probably be rw-rw-r-- with the same group as the service and owned by the service group. That is how group permissions were designed to work. > > ___ sqlite-users mailing list

Re: [sqlite] WAL mode readonly errors to SELECT statements

2019-01-24 Thread Robert Searle
Thanks for the hint about pragma QUERY_ONLY, that might work but we will have to rethink the database file management. The database is currently owned by root and has sensible unix permissions of rw, r, r (ie only root has write permission) We can't run the intended service as root because that

Re: [sqlite] WAL mode readonly errors to SELECT statements

2019-01-23 Thread Simon Slavin
On 24 Jan 2019, at 2:37am, Robert Searle wrote: > occasionally get either > SQLITE_READONLY_RECOVERY or SQLITE_READONLY_CANTINIT responses to select > statements No programmer should be seeing these. They indicate low-level errors that cannot be handled in a systematic manner. Rather than

Re: [sqlite] WAL mode readonly errors to SELECT statements

2019-01-23 Thread Clemens Ladisch
Robert Searle wrote: > We have recently started trying to provide read-only access to the database > (service run as user with group/other read access permissions under Linux, > service not database owner) and occasionally get either > SQLITE_READONLY_RECOVERY or SQLITE_READONLY_CANTINIT responses

[sqlite] WAL mode readonly errors to SELECT statements

2019-01-23 Thread Robert Searle
Hi, I have an sqlite3 database (version 3.25.3) in tmpfs which has many readers and writers. The database is running in WAL mode and seems to work efficiently in that mode. Since the database files are in a memory based file-system, we don't care about the usual corruption on power-cycle issues