Questions tagged [wal]

WAL, or write-ahead log, is a form of journalling used as part of crash-safety and atomic commit support in databases like PostgreSQL and SQLite.

PostgreSQL's write-ahead log is a crucial feature that permits crash-safety and atomic commit to be implemented. It's also heavily used in PostgreSQL's point-in-time recovery, streaming replication, and archive based replication features, as well as hot physical backup.

In SQLite, the default method by which SQLite implements atomic commit and rollback is a rollback journal. Beginning with version 3.7.0, a new "Write-Ahead Log" option (hereafter referred to as "WAL") is available.

229 questions
2
votes
1 answer

ArangoDB timeout due to too many write ahead logs

I am trying to restart my ArangoDB instance but I keep getting a timeout and I think it is because of the replaying of the WAL log files. At first there were 2725 files, now there are 2701. I've let Arango replay all the files (as seen below) but I…
Stanko
  • 4,275
  • 3
  • 23
  • 51
2
votes
2 answers

Redis AOF fsync (ALWAYS) vs. LSM tree

My understanding of log structured merge trees (LSM trees) is that it takes advantage of the fact that appending to disk is very fast (since it requires no seeks) by just appending the update to a write-ahead log and returning to the client. My…
bhh1988
  • 1,262
  • 3
  • 15
  • 30
2
votes
1 answer

querying the database's write-ahead log

I'd like to be able to track changes made to a database (PostgreSQL) over the past month. I know of two options: database triggers change data capture of the write-ahead log But is there no way to query the write-ahead log directly from the…
skunkwerk
  • 2,920
  • 2
  • 37
  • 55
2
votes
1 answer

Does a SQLite WAL file ever reduce in size by itself?

My SQLite WAL file gets very large sometimes and I think that the file retains its size and just begins to overwrite as necessary, does it ever just reset its size? I'm aware of the pragma wal_checkpoint(TRUNCATE) command to manually set a…
Tacitus86
  • 1,314
  • 2
  • 14
  • 36
2
votes
2 answers

WAL file is from different database system

Am using WAL E and trying to restore a postgresql database i get the error WAL file is from different database system: WAL file database system identifier is 6422218584094261886, pg_control database system identifier is…
2
votes
1 answer

WAL synchronization NORMAL vs. OFF

In the original documents for WAL the difference between FULL and NORMAL synchronization is clearly stated1: Write transactions are very fast since they only involve writing the content once (versus twice for rollback-journal transactions) and …
Davor Josipovic
  • 5,296
  • 1
  • 39
  • 57
2
votes
0 answers

wal-e backup-push not terminating (waiting for required WAL segments to be archived)

Trying to setup wal-e for postgres. Following various tutorials and I'm at a point to finally do a first backup of a clean 9.6 postgres install. Followed some tutorials and finally read to do an initial wal-e backup-push, as follows: sudo -u…
Geert-Jan
  • 18,623
  • 16
  • 75
  • 137
2
votes
1 answer

Barman recover command not copying "all" WAL files to standby database server from on Barman server

What is wrong with the recover command that isn't transferring these WAL files? barman recover --target-time "2017-05-16 16:39:02.235780+00:00" \ --remote-ssh-command "ssh postgres@52.212.62.91" \ main-db latest /var/lib/postgresql/9.4/main Here is…
aidanmelen
  • 6,194
  • 1
  • 23
  • 24
2
votes
0 answers

Android sqlite write ahead logging notworking

I am using SQLiteOpenHelper in Android with calling setWriteAheadLoggingEnabled(true); basically I do a bunch of network syncs (each one in their own thread and they call the next one in their onPostExecute) each time so I want to put all of them…
Muhammad Naderi
  • 3,090
  • 3
  • 24
  • 37
2
votes
1 answer

How Sqlite3 recovery in WAL mode when system crash

I'm wondering about the recovery progress in SQLite (WAL mode). If system crash occurs, how SQLite knows 'I have to recovery using WAL file'? and what SQLite exactly do in recovery progress? please help.
2
votes
0 answers

Reading HBase WAL file with Java

I need to read Hbase WAL in my code. I found out the class https://hbase.apache.org/0.94/apidocs/index.html?org/apache/hadoop/hbase/regionserver/wal/HLogPrettyPrinter.html. However it doesn't look like class for external use. Does someone have…
miuser
  • 111
  • 5
2
votes
2 answers

Postgresql Automatic archive purge not occuring

I read several document on postgresql archive recovery and cleanup but my postgresql server still don't purge archive, or I didn't really understand how it works. Simply, I wrote a shell script for WAL archive cleanup. When I run the script from the…
nixmind
  • 2,060
  • 6
  • 32
  • 54
2
votes
1 answer

SQLite: Is there any way for use of WAL without mmap() function?

I want to use WAL mode for the reason of performance and reliability. However my environment doesn't have mmap() function, so I can't compile SQLite with WAL (WAL needs mmap().). Although setting PRAGMA locking_mode=EXCLUSIVE allow use of WAL…
sasaji
  • 23
  • 4
1
vote
1 answer

Is rollback transactions' data written into the Postres WAL?

I have a Postgres replication slot. I rollbacked a couple of transactions but the slot size increased drastically. I do not have any slot changes in it but the size has become huge. Is it possible that the rollbacked transactions are still present…
1
vote
1 answer

PostgreSQL not deleting old WAL archives

I have Postgresql 13 database and Barman 2.7 deployed for backing it up. The Barman is deployed on separated server. Barman is using streaming backup and WAL streaming via pg_recievewal. However the pg_wal directory become enormously large/not…