I'm trying to install a PostgreSQL instance after building it from source, but running the
postmaster daemon prior to starting up the database cluster doesn't seem to work. Here's the error message I got when I started it up:
postgres@Home:~$ /usr/local/pgsql/bin/postmaster -D /usr/local/pgsql/data LOG: could not bind IPv4 socket: Address already in use HINT: Is another postmaster already running on port 5432? If not, wait a few seconds and retry. WARNING: could not create listen socket for "localhost" FATAL: could not create any TCP/IP sockets
After googling around, the only result I could find which gave me some hints told me to run the following commands, the output of which follows:
postgres@Home:~$ lsof -i :5432 COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME postgres 1169 postgres 3u IPv4 1998 0t0 TCP localhost:postgresql (LISTEN) postgres@Home:~$ netstat -an|grep :5432 tcp 0 0 127.0.0.1:5432 0.0.0.0:* LISTEN
Which leads me to believe that the connection that the port that the
postmaster daemon is trying to latch onto is, in fact, available. Any ideas on what might be causing it?
And if you're curious, I'm running pgsql 9.2.3. (Also, please move this to Stack Overflow or Programmers if this is the wrong Stack Exchange site to ask this at.)