Psql points to a different version of the server

Today I was asked to upgrade my OS from Ubuntu 14.04 LTS to 16.04 LTS. Generally speaking, everything went smoothly. However, I received error messages indicating that the PostgreSQL upgrade from 9.3 to 9.5 failed. In the end, I was able to install postgresql-9.5 and verified that I was seeing my previously created databases and tables.

However, when I use the command psqlto access the database named hierarchyas follows, I get some unfamiliar output:

$ psql hierarchy jkeenan
psql (9.5.3, server 9.3.13)
Type "help" for help.

Does this mean that part of my PostgreSQL setup (in the broad sense) has not been updated to 9.5?

Update: Inside psqlI can say SELECT version();and get this conclusion:

 PostgreSQL 9.3.13 on x86_64-unknown-linux-gnu, compiled by gcc (Ubuntu 4.8.4-2ubuntu1~14.04.1) 4.8.4, 64-bit

How can I perform this update? Is the difference between the version psqland the "server" version that I should worry about?

Other data that may be useful in the diagnosis:

$ createdb --version
createdb (PostgreSQL) 9.5.3
$ psql --version
psql (PostgreSQL) 9.5.3

Many thanks.

+4
source share

Source: https://habr.com/ru/post/1649732/


All Articles