
저는 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
~에서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)