跳至内容
菜单
此问题已终结
1 回复
8950 查看

Hello folks

I'm running OpenERP version 7.0_20130811_231021-5 on Arch Linux, and the latest system upgrade has replaced Postgresql 9.2 with 9.3. Yes, I should have checked before allowing the upgrade...

I followed the instructions at wiki.archlinux.org/index.php/PostgreSQL#Upgrading_PostgreSQL and all went well until running pg_upgrade. The errors at the end of the log are:

...
pg_restore: creating COMMENT COLUMN "ir_act_server"."expression"
pg_restore: creating COMMENT COLUMN "ir_act_server"."email"
pg_restore: creating COMMENT COLUMN "ir_act_server"."action_id"
pg_restore: creating TABLE ir_act_url
pg_restore: [archiver (db)] Error while PROCESSING TOC:
pg_restore: [archiver (db)] Error from TOC entry 190; 1259 59957 TABLE ir_act_url openerp
pg_restore: [archiver (db)] could not execute query: ERROR:  column "name" in child table must be marked NOT NULL
    Command was:
-- For binary upgrade, must preserve pg_type oid
SELECT binary_upgrade.set_next_pg_type_oid('59959'::pg_catalog.oid);

Any ideas how to mend that? Or do I need to revert to pg 9.2?

cheers

Chris

形象
丢弃
编写者 最佳答案

In the absence of better ideas, I downgraded postgresql to 9.2 like this:

# systemctl stop postgresql
# cd /var/cache/pacman/pkg
# pacman -U postgresql-9.2.4-2-x86_64.pkg.tar.xz postgresql-libs-9.2.4-2-x86_64.pkg.tar.xz

Renamed /var/lib/postgres/data-9.2 back to just data.

# systemctl restart postgresql
Warning: Unit file of postgresql.service changed on disk, 'systemctl daemon-reload' recommended.
# systemctl daemon-reload

Postgresql 9.2 is running, and OpenERP works again.

I've made sure that it won't happen again by adding this line to /etc/pacman.conf:

IgnorePkg = postgresql postgresql-libs
形象
丢弃
相关帖文 回复 查看 活动
6
12月 23
43864
0
2月 25
1390
2
1月 25
7874
2
1月 24
10138
7
1月 24
48802