I am using the C/C++ interface to SQLite version 3.6.17 in a Linux
environment.

I am using SQLite as part of a CGI program on a clustered group of
webservers which do searches on the database.  Some of these searches
can happen at the same time as multiple instances of the CGI program can
execute either on the one server or many servers within the cluster.
But they all use the one SQLite data file, accessed via NFS.

However, the database is being used as a strictly read-only source as
it is generated off-site and then manually uploaded to the webserver
when required.  Additionally, "select" is the only command issued to
the database when the searching CGI programs execute, and I have used
sqlite3_open_v2() with the SQLITE_OPEN_READONLY flag to further
reinforce that.  So SQLite on the webserver is not doing any writing
operations at all.

Given all this, why am I on rare occasions getting a SQLITE_BUSY
return code when calling sqlite3_prepare_v2() or sqlite3_step() ?
Despite multiple CGI programs possibly querying the database at once,
surely no locks would be set given I'm only issuing "select" commands and
opening the database with the SQLITE_OPEN_READONLY flag set?

On the clustered webserver, the database file sits on an NFS filesystem,
but given that none of the CGI programs want to modify the database,
I assume any issues with broken NFS locking shouldn't be relevant.
_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to