Sunday , September 24 2023

PostgreSQL Upgrade From 9.6 To 11

In this article, I will talk about how to PostgreSQL Upgrade From 9.6 To 11 using pg_dumpall on Linux 7 operating system.

We are creating a new database called “test” for testing purposes.

We create a table in the database we have created and add records to it.

We can see the table we created and the records we added as follows.

After these operations, we take a backup of our database.

After completing the backup process, we stop the PostgreSQL 9.6 service and delete all the packages related to PostgreSQL.

We are backing up the data directory.

We install PostgreSQL 11 with the commands below.

We start the database, then start the service.

We are restoring the backup we took earlier.

We reboot the server.

We connect to the database and check whether the test database we created before exists.

As we can see above, we have a test database. Let’s check the table we created.

We are deleting the data directory of PostgreSQL 9.6 as the upgrade process has been completed successfully.

I hope it will be useful for you.



About Melek Durdu

Leave a Reply

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