PSQLException - POSTGRESQL中的会话设置失败

时间:2013-05-24 06:03:44

标签: postgresql openbravo

当我运行ant命令时 - ant compile.complete或ant install.source

我收到了这些错误 -

E:\ source_code \ Openbravo-3.0MP21 \ src-db \ database \ build-create.xml:77:org.postgr esql.util.PSQLException:协议错误。会话设置失败。 在org.postgresql.core.v3.ConnectionFactoryImpl.doAuthentication(Connect ionFactoryImpl.java:407) at org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(Conne ctionFactoryImpl.java:108) 在org.postgresql.core.ConnectionFactory.openConnection(ConnectionFactor y.java:66) 我怎么可以 x这些问题。与Postgresql数据库相关的所有细节都很好 Openbravo.properties文件。

列在异常堆栈跟踪下面。

  

E:\ source_code \ Openbravo-3.0MP21> ant install.source构建文件:   E:\ source_code \ Openbravo的-3.0MP21 \的build.xml

     

set.code.rev:

     

code.rev:

     

INIT:

     

cleanSubfolders:

     

clean:[删除]删除目录   E:\ source_code \ Openbravo-3.0MP21 \ src-core \ build \ c lasses [删除]   删除目录E:\ source_code \ Openbravo-3.0MP21 \ src-core \ docs
  [删除]删除:   E:\ source_code \ Openbravo-3.0MP21 \ src-core \ lib \ openbravo-co re.jar

     

clean:[删除]删除目录   E:\ source_code \ Openbravo-3.0MP21 \ src-trl \ build \ cl asses [delete]   删除目录E:\ source_code \ Openbravo-3.0MP21 \ src-trl \ docs
  [删除]删除目录   E:\ source_code \ Openbravo-3.0MP21 \ src-trl \ build \ ja vasqlc [删除]   删除:E:\ source_code \ Openbravo-3.0MP21 \ src-trl \ lib \ openbravo-trl   的.jar

     

clean:[删除]删除目录   E:\ source_code \ Openbravo-3.0MP21 \ src-wad \ build \ cl asses [delete]   删除目录E:\ source_code \ Openbravo-3.0MP21 \ src-wad \ build \ ja   vasqlc [删除]删除目录   E:\ source_code \ Openbravo-3.0MP21 \ src-wad \ docs [删除]删除:   E:\ source_code \ Openbravo-3.0MP21 \ src-wad \ lib \ openbravo-wad .jar

     

core.lib:

     

INIT:       [mkdir]创建目录:E:\ source_code \ Openbravo-3.0MP21 \ src-core \ build \ classes

[mkdir] Created dir: E:\source_code\Openbravo-3.0MP21\src-core\docs
     

编译:       [javac]将124个源文件编译为E:\ source_code \ Openbravo-3.0MP21 \ src -c ore \ build \ classes       [javac] E:\ source_code \ Openbravo-3.0MP21 \ src-core \ src \ org \ openbravo \ utils \ Fo   rmatUtilities.java:31:警告:编码的不可映射字符   UTF-8       [javac]返回strIni.replace('?',' a')。替换('?',' e')。替换('?',' i')。替换('?',' o')       [javac] ^       [javac] E:\ source_code \ Openbravo-3.0MP21 \ src-core \ src \ org \ openbravo \ utils \ Fo   rmatUtilities.java:31:警告:编码的不可映射字符   UTF-8       [javac]返回strIni.replace('?',' a')。替换('?',' e')。替换('?',' i')。替换('?',' o')       [javac] ^       [javac] E:\ source_code \ Openbravo-3.0MP21 \ src-core \ src \ org \ openbravo \ utils \ Fo   rmatUtilities.java:31:警告:编码的不可映射字符   UTF-8       [javac]返回strIni.replace('?',' a')。替换('?',' e')。替换('?',' i')。替换('?',' o')       [javac] ^       [javac] E:\ source_code \ Openbravo-3.0MP21 \ src-core \ src \ org \ openbravo \ utils \ Fo   rmatUtilities.java:31:警告:编码的不可映射字符   UTF-8       [javac]返回strIni.replace('?',' a')。替换('?',' e')。替换('?',' i')。替换('?',' o')       [javac的]                ^       [javac] E:\ source_code \ Openbravo-3.0MP21 \ src-core \ src \ org \ openbravo \ utils \ Fo   rmatUtilities.java:32:警告:编码的不可映射字符   UTF-8       [javac] .replace('?',' u')。替换('?',' A')。替换( '?',' E')。替换('?','我')。替换(&#39 ;? ',' O')       [javac] ^       [javac] E:\ source_code \ Openbravo-3.0MP21 \ src-core \ src \ org \ openbravo \ utils \ Fo   rmatUtilities.java:32:警告:编码的不可映射字符   UTF-8       [javac] .replace('?',' u')。替换('?',' A')。替换( '?',' E')。替换('?','我')。替换(&#39 ;? ',' O')       [javac] ^       [javac] E:\ source_code \ Openbravo-3.0MP21 \ src-core \ src \ org \ openbravo \ utils \ Fo   rmatUtilities.java:32:警告:编码的不可映射字符   UTF-8       [javac] .replace('?',' u')。替换('?',' A')。替换( '?',' E')。替换('?','我')。替换(&#39 ;? ',' O')       [javac] ^       [javac] E:\ source_code \ Openbravo-3.0MP21 \ src-core \ src \ org \ openbravo \ utils \ Fo   rmatUtilities.java:32:警告:编码的不可映射字符   UTF-8       [javac] .replace('?',' u')。替换('?',' A')。替换( '?',' E')。替换('?','我')。替换(&#39 ;? ',' O')       [javac的]       ^       [javac] E:\ source_code \ Openbravo-3.0MP21 \ src-core \ src \ org \ openbravo \ utils \ Fo   rmatUtilities.java:32:警告:编码的不可映射字符   UTF-8       [javac] .replace('?',' u')。替换('?',' A')。替换( '?',' E')。替换('?','我')。替换(&#39 ;? ',' O')       [javac的]                         ^       [javac] E:\ source_code \ Openbravo-3.0MP21 \ src-core \ src \ org \ openbravo \ utils \ Fo   rmatUtilities.java:33:警告:编码的不可映射字符   UTF-8       [javac] .replace('?',' U');       [javac] ^       [javac] 10次警告

     

build.jar中:         [jar]构建jar:E:\ source_code \ Openbravo-3.0MP21 \ src-core \ lib \ openbrav o-core.jar

     

构建

     

copy.core.lib:        [copy]将1个文件复制到E:\ source_code \ Openbravo-3.0MP21 \ lib \ runtime

     

database.lib:

     

INIT:

     

编译:

     

build.jar中:         [jar]构建jar:E:\ source_code \ Openbravo-3.0MP21 \ src-db \ build \ lib \ dbma nager.jar

     

罐:        [copy]将1个文件复制到E:\ source_code \ Openbravo-3.0MP21 \ src-db \ database \ l ib

     

create.database:

     

create.database:

     

clean.database.POSTGRE:

     

BUILD FAILED E:\ source_code \ Openbravo-3.0MP21 \ build.xml:728:The   执行此行时发生以下错误:   E:\ source_code \ Openbravo的-3.0MP21 \ SRC-DB \数据库\集结create.xml:50:   执行此行时发生以下错误:   E:\ source_code \ Openbravo的-3.0MP21 \ SRC-DB \数据库\集结create.xml:77:   org.postgr esql.util.PSQLException:协议错误。会话设置   失败。           在org.postgresql.core.v3.ConnectionFactoryImpl.doAuthentication(Connect   ionFactoryImpl.java:407)           at org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(Conne   ctionFactoryImpl.java:108)           在org.postgresql.core.ConnectionFactory.openConnection(ConnectionFactor   y.java:66)           at org.postgresql.jdbc2.AbstractJdbc2Connection。(AbstractJdbc2Conn)   ection.java:125)           at org.postgresql.jdbc3.AbstractJdbc3Connection。(AbstractJdbc3Conn)   ection.java:30)           at org.postgresql.jdbc3g.AbstractJdbc3gConnection。(AbstractJdbc3gC   onnection.java:22)           at org.postgresql.jdbc4.AbstractJdbc4Connection。(AbstractJdbc4Conn)   ection.java:30)           在org.postgresql.jdbc4.Jdbc4Connection。(Jdbc4Connection.java:24)           在org.postgresql.Driver.makeConnection(Driver.java:393)           在org.postgresql.Driver.connect(Driver.java:267)           at org.apache.tools.ant.taskdefs.JDBCTask.getConnection(JDBCTask.java:37   0)           在org.apache.tools.ant.taskdefs.SQLExec.getConnection(SQLExec.java:940)

    at org.apache.tools.ant.taskdefs.SQLExec.execute(SQLExec.java:612)
    at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
    at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
     

sorImpl.java:25)           在java.lang.reflect.Method.invoke(Method.java:597)           在org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.jav)   一:106)           at org.apache.tools.ant.Task.perform(Task.java:348)           在org.apache.tools.ant.Target.execute(Target.java:435)           在org.apache.tools.ant.Target.performTasks(Target.java:456)           在org.apache.tools.ant.Project.executeSortedTargets(Project.java:1393)           在org.apache.tools.ant.helper.SingleCheckExecutor.executeTargets(单   CheckExecutor.java:38)           在org.apache.tools.ant.Project.executeTargets(Project.java:1248)           在org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:440)           在org.apache.tools.ant.taskdefs.CallTarget.execute(CallTarget.java:105)

    at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
    at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
     

sorImpl.java:25)           在java.lang.reflect.Method.invoke(Method.java:597)           在org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.jav)   一:106)           at org.apache.tools.ant.Task.perform(Task.java:348)           在org.apache.tools.ant.Target.execute(Target.java:435)           在org.apache.tools.ant.Target.performTasks(Target.java:456)           在org.apache.tools.ant.Project.executeSortedTargets(Project.java:1393)           在org.apache.tools.ant.helper.SingleCheckExecutor.executeTargets(单   CheckExecutor.java:38)           在org.apache.tools.ant.Project.executeTargets(Project.java:1248)           在org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:440)           在org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)           at sun.reflect.GeneratedMethodAccessor4.invoke(未知来源)           at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces   sorImpl.java:25)           在java.lang.reflect.Method.invoke(Method.java:597)           在org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.jav)   一:106)           at org.apache.tools.ant.Task.perform(Task.java:348)           在org.apache.tools.ant.Target.execute(Target.java:435)           在org.apache.tools.ant.Target.performTasks(Target.java:456)           在org.apache.tools.ant.Project.executeSortedTargets(Project.java:1393)           在org.apache.tools.ant.Project.executeTarget(Project.java:1364)           at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExe)   cutor.java:41)           在org.apache.tools.ant.Project.executeTargets(Project.java:1248)           在org.apache.tools.ant.Main.runBuild(Main.java:851)           在org.apache.tools.ant.Main.startAnt(Main.java:235)           在org.apache.tools.ant.launch.Launcher.run(Launcher.java:280)           在org.apache.tools.ant.launch.Launcher.main(Launcher.java:109)

     

总时间:5秒

任何人都将不胜感激。谢谢!

1 个答案:

答案 0 :(得分:1)

尝试重新启动postgresql服务,然后尝试install.source ..

在Windows中:

服务 - > postgresql 9.0 - >停下来开始。