Nikolaus Rath <[email protected]> writes: > I'm experimenting with creation of a 156 MB database from scratch. I've > set synchronous = NORMAL and locking_mode = exlusive. > > With journal_mode = off and without wrapping the INSERTs into a > transaction, creating the db takes 54 seconds. > > With journal_mode = WAL (and still no transaction), it takes an > impressive 900 seconds. > > With journal_mode = WAL and the INSERTs packed into a transaction, the > total time is 60 seconds.
Really no one an idea of why this is happening? Even taking into account that SQLite has to write a full page into the WAL (rather than just the new row + commit marker as I assumed), a factor of 20 slowdown seems excessive. Also, I believe that with synchronous = NORMAL, there should only be fsync() calls when checkpointing (rather than for every INSERT). Thanks, -Nikolaus -- »Time flies like an arrow, fruit flies like a Banana.« PGP fingerprint: 5B93 61F8 4EA2 E279 ABF6 02CF A9AD B7F8 AE4E 425C _______________________________________________ sqlite-users mailing list [email protected] http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

