On Fri, Nov 5, 2010 at 3:25 AM, Serena Lien <[email protected]> wrote:
>
> I would like to inform the group that I managed to resolve the issue with a
> workaround. I am not sure if this is a bug in vista or whether there might
> in fact be some slight issue with sqlite...
>
> The problem seems to be hardware and software related, and occurs for me
> when my application is running on Windows Vista and is opening a database on
> a networked drive (running Windows Small Business Server 2008) with the
> read-only flag. Running sql queries on the database after this will
> return SQLITE_BUSY when  no one is using the database. Once the application
> is closed and restarted the error does not re-occur. This is highly
> reproducible once per day (in the morning after the machine has powered down
> the screen only, it doesn't go to sleep).

Given that sequence / timing, I *suspect* this is actually caused by
the network connection 'timing out'.  Your application thinks it has
the database file open, but SBS has _decided_ that the connection is
stale, and closed it.  I do not know why your symptoms would only show
up for read only connections.  You might be able to continue after the
error, by having the application close and reopen / reconnect to the
database file.  You might get an error doing a normal close as well,
because SBS thinks it is already closed.

When your Vista system powers down the screen, it may *also* be
powering down the [wired or wireless] network card, which could
trigger SBS to close the read only connection.

> Removing that flag and making sure I only open databases in read-write mode
> has resolved the problem. I have tested this thoroughly over a period of
> many days.
>
> As I said I'm not sure if this is an sqlite bug or not (and I'm sure very
> difficult to reproduce) but I'm writing this in case anyone else has the
> same problem in the hope it helps them.
>
> cheers Serena
--
Phil
_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to