?

Log in

No account? Create an account
entries friends calendar profile adric.net Previous Previous Next Next
Re: could not create IPv6 socket when starting Postgres server - nil.enroll(aetheric_username, quantum_class_id)
yljatlhQo'! QIch lo'laltbebej!
adric
adric
Re: could not create IPv6 socket when starting Postgres server
Solution: edit /etc/hosts ?! Works.

Anecdote: I'm fooling around with Postgresql on my Macbook for educational purposes. I built it from source, for education value and because MacPorts failed me *sniff*. This is all going pretty well, and I'm finding Postgres mighty pleasant. MySQL is not a toy, but it may have started as one and grown up to be a database. PG is a gorram database (RDBMS), has been for aeons, and it shows everywhere. Even the command line client of psql is so much more sophisticated than mysql that it makes you tear up to have to use mysql again after you've used psql. But anyway ... we'll get back to the Postgresql propaganda later.

When I started PG I was getting these annoying log errors to stderr, even though I configured file logging in postgresql.conf easily enough:

lorelei-lee-long:~ adric$ LOG: could not bind IPv6 socket: Address already in use HINT: Is another postmaster already running on port 5432? If not, wait a few seconds and retry.

IPv6 is shut the hell off on my system, manually. I know this because I did it (I clicked forcefully) once I found that it was cheerfully turned on and autoconfiguring on every interface under Leopard *cough* which I didn't require or appreciate, thanks. So, that is why it can't bind, but why was it trying? Please note that the server was running fine for me. I checked the config files for a obvious "ipv6 = true" line and didn't find one. One mailing list post suggested that ipv6 was a compile-time option. Figuring that at worst case I could just rebuild without it, I explored that option, but did not find the configure flag to do it. And then I found this post to pgsql-admin.

He suggests that if you aren't running IPv6, you'd better make damn sure pg isn't confused about that, or you will get that message, and commenting out the IPv6 localhost entries in /etc/hosts did the trick.

Now to do something about this LJ's layout... Maybe this is better?

Tags:
Current Location: NOC
Current Music: 久石譲 - Procession Of The Spirits

Leave a comment