change user password in linux; e.g. for user postgres
To change a password on behalf of a user, first sign on or “su” to the “root” account. Then type, ``passwd user’’
Change the user to postgres :
su - postgres
Create User for Postgres
$ createuser testuser
Create Database
$ createdb testdb
Acces the postgres Shell
psql ( enter the password for postgressql)
Provide the privileges to the postgres user
$ alter user testuser with encrypted password 'qwerty';
$ grant all privileges on database testdb to testuser;