December 2012
Intermediate to advanced
888 pages
48h 24m
English
To create a database user, you use su to become the user postgres from the Linux root account. You can then use the PostgreSQL createuser command to quickly create a user who is allowed to access databases or create new database users, as follows:
matthew@seymour:~$ createuser heatherShall the new user be allowed to create databases? (y/n) yShall the new user be allowed to create more new users? (y/n) yCREATE USER
In this example, the new user named phudson is created and allowed to create new databases and database users. (Carefully consider who is allowed to create new databases or additional users.)
You can also use the PostgreSQL command-line client to create a new user by typing psql along with name ...
Read now
Unlock full access