On Jun 8, 2010, at 10:54 PM, Daniel Stutzbach wrote: > On Tue, Jun 8, 2010 at 10:02 AM, Simon Slavin <slav...@bigfraud.org> > wrote: > >> I'm not sure whether a power-cut at a particularly bad time could >> cause >> something like this. The journaling mechanism built into SQLite >> should be >> avoiding it, but your combination of PRAGMAs might be defeating the >> normal >> defence mechanism. >> > > If my combination of pragmas defeat the defense mechanisms, that > would be an > SQLite bug, wouldn't it? The documentation for them certainly does > not > suggest that there would be any loss in reliability. Can anyone > confirm or > deny that they might be causing a problem? > > I started using PRAGMA locking_mode = EXCLUSIVE and PRAGMA > journal_mode = > TRUNCATE because certain aggressive virus-scanners/system-software > lock > files when they're scanning them. With those pragmas, I can lock the > database and journal once at the beginning and not worry about getting > "unable to open database file" errors later.
Those pragmas should not cause a problem. Simon's referring to "PRAGMA synchronous". The docs for which explain the risks assumed by changing the default setting. http://www.sqlite.org/pragma.html#pragma_synchronous _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users