unable to create user postgres: role “postgres” does not exists

狂风中的少年 提交于 2019-12-03 11:36:52

Turns out i had installed postgres-xc and postgresql on my machine. I had to knock off postgres-xc completely. And it was a little difficult to do that because, there was always an error --purge remove postgres-xc and the uninstallation could not continue.

There seems to be some kind of a packaging bug. (details on launchpad).

Eventually, i ended up doing this to make it work.

After that i uninstalled postgresql and installed it back to make it work.

Read postgresql tutorial it doesn't matter if it's Ubuntu or other Linux.

EDIT before creating role or anything else on fresh install you need to create database cluster: have you created it?

initdb -D /usr/local/pgsql/data

You need to be logged as user postgres on linux machine. Here is more info.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!