Re: pg_upgrade to 15 fails on Windows because of xml_is_well_formed()

From: Thomas Kellerer <shammat(at)gmx(dot)net>
To: Postgres General <pgsql-general(at)postgresql(dot)org>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Subject: Re: pg_upgrade to 15 fails on Windows because of xml_is_well_formed()
Date: 2022-10-13 19:45:16
Message-ID: 1ad087a6-30aa-3371-e417-2b47956c6986@gmx.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Tom Lane schrieb am 13.10.2022 um 21:01:
>> When trying pg_upgrade to upgrade Postgres 14 to 15 on Windows 10 this fails with:
>> pg_restore: error: could not execute query: ERROR: could not find function "xml_is_well_formed" in file "c:/Program Files/PostgreSQL/15/lib/pgxml.dll"
>
>> I don't understand why this functions is included in the dump in the first place.
>
> Indeed. No such function should be present in any version of contrib/xml2
> that was ever converted to extension style. Have you never done that
> in this DB?

Hmm, the xml2 extension is not installed in any of those databases.

Most databases were probably migrated over time from 8.4
and I can't rule out that I did install xml2 there at some time
in the past.

I checked pg_proc and it the function was there twice: one in pg_catalog
and one in the public schema.

After manually dropping the function from the public schema, pg_upgrade went through.

It's probably not worth investigating how it got there.

I tried to create and drop the xml2 extension to see if that maybe leaves
the "orphaned" function in the public schema, but I couldn't reproduce it.

Regards
Thomas

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Adrian Klaver 2022-10-13 19:53:24 Re: pg_upgrade to 15 fails on Windows because of xml_is_well_formed()
Previous Message Tom Lane 2022-10-13 19:12:31 Re: Exponentiation confusion