Skip to main content

Posts

Showing posts with the label Upgrade PostgreSQL Cluster

Matching PostgreSQL Client and Server Versions

Hi, When PostgreSQL server and cluster versions don't match, PostgreSQL doesn't let you to run some functions, therefore you can not use efficiently and can not be advanced on it. To solve this problem you need to upgrade version or follow bellow steps. You can try all of steps for your development or test environments. I installed PostgreSQL server and client with different versions to show what is gonna happen If I try to dump. For sure, I can not get pg_dump! -bash-4.2$ pg_dump -s testdb > testdb_dump.sql pg_dump: server version: 9.6.3; pg_dump version: 9.2.18 pg_dump: aborting because of server version mismatch -bash-4.2$ pg_ctl stop -m fast waiting for server to shut down.... done server stopped -bash-4.2$ mv /var/lib/pgsql /tmp/pgsql_cluster_old mv: cannot move ‘/var/lib/pgsql’ to ‘/tmp/pgsql_cluster_old’: Permission denied To move pgsql file, need to be root at this moment. -bash-4.2$ logout [root@gunce-test tmp]# mv /var/lib/pgsql /tmp/pgsql_clu...