Re: [postgresql-it] Barman : WAL older than first backup

  • From: Giulio Calacoci <giulio.calacoci@xxxxxxxxxxxxxx>
  • To: postgresql-it <postgresql-it@xxxxxxxxxxxxx>
  • Date: Mon, 21 Dec 2015 14:23:42 +0100

Ciao Andrea,

Sono contento che fino ad oggi tu ti sia trovato bene con Barman.

Da quello che vedo dal tuo report credo che il nocciolo del problema giri
intorno alla migrazione.
Barman decide quali WAL eliminare rifacendosi allo start WAL del backup
piú vecchio, nel tuo caso quello del 28 novembre (che dovrebbe essere
pre-upgrade).
I backup, cosi' come i WAL, non sono compatibili fra versioni differenti.
Inolte anche la la numerazione dei WAL non é compatibile.

La versione nuova è a tutti gli effetti un nuovo server, quindi come tale
dovrebbe essere configurata anche all'interno del file di configurazione di
barman impiegando un nome identificativo diverso e reimpostando l'archive
command correttamente, il vecchio server invece deve essere disattivato o
rimosso dalla configurazione.
Alternativamente é possibile risolvere rimuovendo i due backup attualmente
presenti e procedendo con un nuovo base backup, ripartendo de facto da zero.

Saluti

Giulio

PS: Ti consiglio anche di aggiornare all'ultima  versione di barman :)

2015-12-21 9:46 GMT+01:00 Andrea Bazzanini <bazzanini.andrea@xxxxxxxxx>:

Ciao a tutti.

Da qualche tempo uso barman come sistema di backup di postgres. Direi con
notevole soddisfazione. Qualche settimana fa , ho aggiornato il db da
postgres 9.2 a 9.4
L'upgrade non ha presentato particolari problemi.

Da quando ho effettuato l'upgrade pero' sembra che barman non riesca piu
ad archiviare in modo corretto i WAL file che processa.

Questo e' il log di un backup :


Starting backup for server bluehub-db in 
/mnt/barman/bluehub-db/base/20151216T161801
Backup start at xlog location: 52A1/D1000028 (00000001000052A1000000D1, 
00000028)
Copying files.
Copy done.
Backup size: 3.3 TiB. Actual size on disk: 3.3 TiB (-0.00% deduplication 
ratio).
Asking PostgreSQL server to finalize the backup.
Backup end at xlog location: 52E1/85493888 (00000001000052E100000085, 
00493888)
Backup completed
Processing xlog segments for bluehub-db
      Older than first backup. Trashing file 00000001000052E100000051 from 
server bluehub-db
      Older than first backup. Trashing file 00000001000052E100000055 from 
server bluehub-db
      Older than first backup. Trashing file 00000001000052E100000056 from 
server bluehub-db
      Older than first backup. Trashing file 00000001000052E100000057 from 
server bluehub-db
      Older than first backup. Trashing file 00000001000052E100000058 from 
server bluehub-db
      Older than first backup. Trashing file 00000001000052E100000059 from 
server bluehub-db
      Older than first backup. Trashing file 00000001000052E10000005A from 
server bluehub-db
      Older than first backup. Trashing file 00000001000052E10000005B from 
server bluehub-db
      Older than first backup. Trashing file 00000001000052E10000005C from 
server bluehub-db
      Older than first backup. Trashing file 00000001000052E10000005D from 
server bluehub-db
      Older than first backup. Trashing file 00000001000052E10000005E from 
server bluehub-db


Questo e' l'output di un barmal list-backup

barman@barman:~$ barman list-backup all
bluehub-db 20151216T161801 - Sat Dec 19 11:32:39 2015 - Size: 3.3 TiB -
WAL Size: 0 B
bluehub-db 20151127T200001 - Sat Nov 28 06:03:12 2015 - Size: 3.6 TiB -
WAL Size: 0 B

Per qualche ragione il processso "barman cron" sembra non gradire i files
WAL che arrivano dal DB e dal messaggio che appare , sembra che consideri
il WAL piu vecchi dell' ultimo backup

L'errore e' comparso , dopo il passaggio da 9.2 a 9.4 , non so se e' un
caso o se e' la causa scatenante .

La versione di barman e' la 1.4.1






--
AndreA

<http://it.linkedin.com/in/andreabazzanini>





_______________________________________________
Postgresql-it mailing list
Postgresql-it@xxxxxxxxxxxxx
http://lists.psql.it/mailman/listinfo/postgresql-it




-- 
 Giulio Calacoci - 2ndQuadrant Italia
 PostgreSQL Training, Services and Support
 giulio.calacoci@xxxxxxxxxxxxxx | www.2ndQuadrant.it

Other related posts: