Re: invalid memory alloc request size

From: Janning Vygen <vygen(at)gmx(dot)de>
To: pgsql-general(at)postgresql(dot)org
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Subject: Re: invalid memory alloc request size
Date: 2006-01-23 20:45:51
Message-ID: 200601232145.51966.vygen@gmx.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

TOM! Ich will ein Kind von Dir!!
(it means 'something like': thank you so much. you just saved my life!)

Am Montag, 23. Januar 2006 21:16 schrieb Tom Lane:
> Janning Vygen <vygen(at)gmx(dot)de> writes:
> >> OK, what's the schema of this table exactly?
> >
> > ...
> > Regeln:
> > cache_stip_delete AS
> > ON DELETE TO spieletipps DO UPDATE tsptcache SET tc_cache = -2
>> [...]
>
> Oh, I should have thought of that: the bare DELETE operation doesn't
> care what's in the tuple, but this ON DELETE rule sure does. That's
> why the delete crashes, it's trying to extract the field contents so
> it can execute the rule.

I dropped the rule and deleted the row successfully with the ctid. Thanks a
lot for the great support! This problem will be my first article in my
PostgreSQL Troubleshooting Guide for Dummies. "We" really need it for guys
like me.

> > yes, they should both be "alteheide". Is it possible to open the file and
> > just fix the bit?
>
> Yeah, if you have a suitable hex editor. You'll probably need to shut
> down the postmaster first, as it may have a cached copy of the page.

i decided not to poke to postgres internal file storage.

> > I have no clue, why it happens. But i changed my schema a few month
> > ago to use a materialized view (You see all the rules in this schema
> > above). i need some complicated ranking algorithm to calculate the
> > materialzed view. everything is implemented inside postgresql with
> > rules and functions (pgperl and plpgsql). One more aspect are temp
> > tables to me. I use lots of them for a specific tasks (reusing the
> > calculating algorithm mentioned above for a different data view). With
> > lots of temp tables i got problems with pg_type where some old temp
> > values reside and i got to delete some of them manually a few times
> > per month.
>
> Hmm ... the one part of that that jumps out at me is plperl. We already
> know that plperl can screw up the locale settings; I wonder whether
> there are other bugs. Anyway, if you are using plperl I *strongly*
> recommend updating to the latest PG release ASAP (8.0.6 in your case).

ok, shouldn't i upgrade to 8.1 instead of 8.0.6 if i can?

> If you cannot, at least make sure the postmaster is launched with the
> same LC_XXX settings in its environment as are embedded in the database.

i will look at it!

kind regards
janning

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2006-01-23 20:57:07 Re: invalid memory alloc request size
Previous Message Rick Gigger 2006-01-23 20:37:32 Re: Linux - postgres RAID