Обсуждение: first steps
Hey Group; I have looked at the suggestions on > http://www.postgresql.org/docs/8.4/static/ But I still am confused setting up the permissions and myself as a user. I have seen /home/donn/.pgpsql and .pgadmin. However, I am not sure where to start - edit postgres's pg_hba.conf file maybe? /usr/bin/postmater is available. I do have pgadmin3 and it requires a pgsql user and password. -- 73 de Donn Washburn 307 Savoy Street Email:" n5xwb@comcast.net " Sugar Land, TX 77478 LL# 1.281.242.3256 Ham Callsign N5XWB HAMs : " n5xwb@arrl.net " VoIP via Gizmo: bmw_87kbike / via Skype: n5xwbg BMW MOA #: 4146 - Ambassador " http://counter.li.org " #279316
Donn Washburn wrote: > I have looked at the suggestions on > > http://www.postgresql.org/docs/8.4/static/ > But I still am confused setting up the permissions and myself as a user. > I have seen /home/donn/.pgpsql and .pgadmin. However, I am not sure > where to start - edit postgres's pg_hba.conf file maybe? > /usr/bin/postmater is available. I do have pgadmin3 and it requires a > pgsql user and password. For instance, you may want to create new database and new user. First, swith to postgres user: su - postgres Than open psql psql Than create database CREATE DATABASE test_database WITH ENCODING='UTF8'; Then create user CREATE USER donn PASSWORD 'changeme'; Then, connect to the database: \c test_database Then, grant privilleges to user donn: GRANT ALL ON SCHEMA public TO donn; Next, try to connect to the specified database with specified user: \q exit psql test_database donn If that works fine, try connecting to that same database with the same user using pgAdmin. If both pgAdmin and PostgreSQL are on the same machine, there is no need to modify pg_hba.conf and postgresql.conf. Regards, Ognjen
Please, post to the mailing list, not private. When are you asked for password? At "psql" or "psql test_database donn"? -Ognjen Donn Washburn wrote: > I assume the password is <enter> but that fails. So does any other > guess I try. This is a 11.3 M4 rpm based 8.4 postgres install > > On 04/14/2010 03:35 AM, Ognjen Blagojevic wrote: >> Donn Washburn wrote: >>> I have looked at the suggestions on > >>> http://www.postgresql.org/docs/8.4/static/ >>> But I still am confused setting up the permissions and myself as a user. >>> I have seen /home/donn/.pgpsql and .pgadmin. However, I am not sure >>> where to start - edit postgres's pg_hba.conf file maybe? >>> /usr/bin/postmater is available. I do have pgadmin3 and it requires a >>> pgsql user and password. >> >> For instance, you may want to create new database and new user. First, >> swith to postgres user: >> >> su - postgres >> >> Than open psql >> >> psql >> >> Than create database >> >> CREATE DATABASE test_database WITH ENCODING='UTF8'; >> >> Then create user >> >> CREATE USER donn PASSWORD 'changeme'; >> >> Then, connect to the database: >> >> \c test_database >> >> Then, grant privilleges to user donn: >> >> GRANT ALL ON SCHEMA public TO donn; >> >> Next, try to connect to the specified database with specified user: >> >> \q >> exit >> psql test_database donn >> >> If that works fine, try connecting to that same database with the same >> user using pgAdmin. If both pgAdmin and PostgreSQL are on the same >> machine, there is no need to modify pg_hba.conf and postgresql.conf. >> >> Regards, >> Ognjen >> >