Pivotal Knowledge Base

Follow

Alter table statement failed with "ERROR: Index 6 exceed size of vpinfo array size 6 (aocssegfiles.h:116)"

Environment

Pivotal Greenplum: 4.3.x

OS: RHEL 6.x

Symptom

When attempting to add a column to an existing table, it failed with error message “ERROR: Index 6 exceed size of vpinfo array size 6 (aocssegfiles.h:116).”

Error Message:

reporting=# alter table visits_industry_weekly add column weighted_page_views FLOAT DEFAULT 0, add column weighted_duration FLOAT DEFAULT 0,add column projected_page_views FLOAT DEFAULT 0, add column projected_duration FLOAT DEFAULT 0; 
ERROR: Index 6 exceed size of vpinfo array size 6 (aocssegfiles.h:116) (seg60 sdw-8:40004 pid=147160) (cdbdisp.c:1326)

Error messages in the segment logs:

2017-06-26 11:34:24.419738 UTC,"gpadmin","reporting",p147160,th1788061472,"172.20.3.170","6012",2017-06-26 11:33:58 UTC,297870358,con901660,cmd4,seg60,,dx21006484,x297870358,sx1,"ERROR","XX000","Index 6 exceed size of vpinfo array size 6 (aocssegfiles.h:116)",,,,,,"alter table visits_industry_weekly add column weighted_page_views FLOAT DEFAULT 0, add column weighted_duration FLOAT DEFAULT 0,add column projected_page_views FLOAT DEFAULT 0, add column projected_duration FLOAT DEFAULT 0;",0,,"../../../src/include/access/aocssegfiles.h",116,"Stack trace:
1 0xb061ba postgres <symbol not found> (elog.c:502)
2 0xb081c8 postgres elog_finish (elog.c:1446)
3 0x70aa16 postgres <symbol not found> (aocssegfiles.h:116)
4 0x71f581 postgres <symbol not found> (tablecmds.c:5358)
5 0x71faf1 postgres AlterTable (tablecmds.c:4001)
6 0x9a5384 postgres ProcessUtility (utility.c:1137)
7 0x9a0ea3 postgres <symbol not found> (pquery.c:1521)
8 0x9a2735 postgres PortalRun (pquery.c:1129)
9 0x99b713 postgres PostgresMain (postgres.c:1365)
10 0x8fa3ee postgres <symbol not found> (postmaster.c:6658)
11 0x8fd170 postgres PostmasterMain (postmaster.c:7589)
12 0x7ff1ef postgres main (main.c:206)
13 0x7f186634fd1d libc.so.6 __libc_start_main (??:0)
14 0x4c4a19 postgres <symbol not found> (??:0)

Cause

The issue is caused due to a software defect which causes a metadata mismatch between pg_class and related relations in the pg_aoseg schema.

Resolution

This issue is fixed in Greenplum release 4.3.14.0 onwards. Upgrade to at least 4.3.14.0 release to pick up the fix.

It can also be worked around with steps below (Suppose the issue is with table "tab1").

  1. Create table tab1_new as select * from tab1
  2. Alter table tab1_new add column ......
  3. Drop table tab1
  4. Alter table tab1_new rename to tab1

 

Comments

Powered by Zendesk