1

I am trying to install the following packcage postgresql-server-dev-9.5. Using

sudo apt-get install postgresql-server-dev-9.5

Now, after I run this command I get this error:

Unable to locate package postgresql-server-dev-9.5.

Couldn't find any package by glob 'postgresql-server-dev-9.5'.

Couldn't find any package by regex 'postgresql-server-dev-9.5'

How can I fix this? I use ubuntu 18.04.1

  • If you really want to use this older version of Postgres (it is supported, but not the latest), install it from the Postgres APT repostiory, see wiki.postgresql.org/wiki/Apt – Colin 't Hart Oct 5 '18 at 10:00
3

Ubuntu 18.04 has PostgreSQL 10, so the correct package there is postgresql-server-dev-10:

sudo apt install postgresql-server-dev-10

To determine the major PostgreSQL version in a given release of Ubuntu, find the matching entries in the postgresql-common page on Launchpad. Thus:

  • 19.04 has PostgreSQL 11 (postgresql-server-dev-11)
  • 18.04 and 18.10 have PostgreSQL 10 (postgresql-server-dev-10)
  • 16.04 has PostgreSQL 9.5 (the second part of the version number is significant here; postgresql-server-dev-9.5)
  • 14.04 has PostgreSQL 9.3 (postgresql-server-dev-9.3)
  • 12.04 has PostgreSQL 9.1 (postgresql-server-dev-9.1)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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