-2

Я использую ноутбук с Windows 8 в качестве сервера разработки.

Я пытаюсь установить postgres на свой ноутбук, но получаю следующую ошибку:

Проблема с запуском шага после установки. Установка может не завершиться правильно. Сбой инициализации кластера базы данных.

Вот видео моих усилий (извините за ужасное качество, я до сих пор не использовал программное обеспечение для захвата экрана):

http://youtu.be/LwhqCXiji8E

Установочный файл:

fixing permissions on existing directory C:/postgres/data ... ok
creating subdirectories ... ok
selecting default max_connections ... The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
10
selecting default shared_buffers ... The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
400kB
creating configuration files ... ok
creating template1 database in C:/postgres/data/base/1 ... The system cannot find the path specified.
child process exited with exit code 1
initdb: removing contents of data directory "C:/postgres/data"

Called Die(Failed to initialise the database cluster with initdb)...
Failed to initialise the database cluster with initdb

Script stderr:
 Program ended with an error exit code

Error running cscript //NoLogo "C:\postgres/installer/server/initcluster.vbs" "NT AUTHORITY\NetworkService" "postgres" "****" "C:\postgres" "C:\postgres\data" 5432 "DEFAULT" 0 : Program ended with an error exit code
Problem running post-install step. Installation may not complete correctly
 The database cluster initialisation failed.

1 ответ1

0

с http://www.windows-commandline.com/add-user-to-group-from-command-line/

Solution:
- Uninstall PostgreSQL
- net user postgres /delete
- Control Panel -> User Accounts -> Configure advanced user profile properties -> delete all "Unknown User" instances that seem to be left from postgres
- compmgmt.msc -> Local Users and Groups -> Users -> New User... -> User name: postgres, Password: postgrespass -> Create
- compmgmt.msc -> Local Users and Groups -> Users -> postgres -> Member of -> Add... -> Administrators -> OK
- copy postgresql-8.4.9-1-windows.exe to C:\
- runas /user:postgres cmd.exe -> cd \ -> postgresql-8.4.9-1-windows.exe -> installed successfully without errors. Checked data folder and confirmed files created successfully.
- compmgmt.msc -> Local Users and Groups -> Users -> postgres -> Member of -> Administrators -> Remove
- compmgmt.msc -> Local Users and Groups -> Users -> postgres -> Member of -> Add... -> Power Users -> OK
- Installed HM2 -> created db successfully
- Restarted computer -> HM2 runs properly (i.e. just to check postgresql service starts automatically)

Всё ещё ищете ответ? Посмотрите другие вопросы с метками .