Configurazione Postgresql
Ciao a tutti.
Ho installato per la prima volta postgresql su un mio piccolo server, ho
creato un nuovo database di nome mat ed un nuovo utente di nome matteo;
quindi ho abilitato l'host 192.168.1.2 (che sarà il client) a tutti i
database ma con autenticazione dell'utente (ho anche provato senza
autenticazione). Casomai posto i file di configurazione.
Comunque il problema è questo: sul client ho installato il pacchetto
postgresql-client ma dando il comando
psql -h vecio -d mat
(vecio è 192.168.1.2)
ottengo il seguente output
psql: FATAL: manca una voce in pg_hba.conf per l'host "192.168.1.2",
utente "matteo", database "mat", SSL non attiva
L'ultima parte di pg_hba.conf (il resto comunque è tutto disabilitato) è
la seguente:
# TYPE DATABASE USER IP-ADDRESS IP-MASK METHOD
# Database administrative login by UNIX sockets
local all postgres
ident sameuser
#
# All other connections by UNIX sockets
local all all
ident sameuser
#
# All IPv4 connections from localhost
host all all 127.0.0.1 255.255.255.255
ident sameuser
#
# All IPv6 localhost connections
host all all ::1
ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff ident sameuser
host all all ::ffff:127.0.0.1/128
ident sameuser
#
# reject all other connection attempts
host all all 0.0.0.0 0.0.0.0 reject
host all all 192.168.1.2 255.255.255.255 ident
L'ultima riga presumo sia quella incriminata, non l'ho scritta io
direttamente ma c'e l'ha aggiunta webmin-postgresql in base alle mie
richieste. Che c'è che non va?
Grazie dell'aiuto.
Reply to: