I'm attempting to set up archiving on a windows server machine but when I check the logs nothing is happening.

The postgresql.conf file this is my input:

#wal_level = replica

#archive_mode = on
#archive_command = 'copy "%p" "\\\temp\archivedir\\%f"' 
also tried this
#archive_command = 'copy "%p" "c:\\temp\archivedir\\%f"'

#archive_timeout = 0

Any ideas why this isn't archiving?

1 Answer 1


The # at the beginning of a line means it's a comment. Those lines aren't doing anything.

You need to use:

archive_mode = on
archive_command = 'copy "%p" "c:\\temp\archivedir\\%f"'

Note, there is no # at the beginning of the line.

wal_level = replica is only needed for the master, not the replica.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.