On 19 Jan 2011, at 11:53, Russell Leighton wrote:

> Perhaps that could be the default and a pragma could be used to  
> override this default and specify the directory holding the WAL.
> 
> This could be useful in cases  that users want to put the WAL  
> someplace else (like an SSD).

I think you're getting way beyond the 'Lite' world with that one.

On modern Linux systems you can use

mount --bind /path/to/existing/file /alternate/path/to/that/file

Which makes any access of /alternate/path/to/that/file an access of 
/path/to/existing/file. Both must exist; I recommend using touch to create the 
file at the alternate path, as it's mostrously confusing if it contains any 
data when the mount has not been run.

You could use this facility to make the SQLite database appear to be on your 
SSD. For safety's sake you should also make the WAL file appear to be colocated 
with the database, so that the WAL file can be found by an application which 
accesses the database with either path. This may or may not be safe depending 
on whether SQLite uses the path to the database to perform any locking.

To be clear: I won't be doing this myself…

Best Regards,

Phil Willoughby
-- 
Managing Director, StrawberryCat Limited

StrawberryCat Limited is registered in England and Wales with Company No. 
7234809.

The registered office address of StrawberryCat Limited is:

107 Morgan Le Fay Drive
Eastleigh
SO53 4JH

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

Reply via email to