微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

postgresql server start and then immediately stop


I had the same issue installing 9.1.4 on Windows 7. I managed to find a solution online that worked.

The steps I followed are:

  1. Uninstall Postgresql
  2. Delete the postgres user if it still exists.

    net user postgres /delete
  3. Create the postgres user with a password you can remember

    net user /add postgres <password>
  4. Add the postgres user to the Administrators group

    net localgroup administrators postgres /add
  5. Add the postgres user to the Power Users group

    net localgroup "power users" postgres /add
  6. Run a command window as the postgres user

    runas /user:postgres cmd.exe
  7. Run the install file from within the command window.

    C:\Download\postgresql-9.1.4-1-windows.exe

    This should run the installation successfully.

  8. Remove the postgres user from the Administrators group.

    net localgroup administrators postgres /delete

 源链接https://dba.stackexchange.com/questions/10241/postgresql-the-database-cluster-initialization-Failed

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 [email protected] 举报,一经查实,本站将立刻删除。

相关推荐