I'm don't know much about database management, so to enable the remote access to my postgresql db I followed some tutorials. I've updated pg_hba_conf and postgresql_conf files.
In pg_hba_conf I added the
"host all all 0.0.0.0/0 md5"
line in the "# IPv4 local connections" slot.
I've been succeeded for some days, but since yesterday there's a problem happening. In the computer I'm remote accessing the server, after I input the password for postgres user, PgAdmin returns "timeout expired".
First I've checked the server properties, and discovered that the IP inserted was not correct (what seemed strange, but I've corrected anyway). For the day it did, but today the same "timeout expired" message appeared again. The remote access settings are fine in PgAdmin, but as I checked pg_hba_conf in the server computer, it came with this settings where I've updated in first time:
"# IPv4 local connections: host all all 127.0.0.1/32 @authmethodhost@"
Seems that it automatically removed my updated line and also altered the authentication method (as I remember, the default was "md5" and not this @authmethodhost@). I'm really confused with that.
Below I'm copying a print from the pg_hba_conf file for you to check if there's another change that I wasn't able to perceive.