- Start postgres
psql template1
CREATE USER root WITH SUPERUSER;
Or
sudo -u -i postgres
- createuser --interactive root
- psql
- ALTER USER "root" WITH PASSWORD 'new_password';
root~# createdb db_name
vim /etc/postgresql/9.3/main/pg_hba.conf
- Insert line
host all all 192.168.101.20/24 trust
- Change listen in postgresql.conf
http://www.thegeekstuff.com/2014/02/enable-remote-postgresql-connection/