Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 284094 - If listen_address is wrong in config - start script reports generic error
Summary: If listen_address is wrong in config - start script reports generic error
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Unspecified (show other bugs)
Hardware: x86 Linux
: High minor (vote)
Assignee: PgSQL Bugs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-09-08 09:47 UTC by johndoeyu
Modified: 2010-06-04 14:20 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description johndoeyu 2009-09-08 09:47:29 UTC
After changing the IP address of the computer, and forgotten to adjust the listen_address in /var/lib/postgresql/8.3/data/postgresql.conf - postgres naturally failed to start.

But the start script reports some generic error:
# /etc/init.d/postgresql-8.3 start
 * Starting PostgreSQL ...
waiting for server to start...............................................................could not start server                                                                                                                                                       [ !! ]
 * The pid-file doesn't exist but pg_ctl reported a running server.
 * Please check whether there is another server running on the same port or read the log-file.

Reproducible: Always

Steps to Reproduce:
1. change the IP in config file to something different than the IP you are using
2.
3.

Actual Results:  
Generic start message is displayed that postgresql can't start.

Expected Results:  
Display the same error message that is displayed when you manually call /usr/bin/pg_ctl or have the correct error message in /var/log/messages or similar.

If you start manually - the real reason is seen:
(as postgres user)
/usr/bin/pg_ctl start -D /var/lib/postgresql/8.3/data

LOG:  could not bind IPv4 socket: Cannot assign requested address
HINT:  Is another postmaster already running on port 53891? If not, wait a few seconds and retry.
WARNING:  could not create listen socket for "10.0.0.95"
FATAL:  could not create any TCP/IP sockets
Comment 1 Aaron W. Swenson gentoo-dev 2010-03-24 00:07:43 UTC
Addressed in bug #311047
Comment 2 Patrick Lauer gentoo-dev 2010-06-04 14:20:13 UTC
Committed