- Install
$ sudo apt-get update $ sudo apt-get install postgresql postgresql-contrib
- Switch to
postgres
user$ sudo -i -u postgres
- Create
root
accountcreateuser --interactive
Input
root
, as superuser - Create
root
database for userroot
createdb root
- Alter
root
’s passwordpsql alter user root with encrypted password 'toor'
Now you can access to PostgreSQL by root
and password toor