Postgresql User Management

Changing a user password

  • su -c psql postgres
  • \password tdobes

Creating a user

  • su -c "createuser -d -P -r -s tdobes" postgres
    • -d = can create databases
    • -P = prompt for password
    • -r = can create new roles (a.k.a. users or groups)
    • -s = is superuser
  • su -c "createuser -P drupal" postgres

Creating a database

  • su -c "createdb --encoding=UNICODE --owner=drupal --template=template0 drupaldb" postgres
computer/postgresql_user_management.txt · Last modified: 2011/05/18 20:08 by tdobes
Recent changes RSS feed Driven by DokuWiki Valid XHTML 1.0 Valid CSS