su -c "createuser -h localhost --createdb --no-createrole --no-superuser
ah3" postgres
su -c "createdb -h localhost --owner ah3 ah3" postgres
su -c "psql -h localhost --user ah3 ah3 < /opt/ah3/database/ah3.psql"
postgres
I don't know what is the default password is for the user "postgres"
however. How do I fix this problem, please?
I don't know about CentOS but normally the password for the postgres DB user is supplied during installation.
However, you can easily reset the password:
http://archives.postgresql.org/pgsql-admin/2002-06/msg00197.php
http://www.depesz.com/index.php/2008/11/28/recovering-lost-postgresql-password/
Thomas