Results 1 to 3 of 3
  1. #1
    Join Date
    Jun 2015
    Posts
    4

    Unanswered: Starting Postgres Server

    I've had no luck in starting the postgres server. I can add new databases, tables, etc to the postgres, but can't add things to the tables through a webpage. The webpage is running on a localhost for now. The data folder was originally created in a root user, but I moved it to my own user account and it solved many problems, but I'm back at the same old error I keep getting after entering 'postgres -D data' (data being the data cluster folder)

    Code:
    EDT LOG:  could not bind IPv4 socket: Address already in use
    2015-06-18 11:11:35 EDT HINT:  Is another postmaster already running on port 5432? If not, wait a few seconds and retry.
    2015-06-18 11:11:35 EDT LOG:  could not bind IPv6 socket: Address already in use
    2015-06-18 11:11:35 EDT HINT:  Is another postmaster already running on port 5432? If not, wait a few seconds and retry.
    2015-06-18 11:11:35 EDT WARNING:  could not create listen socket for "*"
    2015-06-18 11:11:35 EDT FATAL:  could not create any TCP/IP sockets
    Update:
    I tried two different commands to start the server.
    Code:
    pg_ctl -D data -l logfile start
    
    and
    
    pg_ctl -D /Library/PostgreSQL/9.4/data -l logfile start
    resulting in:
    Code:
    server starting
    
    and
    
    LOG:  skipping missing configuration file "/Library/PostgreSQL/9.4/data/postgresql.auto.conf"
    pg_ctl: another server might be running; trying to start server anyway
    server starting
    The postgresql.auto.conf file is most definitely there with correct name and everything. If I try to stop the supposedly started server it results in this:
    Code:
    Is server running?
    
    and
    
    LOG:  skipping missing configuration file "/Library/PostgreSQL/9.4/data/postgresql.auto.conf"
    pg_ctl: could not send stop signal (PID: 83): Operation not permitted
    Last edited by toast9; 06-18-15 at 15:51.

  2. #2
    Join Date
    Feb 2015
    Posts
    1
    try to start server in another port and post the results.

  3. #3
    Join Date
    Jun 2015
    Posts
    4
    Using the command
    Code:
    sudo lsof -i :5432
    it shows that postgres is running on port 5432.

    Code:
    COMMAND  PID     USER   FD   TYPE             DEVICE SIZE/OFF NODE NAME
    postgres  83 postgres    4u  IPv6 0x261d777f749af8e3      0t0  TCP *:postgresql (LISTEN)
    postgres  83 postgres    5u  IPv4 0x261d777f769f7233      0t0  TCP *:postgresql (LISTEN)
    Although I'm not sure whey there are two postgres showing. Interestingly if I use
    Code:
    pg_ctl -D data status
    it says
    Code:
    pg_ctl: no server running
    The data cluster being used must be somewhere else, but I can't seem to find it.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •