安装PostgreSQL 9.2的问题 [英] Problems Installing PostgreSQL 9.2

查看:180
本文介绍了安装PostgreSQL 9.2的问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在尝试在计算机上安装64位版本的Windows的PostgreSQL PostgreSQL 9.2(Windows 7 64位)并收到此错误:



环境变量COMPSPEC似乎没有指向cmd.exe或存在尾随的半冒号。



我已经



我禁用了防病毒软件(Microsoft Security Essentials)和防火墙。



运行:

 %COMSPEC% / C回声测试正常 

返回测试正常



我已经检查了我的系统环境变量用于结尾的半冒号,但我找不到。



然后我安装了32位版本,并设法以另一种方式结束安装错误消息指出:安装后步骤运行问题。安装可能无法正确完成读取C:\\ Program Files(x86)\\ PostgreSQL \\ 9.2 \\ data \\ postgresql.conf 时出错,但是没有 postgresql。 conf 该目录中的文件。它确实安装了该应用程序,当我尝试用红色X连接服务器时,它说在底部失败,并且在我输入密码后无法连接。



如何连接到该服务器连接?

解决方案

ComSpec是有关任何安装失败的通用错误消息。

p>

确定问题


  1. 导航至以下路径
    c:\用户\XXXXXX\AppData\Local\Temp

  2. 打开'bitrock_installer_XXXX.log'

  3. 检查是否出现以下错误:




脚本标准错误:
' C:\Users\XXXXX\AppData\ \Local\Temp\POSTGR〜1\TEMP_C〜1.BAT'不被识别为内部或外部命令,可操作程序或批处理文件。



运行错误



C:\Users\XXXXX\AppData\Local\Temp / postgresql_installer_47b21c4ea1 / temp_check_comspec.bat:

' C:\Users\XXXXX\AppData\

可运行的程序或批处理文件。

不能将Local\Temp\POSTGR〜1\TEMP_C〜1.BAT'识别为内部或外部命令。 / p>

这是' 8.3文件名和目录'(例如'\Postgres安装'->'\POSTGR〜1')
有关禁用8.3文件名和目录的Microsoft文章: https://support.microsoft.com/zh-CN/kb/121007



解决方案:




  1. 在管理模式下打开命令提示符

  2. 执行以下命令以根据驱动器更改格式或所有驱动器



    示例命令:

      fsutil 8dot3name set 1 -在所有卷上禁用8dot3名称创建
    fsutil 8dot3name set C:1-在c上禁用8dot3名称创建:


  3. 以具有管理员特权的用户身份执行安装


  4. 安装后,请考虑将8dot3name设置重置为默认值(2),以避免意外的后果

希望它可以解决问题!


I've been trying to install the 64bit version of PostgreSQL 9.2 for Windows on my machine (Windows 7 64bit) and get this error:

The environment variable COMPSPEC does not seem to point to the cmd.exe or there is a trailing semi colon present.

I've installed it as Administrator.

I disabled the antivirus (Microsoft Security Essentials) and the firewall.

Running:

"%COMSPEC%" /C "echo test ok"

returned test ok

I've checked my System Environment Variables for trailing semi colon and I couldn't find any.

I then installed the 32bit version and managed to get to the end of the install with a different error message stating: Problem running post-install step. Installation may not complete correctly Error reading the C:\Program Files (x86)\PostgreSQL\9.2\data\postgresql.conf but there is no postgresql.conf file in that directory. It did install the application and when I try to connect the server with the red X on it it says fail at the bottom and it won't connect after I type in my password.

How can I connect to this server connection?

解决方案

ComSpec is a generic error message for any installation failure.

Identifying the problem

  1. Navigate to below path c:\Users\XXXXXX\AppData\Local\Temp
  2. Open 'bitrock_installer_XXXX.log'
  3. Check, if you are getting below error:

Script stderr: '"C:\Users\XXXXX\AppData\Local\Temp\POSTGR~1\TEMP_C~1.BAT"' is not recognized as an internal or external command, operable program or batch file.

Error running

C:\Users\XXXXX\AppData\Local\Temp/postgresql_installer_47b21c4ea1/temp_check_comspec.bat :
'"C:\Users\XXXXX\AppData\Local\Temp\POSTGR~1\TEMP_C~1.BAT"' is not recognized as an internal or external command,

operable program or batch file.

This is a problem with '8.3 file names and directories' (e.g. '\Postgres Install' -> '\POSTGR~1') Microsoft article on disabling 8.3 file names and directories: https://support.microsoft.com/en-gb/kb/121007

Solution:

  1. Open command prompt in admin mode
  2. Execute following command to change the format based on your drive or all drives

    Sample commands:

    fsutil 8dot3name set 1"      - disable 8dot3 name creation on all volumes
    fsutil 8dot3name set C: 1"   - disable 8dot3 name creation on c:
    

  3. Execute the installation as a user having admin privileges

  4. After install, consider resetting the 8dot3name setting to default (2) to avoid unintended consequences

Hope it solves the problem!

这篇关于安装PostgreSQL 9.2的问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆