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. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

On my system, whoami returns Dan. I run initdb with the --username=PgUser argument. Then as OS user Dan I run pg_ctl start on the newly-initialized cluster, and it gives this output:

LOG:  database system was shut down at 2013-06-13 00:54:33 UTC
LOG:  autovacuum launcher started
LOG:  database system is ready to accept connections
FATAL:  role "Dan" does not exist
server started

The server appears to have started up normally. I believe the error occurs because it wants me to run pg_ctl as the OS user named PgUser. What I want to know is:

  • Is that belief correct?
  • Is there a way to specify the user as PgUser without using su? I would prefer not to create a new OS user and would like to use a PostgreSQL user with a different username (I'm doing some code refactoring that makes this more convenient).
  • Is the instance I started crippled in some way because I started it as OS user Dan?
share|improve this question
up vote 2 down vote accepted

This happens when you run pg_ctl start with the -w (wait) option, because it will try a test connection with a user that does not exist (in your case). But that's not really a problem (except for the confusing error message), because that proves that the server is up.

share|improve this answer
Hm-hm, what do you think, is it possible somehow to adjust the error message so that is shows the (non)-severity of the issue? :) – dezso Jun 13 '13 at 19:58
Anything is possible. ;-) Send in a bug. – Peter Eisentraut Jun 13 '13 at 20:42

Your Answer


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

Not the answer you're looking for? Browse other questions tagged or ask your own question.