[MapProxy] FYI: Possible root cause of 'sqlite3.OperationalError: database is locked'
Just van den Broecke
just at justobjects.nl
Sun Mar 15 09:07:24 PDT 2015
Hi,
I confirm this behaviour for MapProxy 1.7.1 on Ubuntu (with UbuntuGIS
unstable PPA) using the standard Ubuntu package for sqlite3:
- on Ubuntu 13.10 with "sqlite3 amd64 3.7.17-1ubuntu1", the
'sqlite3.OperationalError: database is locked'-error appeared.
- after upgrading to Ubuntu 14.04.2 with "sqlite3 amd64 3.8.2-1ubuntu2",
the error no longer occurred.
Though the issue itself seems not to be version-dependent, but on the
compiler-directive HAVE_USLEEP (which must be 1). So that flag may have
been set for Ubuntu 14.04, which is as a better choice (LTS) anyway.
Maybe of use for reproducing via e.g. Vagrant.
best,
Just
On 10-01-15 18:36, Oliver Tonnhofer wrote:
> Hi,
>
> a few users reported 'sqlite3.OperationalError: database is locked’ during seeding or moderate load when using SQLite or MBTiles backends. I could never reproduce and debug this on my systems, but I think that I found the root cause.
>
> On some systems SQLite is not compiled with USLEEP support. Without USLEEP, SQLite will sleep a whole second every time another thread/process is reading or writing to the same SQLite database.
>
> Here is a detailed description of the issue: http://beets.radbox.org/blog/sqlite-nightmare.html
>
> You should try to upgrade your system or the SQLite version used by Python if you see these lock errors.
>
>
> Regards,
> Oliver
>
More information about the MapProxy
mailing list