Sign up ×
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

I have the Postres app installed an running on my Mac. And it has worked beautifully. I don’t know what changed, but now I cannot connect to it from Rails, PG Commander, PG Admin or the command psql -h localhost. However, I can connect with just psql. I get the following error in the log as soon as the connection times out:

LOG:  incomplete startup packet

Rails database.yml

  adapter: postgresql
  database: my_db
  host: localhost

PG Commander settings:

enter image description here


# "local" is for Unix domain socket connections only
local   all             all                                     trust
# IPv4 local connections:
host    all             all               trust
# IPv6 local connections:
host    all             all             ::1/128                 trust


share|improve this question
Check the settings in pg_hba.conf which can be found in the data dir. My guess is you allow ip4 and deny ip6 or vice versa. Adjusting log settings in postgresql.conf may also prove informative. – sambler Jan 29 '14 at 5:43
I updated the question with those 2 files. It would appear that both ipv4 and 6 are enabled. I haven’t touched any config files though. – David Beck Jan 29 '14 at 14:36
The message starting with LOG doesn't mean there is an error. Still, you can have a look here for some clues. Are there any other messages (LOG or FATAL) around in the log? – dezso Jan 29 '14 at 15:41
Yes, I know. I’ve seen tons of responses noting that certain services can cause that message to appear. However, it is not happening at regular intervals, only when a connection finally times out. And it is the only message, so it is all I have to go on. – David Beck Jan 29 '14 at 16:02
You may want to check your firewall settings. Then in postgresql.conf try setting log_connections=on and log_min_messages=debug1 and see what shows up in the logs. Increase log_min_messages up to debug5 if that isn't helpful. – sambler Jan 30 '14 at 9:55

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.