On Thu, Jul 8, 2010 at 10:31 AM, Eric Smith <eas....@gmail.com> wrote:

> I'm forced into a situation where I have to use an nfs server that I
> think is buggy.
>

Try using:

    sqlite3 db ./foo -vfs unix-dotfile

That uses an alternative VFS that uses dot-file locking instead of posix
advisory locks.  The dot-file locks are someone slower and have less
concurrency, so the use of "PRAGMA locking_mode=EXCLUSIVE" might also be a
good idea in such a configuration.



>
> I can read/write files normally using fopen() on the exported
> filesystem, but can't do anything useful with sqlite 3.6.23.1:
>
> -bash-2.05b$ tclsh
> % package require sqlite
> 3.6.23
> % sqlite3 db ./foo
> % db eval {pragma synchronous=off}
> disk I/O error
> % puts $::errorInfo
> disk I/O error
>    while executing
> "db eval {pragma synchronous=off}"
> % db eval {create table t(a)}
> disk I/O error
> % ^C
> -bash-2.05b$ lh
> total 0
> -rw-r--r--  1 esmith  1005     0B Jul  8 10:19 foo
> -bash-2.05b$ echo foobar > foo
> -bash-2.05b$ lh
> total 2
> -rw-r--r--  1 esmith  1005     7B Jul  8 10:23 foo
> -bash-2.05b$ tclsh
> % package require sqlite
> 3.6.23
> %
> % file delete -force foo
> % sqlite3 db ./foo
> % db eval {pragma locking_mode=exclusive}
> exclusive
> % db eval {pragma synchronous=off}
> disk I/O error
>
> Everything works fine when I use a database on the local disk:
>
> % db close
> % sqlite3 db /tmp/foo
> % db eval {pragma synchronous=off}
> % db eval {create table t(a)}
> % db eval {insert into t values('blah')}
> % db eval {select count(*) from t}
> 1
> %
>
> -bash-2.05b$ uname -a
> FreeBSD xxxx 5.40.0000 FreeBSD 5.40.0000 #0: Fri Sep 19 03:14:59 EDT 2008
>  i386
>
> Can anyone offer any hints?
>
> Thanks!
> Eric
>
> --
> Eric A. Smith
>
> Furbling, v.:
>    Having to wander through a maze of ropes at an airport or
>    bank even when you are the only person in line.
>        -- Rich Hall, "Sniglets"
> _______________________________________________
> sqlite-users mailing list
> sqlite-users@sqlite.org
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>



-- 
---------------------
D. Richard Hipp
d...@sqlite.org
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to