database is locked error with 3.3.13

classic Classic list List threaded Threaded
13 messages Options
Reply | Threaded
Open this post in threaded view
|

database is locked error with 3.3.13

BareFeetWare
Hi all,

I recently installed SQLite 3.3.13, after having used previous  
versions. I now get an error:

Error: database is locked

when I use the sqlite3 command line tool to access a database on a  
shared volume.

But opening the same file with an earlier version works fine.

I'm not sure what version introduced this problem. I suspect it's  
after 3.3.9. It's definitely after 3.1.3.

I'm using Mac OS X 10.4.8, with the database file on an AppleShare  
mounted volume.

What's the issue here? Is it a known bug? Will it be fixed?

Thanks,
Tom


-----------------------------------------------------------------------------
To unsubscribe, send email to [hidden email]
-----------------------------------------------------------------------------

Reply | Threaded
Open this post in threaded view
|

Re: database is locked error with 3.3.13

BareFeetWare
Hi all,

Following up:

> I recently installed SQLite 3.3.13, after having used previous  
> versions. I now get an error:
>
> Error: database is locked
>
> when I use the sqlite3 command line tool to access a database on a  
> shared volume.
>
> But opening the same file with an earlier version works fine.
>
> I'm not sure what version introduced this problem. I suspect it's  
> after 3.3.9. It's definitely after 3.1.3.
>
> I'm using Mac OS X 10.4.8, with the database file on an AppleShare  
> mounted volume.

I tried using sqlite 3.3.10 (which I had on another machine) and  
still have the problem. I looked for 3.3.9 to re-install it, to try  
that version, but couldn't find it on the sqlite.org web site.

Have others experienced a locking error on remote volumes?

Where can I get 3.3.9 and earlier source code?

Thanks,
Tom


-----------------------------------------------------------------------------
To unsubscribe, send email to [hidden email]
-----------------------------------------------------------------------------

Reply | Threaded
Open this post in threaded view
|

Re: database is locked error with 3.3.13

Wiktor Adamski
In reply to this post by BareFeetWare

> Where can I get 3.3.9 and earlier source code?

http://www.sqlite.org/sqlite-source-3_3_0.zip
...
http://www.sqlite.org/sqlite-source-3_3_9.zip

But it would be nice to have direct link on the website, or even better to
have tags for all releases in CVS.

---------------------------------------------------------------------------------------------
Aparat cyfrowy, odtwarzacz mp3 i inne nagrody. Sprawd¼ nowy konkurs na TeleInteria!>> http://link.interia.pl/f1a2d


-----------------------------------------------------------------------------
To unsubscribe, send email to [hidden email]
-----------------------------------------------------------------------------

Reply | Threaded
Open this post in threaded view
|

Re: database is locked error with 3.3.13

ken-33
In reply to this post by BareFeetWare
I have the following sources which one would you like?
 
 sqlite-2.8.16.tag.gz  sqlite-3.3.8.tar.gz
 sqlite-3.2.2.tar.gz   sqlite-3.3.9.tar.gz
 sqlite-3.2.8.tar.gz
 sqlite-3.3.10.tar.gz
 sqlite-3.3.12.tar.gz
 sqlite-3.3.13.tar.gz
 sqlite-3.3.5.tar.gz  
 sqlite-3.3.7.tar.gz
 
 Ken
 

T&B <[hidden email]> wrote: Hi all,

Following up:

> I recently installed SQLite 3.3.13, after having used previous  
> versions. I now get an error:
>
> Error: database is locked
>
> when I use the sqlite3 command line tool to access a database on a  
> shared volume.
>
> But opening the same file with an earlier version works fine.
>
> I'm not sure what version introduced this problem. I suspect it's  
> after 3.3.9. It's definitely after 3.1.3.
>
> I'm using Mac OS X 10.4.8, with the database file on an AppleShare  
> mounted volume.

I tried using sqlite 3.3.10 (which I had on another machine) and  
still have the problem. I looked for 3.3.9 to re-install it, to try  
that version, but couldn't find it on the sqlite.org web site.

Have others experienced a locking error on remote volumes?

Where can I get 3.3.9 and earlier source code?

Thanks,
Tom


-----------------------------------------------------------------------------
To unsubscribe, send email to [hidden email]
-----------------------------------------------------------------------------


Reply | Threaded
Open this post in threaded view
|

Re: database is locked error with 3.3.13

D. Richard Hipp
In reply to this post by BareFeetWare
T&B <[hidden email]> wrote:

>
> I recently installed SQLite 3.3.13, after having used previous  
> versions. I now get an error:
>
> Error: database is locked
>
> when I use the sqlite3 command line tool to access a database on a  
> shared volume.
>
> But opening the same file with an earlier version works fine.
>
> I'm not sure what version introduced this problem. I suspect it's  
> after 3.3.9. It's definitely after 3.1.3.
>
> I'm using Mac OS X 10.4.8, with the database file on an AppleShare  
> mounted volume.
>
> What's the issue here? Is it a known bug? Will it be fixed?
>

This is not a bug in SQLite - it is a bug in Apple's implementation
(or more precisely their lack of implementation) of POSIX advisory
locks for AppleShare mounted volumes.  The SQLite sources include
an (Apple-supplied) patch to work around the problem. Recompile
with

   -DSQLITE_ENABLE_LOCKING_STYLE=1

We are working toward turning on this patch by default, but we are not
quite there yet.

--
D. Richard Hipp  <[hidden email]>



-----------------------------------------------------------------------------
To unsubscribe, send email to [hidden email]
-----------------------------------------------------------------------------

Reply | Threaded
Open this post in threaded view
|

database is locked error on Mac OS X

BareFeetWare
>> I recently installed SQLite 3.3.13, after having used previous
>> versions. I now get an error:
>>
>> Error: database is locked

> This is not a bug in SQLite - it is a bug in Apple's implementation  
> (or more precisely their lack of implementation) of POSIX advisory  
> locks for AppleShare mounted volumes.  The SQLite sources include  
> an (Apple-supplied) patch to work around the problem.

Thank you :-)

> Recompile with
>
>    -DSQLITE_ENABLE_LOCKING_STYLE=1

Pardon my ignorance, but where/how exactly do I enter this before  
recompiling?

Thanks,
Tom


-----------------------------------------------------------------------------
To unsubscribe, send email to [hidden email]
-----------------------------------------------------------------------------

Reply | Threaded
Open this post in threaded view
|

Fwd: database is locked error on Mac OS X

BareFeetWare
Can someone please tell me (politely ;-) where to put the -
DSQLITE_ENABLE_LOCKING_STYLE=1

I tried inserting it arbitrarily in the Makefile.in file but it  
didn't seem to make a difference.

Don't laugh :-[ ;-)

Thanks,
Tom

  ----
From: T&B <[hidden email]>
Date: 9 March 2007 1:46:21 PM
To: [hidden email]
Subject: [sqlite] database is locked error on Mac OS X
Reply-To: [hidden email]

>> I recently installed SQLite 3.3.13, after having used previous
>> versions. I now get an error:
>>
>> Error: database is locked

> This is not a bug in SQLite - it is a bug in Apple's implementation  
> (or more precisely their lack of implementation) of POSIX advisory  
> locks for AppleShare mounted volumes.  The SQLite sources include  
> an (Apple-supplied) patch to work around the problem.

Thank you :-)

> Recompile with
>
>    -DSQLITE_ENABLE_LOCKING_STYLE=1

Pardon my ignorance, but where/how exactly do I enter this before  
recompiling?

Thanks,
Tom

-----------------------------------------------------------------------------
To unsubscribe, send email to [hidden email]
-----------------------------------------------------------------------------

Reply | Threaded
Open this post in threaded view
|

Re: Fwd: database is locked error on Mac OS X

D. Richard Hipp
T&B <[hidden email]> wrote:
> Can someone please tell me (politely ;-) where to put the -
> DSQLITE_ENABLE_LOCKING_STYLE=1
>
> I tried inserting it arbitrarily in the Makefile.in file but it  
> didn't seem to make a difference.
>

Do "configure".  Then edit the Makefile that is generated.
--
D. Richard Hipp  <[hidden email]>


-----------------------------------------------------------------------------
To unsubscribe, send email to [hidden email]
-----------------------------------------------------------------------------

Reply | Threaded
Open this post in threaded view
|

Re: Fwd: database is locked error on Mac OS X

Puneet Kishor-2
On 3/10/07, [hidden email] <[hidden email]> wrote:
> T&B <[hidden email]> wrote:
> > Can someone please tell me (politely ;-) where to put the -
> > DSQLITE_ENABLE_LOCKING_STYLE=1
> >
> > I tried inserting it arbitrarily in the Makefile.in file but it
> > didn't seem to make a difference.
> >
>
> Do "configure".  Then edit the Makefile that is generated.

I think Tom is trying to figure out where exactly in the Makefile to
insert the D flag. Tom, I am walking on thin ice here, but after you
have run ./configure, you could try inserting a line like so pretty
much anywhere in your Makefile.in AFTER TCC has been declared. So, you
could add a line like so

# flag to deal with Mac OS X file locking on shared drives
TCC += -DSQLITE_ENABLE_LOCKING_STYLE=1

Obviously, I could be way wrong about this, but if I am, hopefully
someone will chime up and tell us so.,


--
Puneet Kishor http://punkish.eidesis.org/
Nelson Inst. for Env. Studies, UW-Madison http://www.nelson.wisc.edu/
Open Source Geospatial Foundation http://www.osgeo.org/education/
---------------------------------------------------------------------
collaborate, communicate, compete
=====================================================================

-----------------------------------------------------------------------------
To unsubscribe, send email to [hidden email]
-----------------------------------------------------------------------------

Reply | Threaded
Open this post in threaded view
|

Re: Fwd: database is locked error on Mac OS X

Aristotle Pagaltzis
In reply to this post by D. Richard Hipp
* [hidden email] <[hidden email]> [2007-03-10 17:30]:
> Do "configure". Then edit the Makefile that is generated.

It would be nice if these options were mapped to `--enable-foo`
switches on the configure script… would that take a lot of work?

(Alternatively, if you don’t want to do it yourself: would it
take a lot of research to learn how to do it? If not, and you’d
be willing to accept a patch, I might contribute one.)

Regards,
--
Aristotle Pagaltzis // <http://plasmasturm.org/>

-----------------------------------------------------------------------------
To unsubscribe, send email to [hidden email]
-----------------------------------------------------------------------------

Reply | Threaded
Open this post in threaded view
|

Re: database is locked error on Mac OS X

BareFeetWare
In reply to this post by D. Richard Hipp
Hi Richard and Puneet,

I just wanted to say thanks, and to record your combined advice that  
worked. Much of this may be superfluous or painfully obvious, but it  
worked:

1. In the sqlite-3.3.13 downloaded source directory, execute:

./configure

2. That creates a new file "MakeFile". Edit that file in any text  
editor, and add these lines:

# flag to deal with Mac OS X file locking on shared drives
TCC += -DSQLITE_ENABLE_LOCKING_STYLE=1

I put them just before the line:

# You should not have to change anything below this line

3. Execute:

sudo make
sudo make install

Done.

You can now run/test the new sqlite3 command line tool by executing:

/usr/local/bin/sqlite3

which will show:

SQLite version 3.3.13
Enter ".help" for instructions

Editing a database file on a remote volume now works with this  
modified latest version.

Thanks again.
Tom


-----------------------------------------------------------------------------
To unsubscribe, send email to [hidden email]
-----------------------------------------------------------------------------

Reply | Threaded
Open this post in threaded view
|

Re: database is locked error

BareFeetWare
In reply to this post by D. Richard Hipp
Following up an old thread:

> The SQLite sources include an (Apple-supplied) patch to work around  
> the problem. Recompile
> with
>
>    -DSQLITE_ENABLE_LOCKING_STYLE=1
>
> We are working toward turning on this patch by default, but we are  
> not quite there yet.

I compiled and ran SQLite 3.3.17 and got the old error again when  
accessing a database file on a server volume, with SQLite saying it  
is locked.

Does this mean that we are still "not quite there yet" with a default  
fix? Any time frame?

Thanks,
Tom


-----------------------------------------------------------------------------
To unsubscribe, send email to [hidden email]
-----------------------------------------------------------------------------

Reply | Threaded
Open this post in threaded view
|

Re: database is locked error

BareFeetWare
Is there a timetable for including the fix for opening SQLite files  
on a shared volume? Since it's fairly trivial, is there a reason why  
it hasn't been included yet?

Thanks,
Tom

  ----
From: T&B <[hidden email]>
Date: 29 April 2007 3:35:00 AM
To: [hidden email]
Subject: Re: [sqlite] database is locked error

Following up an old thread:

> The SQLite sources include an (Apple-supplied) patch to work around  
> the problem. Recompile
> with
>
>    -DSQLITE_ENABLE_LOCKING_STYLE=1
>
> We are working toward turning on this patch by default, but we are  
> not quite there yet.

I compiled and ran SQLite 3.3.17 and got the old error again when  
accessing a database file on a server volume, with SQLite saying it  
is locked.

Does this mean that we are still "not quite there yet" with a default  
fix? Any time frame?

Thanks,
Tom




-----------------------------------------------------------------------------
To unsubscribe, send email to [hidden email]
-----------------------------------------------------------------------------