Struggling with con...
 
Notifications
Clear all

[Solved] Struggling with concept of WAL files

3 Posts
2 Users
1 Reactions
1,056 Views
(@sevenofnine)
Active Member
Joined: 5 years ago
Posts: 17
Topic starter  

Hi guys,

Im struggling with write ahead logs and understanding them. I get the concept that it is basically a role back journal in reverse and any data, say web history for example, is written to the log and then committed to the actual database at a checkpoint thats either automatic at 1000 pages or forced by design. Am I correct in saying this is to save multiple writes to disk? But, if this log is written to disk how are we saving on writes? If the file is held in memory then this would make more sense to me but I cant find much detail around this.

I appreciate its highly likely I am missing a very simple concept here so I apologise upfront.

Thanks

P


   
Quote
minime2k9
(@minime2k9)
Honorable Member
Joined: 14 years ago
Posts: 481
 

I recently did a bit of a write-up on WAL files:

https://askclees.com/2020/10/11/timelining-using-sqlite-write-ahead-logs/

Might be useful to you, it does explain about them outside of using them for timelining


   
trewmte reacted
ReplyQuote
(@sevenofnine)
Active Member
Joined: 5 years ago
Posts: 17
Topic starter  

Thanks minime2k9, very in depth explanation. I scanned through it but to be honest beed to take some time to read it in detail and come back to you.

Thanks again.


   
ReplyQuote
Share: