Thread: Problem with bacula and 8.3/8.4
Hi all, I've tried, in various combinations, bacula (2.4, 3.0) and pgsql 8.4 and 8.3 in an upgrade attempt. Whichever combo I try I get the following error: 19-Aug 02:24 bacula-dir JobId 1951: Fatal error: sql_create.c:789 Fill Path table Query failed: INSERT INTO Path (Path) SELECT a.Path FROM (SELECT DISTINCT Path FROM batch) AS a WHERE NOT EXISTS (SELECT Path FROM Path WHERE Path = a.Path) : ERR=ERROR: array size exceeds the maximum allowed (268435455) Batch is a temp table so I tried bumping temp_buffers up to 268MB but I still got the error. Anything I else I should try before I rollback the upgrade? tia, arturo
On Wed, 2009-08-19 at 08:58 -0400, Arturo Pérez wrote: > 19-Aug 02:24 bacula-dir JobId 1951: Fatal error: sql_create.c:789 > Fill Path table Query failed: INSERT INTO Path (Path) SELECT a.Path > FROM (SELECT DISTINCT Path FROM batch) AS a WHERE NOT EXISTS (SELECT > Path FROM Path WHERE Path = a.Path) : ERR=ERROR: array size exceeds > the maximum allowed (268435455) That's odd. Where's the array? Subqueries shouldn't result in arrays in any way, no? On my Bacula install there are no triggers on the `path' table and it's a very simple table: Table "public.path" Column | Type | Modifiers --------+---------+------------------------------------------------------- pathid | integer | not null default nextval('path_pathid_seq'::regclass) path | text | not null Indexes: "path_pkey" PRIMARY KEY, btree (pathid) "path_name_idx" btree (path) so I'm a bit puzzled. Just to see, try expressing the query in two steps: SELECT path INTO TEMPORARY TABLE batch_path FROM batch GROUP BY path; INSERT INTO Path (Path) SELECT batch_path.Path FROM batch_path AS a WHERE NOT EXISTS (SELECT 1 FROM Path WHERE Path = a.Path); -- Craig Ringer
On Aug 19, 2009, at 10:33 PM, Craig Ringer wrote: > On Wed, 2009-08-19 at 08:58 -0400, Arturo Pérez wrote: > >> 19-Aug 02:24 bacula-dir JobId 1951: Fatal error: sql_create.c:789 >> Fill Path table Query failed: INSERT INTO Path (Path) SELECT a.Path >> FROM (SELECT DISTINCT Path FROM batch) AS a WHERE NOT EXISTS (SELECT >> Path FROM Path WHERE Path = a.Path) : ERR=ERROR: array size exceeds >> the maximum allowed (268435455) > > That's odd. Where's the array? Subqueries shouldn't result in > arrays in > any way, no? > Looks like a bad build so far. I was upgrading to 3.0/8.4 and tried to build everything universal (on Mac) to future-proof the upgrade. I built just a native binary and it seems to work better. -arturo