当前位置:   article > 正文

psql: FATAL: role “postgres“ does not exist_psql: error: fatal: role "postgres" does not exist

psql: error: fatal: role "postgres" does not exist

1.如果你当前用户是postgres,运行createuser -s postgres则会报错

createuser: could not connect to database postgres: FATAL:  role "postgres" does not exist

2.切换到其他用户,比如 su apps

3.再次运行 createuser -s postgres 则不会报错啦!

4.psql -U postgres -d postgres -h 127.0.0.1 -p 5432 这样就OK啦,

5.记住一定要切换用户之后,再去createuser -s postgres,不然这句也会报错。

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/笔触狂放9/article/detail/913927
推荐阅读
相关标签
  

闽ICP备14008679号