【发布时间】:2012-05-08 01:04:17
【问题描述】:
我正在尝试为我的 Greenplum 数据库 4.2.1.0 安装 Postgresql (8.2.15) additional supplied modules intarray 和 intagg。安装似乎成功;我按照教程here 将所有文件复制到greenplumlib-db-4.2.1.0/lib/postgresql share/postgresql 目录中。但是当我尝试执行我的 java 代码时,它会抛出一个“未定义的符号”错误:
org.postgresql.util.PSQLException: ERROR: could not load library "/usr/local/greenplum-db-4.2.1.0/lib/postgresql/_int.so": /usr/local/greenplum-db-4.2.1.0/lib/postgresql/_int.so: undefined symbol: pfree
at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2062)
at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1795)
at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:257)
at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:479)
at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:353)
at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:345)
at tuffy.db.RDB.execute(RDB.java:354)
at tuffy.db.RDB.resetSchema(RDB.java:700)
at felix.main.Felix.parseFelixQuery(Felix.java:106)
at felix.main.Felix.run(Felix.java:755)
at felix.main.Main.main(Main.java:69)
表示符号 pfree 未定义。我检查了版本号:Greenplum 中的 postgresql 和附加模块都是 8.2.15。我错过了什么吗?
更新:教程链接似乎不稳定;它基本上提供了一些简单的步骤来完成安装:
Get any of the postgresql 8.2 source package from the official site
su - gpadmin
Unpack the source, then go to ~/postgresql-8.2.xx/contrib/xxx
make USE_PGXS=1 COPT="-Wno-error" install
(Optional for Greenplum MPP) Use gpssh to copy whatever .so file that just get installed under /usr/local/greenplum-db/lib/postgresql to other nodes
psql -f xxx.sql [DBNAME]
更新: 谢谢您的回答。
我正在安装Greenplum,但它只包含postgresql 8.2.15,所以我必须使用这个版本。我已将整个 /usr/local/pgsql/lib 目录复制到 greenplum 库中,似乎使 intarray 可以工作,但现在我有一个新错误:
could not load library "/usr/local/greenplum-db-4.2.1.0/lib/postgresql/plpgsql.so":
/usr/local/greenplum-db-4.2.1.0/lib/postgresql/plpgsql.so: undefined symbol: heap_copytuple
我好像遗漏了一些文件...
谢谢!
【问题讨论】:
-
就扩展名而言,你从哪里下载的究竟是什么?
标签: postgresql greenplum