![]() ![]() What I have triedĪmong other similar commands, for me all these commands failed: createuser -s I am adding an answer for a case I have not seen here, which is an edge case if you have multiple users on the same machine and the user who is trying to use postgres services is not the user who installed postgres on the machine. If user is really the DB superuser you can create another DB superuser and a private, empty database for him: CREATE USER postgres SUPERUSER ĬREATE DATABASE postgres WITH OWNER postgres īut since your postgres.app setup does not seem to do this, you also should not. So you could try this command to login: sudo -u user psql user So I think your setup simple uses user as the superuser. And looking at the output of your \l command: The permissions for user on the template0 and template1 databases are the same as on my Ubuntu system for the superuser postgres. ![]() If there is one, you can use that to login. If there is not at least one role with superuser, then you have a problem :-) Postgres | Superuser, Create role, Create DB | Later in the login process it might also stumble over the missing database.īut the first step is to check the missing role: What is the output within psql of the command \du ? On my Ubuntu system the relevant line looks like this: List of roles Note that the error message does NOT talk about a missing database, it talks about a missing role. ![]() NOTE: If you installed postgres using homebrew, see the comment from below. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |