pgAdmin
Install
_$: apt-get install pgadmin3
Update
We will install a new version of PostgreSQL and a new version of pgadmin too. The current version of PostgreSQL will be reachable on port 5432
and the new one on port 5433
_$: $ pgadmin3 --version
pgAdmin III 1.18.1
_$: service postgresql status
9.3/main (port 5432): online
_$: lsb_release -cs
trusty
/etc/apt/sources.list.d/pgdg.list:
----------------------------------
deb http://apt.postgresql.org/pub/repos/apt/ trusty-pgdg main
_$: wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add -
_$: sudo apt-get update
_$: sudo apt-get upgrade
_$: sudo apt-get install postgresql-9.5 pgadmin3
Check
_$: pgadmin3 --version
pgAdmin III 1.22.1
_$: service postgresql status
9.3/main (port 5432): online
9.5/main (port 5433): online
Accept incoming connections
Our database server is located at 192.168.1.191:5432
and we have to configure it to accept incoming connections from hosts in the same network (192.168.1.0).
/etc/postgresql/9.1/main/pg_hba.conf:
-------------------------------------
...
# "local" is for Unix domain socket connections only
local all all trust
# IPv4 local connections:
host all all 127.0.0.1/32 md5
host all all 192.168.1.0/24 md5
_$: service postgresql restart
Connection
In pgAdminIII go to Add a connection to a server
Name: development
Host: 192.168.1.191
Port: 5432
Service: -
Maintenance DB: postgres
Username: <user>