Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to install PgAdmin 4 on Ubuntu 20 [duplicate]

After Upgrading to Ubuntu-20.04 I am unable to install pgadmin4. Also, any other version of pgadmin is not working.

It is showing below error:

Package pgadmin4 is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package 'pgadmin4' has no installation candidate
E: Unable to locate package pgadmin4-apache2

In my "pgdg.list" file which can be accessed from below command

sudo nano /etc/apt/sources.list.d/pgdg.list

I have:

deb http://apt.postgresql.org/pub/repos/apt/ focal-pgdg main
like image 522
Shubham Soni Avatar asked Nov 16 '22 12:11

Shubham Soni


2 Answers

You must create the /etc/apt/sources.list.d/pgdg.list file and add the line:

deb http://apt.postgresql.org/pub/repos/apt/ focal-pgdg main

Then run:

wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add -

Finally, run:

sudo apt-get update && sudo apt-get install pgadmin4

For more details: https://www.postgresql.org/download/linux/ubuntu/

like image 127
zFortes Avatar answered Dec 06 '22 23:12

zFortes


I'm having the same issue... apt.postgresql.org is in the "sources.d", I can see it is "Hit" by "apt update", but still no pgadmin4 installation candidate found.

It looks like focal (20.04) is simply not currently supported (although multiple articles indicate it was at one point). Earlier versions are all there. Alas, trying to install them leads to the requirement of python3-psyco2 < 2.8, but 2.8 is the focal version. Perhaps a build fail caused it to drop from repos, or an upstream version change is causing a problem... it's beyond me at this point...

Anyway, I'm not up to working that hard for it... so it's our good old friend "psql" for me right now :-)

like image 33
Tengam Avatar answered Dec 06 '22 21:12

Tengam