maxy04
28. September 2013 um 19:54
1
Excuse me but i don’t speak deuscht.
I’m finding a problem in pg settings.
i set pg_hba.conf in this way:
local all all md5
host all all 127.0.0.1/32 md5
it does work while i do
psql -d mydb
pg ask me the password.
but if i do
psql -U postgres -d borsa
it don’t ask me the password, and it is wrong.
what is the problem?
maxy04:
Excuse me but i don’t speak deuscht.
I’m finding a problem in pg settings.
i set pg_hba.conf in this way:
local all all md5
host all all 127.0.0.1/32 md5
it does work while i do
psql -d mydb
pg ask me the password.
that’s okay.
but if i do
psql -U postgres -d borsa
it don’t ask me the password, and it is wrong.
what is the problem?
show us the whole pg_hba.conf, i guess there a special line for the postgres-user some lines before.
maxy04
30. September 2013 um 18:37
3
this is the whole pg_hba.conf
local all all md5
host all all 127.0.0.1/32 md5
#host all all 192.168.1.0/24 md5
there is only a commented line.
the strange thing is this: i have a raspberry pi with slackware 14(the same i have on laptop), i used the same postgresql source for compiling, i use the same pg_hba.conf, and this ask me the password.
maxy04:
this is the whole pg_hba.conf
local all all md5
host all all 127.0.0.1/32 md5
#host all all 192.168.1.0/24 md5
there is only a commented line.
the strange thing is this: i have a raspberry pi with slackware 14(the same i have on laptop), i used the same postgresql source for compiling, i use the same pg_hba.conf, and this ask me the password.
open psql, and execute:
show hba_file;
is this the file you edited?
maxy04
30. September 2013 um 20:07
5
yes, it is.
the postgresql.conf
data_directory = ‘/data/pgsql’
hba_file = ‘/data/pgsql/pg_hba.conf’
ident_file = ‘/data/pgsql/pg_ident.conf’
listen_addresses = ‘localhost,192.168.1.79’ # my pc
port = 5432
max_connections = 10
shared_buffers = 24MB
log_destination = ‘syslog’
syslog_facility = ‘LOCAL0’
syslog_ident = ‘postgres’
log_min_messages = info
log_min_error_statement = info
log_line_prefix=’%a %u %d %t’
datestyle = ‘iso, ymd’
lc_messages = ‘it_IT.utf8’
lc_monetary = ‘it_IT.utf8’
lc_numeric = ‘it_IT.utf8’
lc_time = ‘it_IT.utf8’
default_text_search_config = ‘pg_catalog.italian’