Thread: problem with password
I create the database by following:
mkdir -p /usr/local/pgsql/data
chown postgres /usr/local/pgsql/data
su postgres
chown postgres /usr/local/pgsql/data
su postgres
initdb -D /usr/local/pgsql/data
postmaster -D /usr/local/pgsql/data
createdb appc
psql appc
postmaster -D /usr/local/pgsql/data
createdb appc
psql appc
Then i create a same user:
create user dima with password 'dima'
\q
\q
Then:
psql appc -U dima -W
Password: __Input any password__ - enter to postgresql.
Password: __Input any password__ - enter to postgresql.
Why i can access to database with any password? What is my error?
update user set password = password('dima') where user = 'dima'
that should fix your problem.
----- Original Message -----From: SashaSent: Thursday, February 27, 2003 10:49 AMSubject: [GENERAL] problem with passwordI create the database by following:mkdir -p /usr/local/pgsql/data
chown postgres /usr/local/pgsql/data
su postgresinitdb -D /usr/local/pgsql/data
postmaster -D /usr/local/pgsql/data
createdb appc
psql appcThen i create a same user:create user dima with password 'dima'
\qThen:psql appc -U dima -W
Password: __Input any password__ - enter to postgresql.Why i can access to database with any password? What is my error?
On Thu, 27 Feb 2003, Sasha wrote: > I create the database by following: > > mkdir -p /usr/local/pgsql/data > chown postgres /usr/local/pgsql/data > su postgres > > initdb -D /usr/local/pgsql/data > postmaster -D /usr/local/pgsql/data > createdb appc > psql appc > > Then i create a same user: > > create user dima with password 'dima' > \q > > Then: > > psql appc -U dima -W > Password: __Input any password__ - enter to postgresql. > > Why i can access to database with any password? What is my error? What does your pg_hba.conf file (in the data directory) say?