我一直在試圖安裝PostgreSQL 9.2的最後幾天。我想我嘗試了一切,我可以在網上找到,但該服務仍然無法啓動。我目前正在運行Windows 7 SP1。我曾經安裝過PostgreSQL 8.3並且工作正常,但幾個星期前我決定卸載它。我徹底卸載了它(刪除postgres用戶和數據文件),現在每次嘗試安裝任何版本時,都會在加載數據庫模塊時發生此安裝結束時的非致命錯誤。 我設法看到postgresql服務沒有啓動,或者當windows啓動然後停止。 這是安裝日誌文件的相關部分:Postgresql未能安裝正確
成功處理了771個文件;處理失敗0個文件
initcluster.vbs運行完成
腳本標準錯誤:
Configuring database server startup... Executing cscript //NoLogo "C:\Program Files (x86)\PostgreSQL\9.2\installer\server\startupcfg.vbs" 9.2 "NT AUTHORITY\NetworkService" "****" "C:\Program Files (x86)\PostgreSQL\9.2" "C:\Program Files (x86)\PostgreSQL\9.2\data" "postgresql-9.2" Script exit code: 0 Script output: startupcfg.vbs ran to completion Script stderr: Creating menu shortcuts... Executing cscript //NoLogo "C:\Program Files (x86)\PostgreSQL\9.2\installer\server\createshortcuts.vbs" 9.2 "postgres" 5432 "PostgreSQL 9.2 (x86)" "C:\Program Files (x86)\PostgreSQL\9.2" "C:\Program Files (x86)\PostgreSQL\9.2\data" "postgresql-9.2" Script exit code: 0 Script output: Start FixupFile(C:\Program Files (x86)\PostgreSQL\9.2\scripts\serverctl.vbs)... Opening file for reading... Closing file (reading)... Replacing placeholders... Opening file for writing... Closing file... End FixupFile()... Start FixupFile(C:\Program Files (x86)\PostgreSQL\9.2\scripts\runpsql.bat)... Opening file for reading... Closing file (reading)... Replacing placeholders... Opening file for writing... Closing file... End FixupFile()... createshortcuts.vbs ran to completion Script stderr: Starting the database server... Executing cscript //NoLogo "C:\Program Files (x86)\PostgreSQL\9.2\installer\server\startserver.vbs" postgresql-9.2 Script exit code: 0 Script output: Starting postgresql-9.2 Service postgresql-9.2 started successfully startserver.vbs ran to completion Script stderr: Loading additional SQL modules... Executing cscript //NoLogo "C:\Program Files (x86)\PostgreSQL\9.2\installer\server\loadmodules.vbs" "postgres" "****" "C:\Program Files (x86)\PostgreSQL\9.2" "C:\Program Files (x86)\PostgreSQL\9.2\data" 5432 Script exit code: 2 Script output: Installing the adminpack module in the postgres database... Executing 'C:\Users\George\AppData\Local\Temp\radA5996.bat'... psql: server closed the connection unexpectedly This probably means the server terminated abnormally before or while processing the request. Failed to install the 'adminpack' module in the 'postgres' database loadmodules.vbs ran to completion Script stderr: Program ended with an error exit code Error running cscript //NoLogo "C:\Program Files (x86)\PostgreSQL\9.2\installer\server\loadmodules.vbs" "postgres" "****" "C:\Program Files (x86)\PostgreSQL\9.2" "C:\Program Files (x86)\PostgreSQL\9.2\data" 5432 : Program ended with an error exit code [10:34:28] Write the data directory to the ini file... [10:34:28] Write the port number, service ID, locale and superuser to the ini file... [10:34:28] Write ServiceID(postgresql-9.2) to registry/ini... [10:34:28] Write Superuser to ini file and windows registry... [10:34:28] Write Service Account to ini file and windows registry... [10:34:28] Write the server description to the ini file... [10:34:28] Write the server branding to the ini file... [10:34:28] Write the 'whether stack-builder is disabled or not' to the ini file... [10:34:29] Finished running post-installation/upgrade tasks. Creating Uninstaller Creating uninstaller 25% Creating uninstaller 50% Creating uninstaller 75% Creating uninstaller 100% Installation completed
快速嘗試安裝9.1的副本 - 如果有效,那麼問題出現在9.2的安裝程序中。如果沒有,則表明您的設置上存在干擾。確保任何防病毒設置爲忽略PostgreSQL的目錄和進程。還值得檢查,看看服務器啓動時是否留下了任何日誌消息。 (P.S.感謝發佈安裝程序日誌的相關位 - 讓每個人的生活更輕鬆) –
不會更適合serverfault嗎? – didierc