pg_restore archiver unsupported version (1.13) in file header

If you get the error “pg_restore archiver unsupported version” while restoring, most propably it is because of the version. You may get this error because the version on the server you backed up from and the version on the server you want to restore are not the same. Or, if you checked the versions but still get the same error when you try to restore, it may be because you are using a different binary.

Let’s consider the scenario where the versions are the same but we use different binaries.

We go to both servers and run the following command and see that the versions are the same.

We saw that postgresql is 11.9 and let’s do the restore using version 11 as follows.

-p = the part where we specify the port of postgresql11

-d = database name

– /var/lib/pgsql/11/data/backup.sql = The path information of the backup.

Faruk Erdem
Author: Faruk Erdem

Leave a Reply

Your email address will not be published. Required fields are marked *