Re: [ADMIN] pg_upgrade from 9.1.3 to 9.2 failed

From: Rural Hunter <ruralhunter(at)gmail(dot)com>
To: Bruce Momjian <bruce(at)momjian(dot)us>
Cc: Peter Eisentraut <peter_e(at)gmx(dot)net>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Subject: Re: [ADMIN] pg_upgrade from 9.1.3 to 9.2 failed
Date: 2012-09-25 00:41:19
Message-ID: 5060FDAF.8020407@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin pgsql-hackers

于 2012/9/24 22:57, Bruce Momjian 写道:
> On Mon, Sep 24, 2012 at 10:45:34PM +0800, Rural Hunter wrote:
>>> If your operating system locale/encoding names changed after the initdb
>>> of the old cluster, this would not be reflected in template0.
>> No. It's not changed. look at my system settings:
>> LANG=zh_CN.UTF-8
>> $ cat /var/lib/locales/supported.d/local
>> zh_CN.UTF-8 UTF-8
>>
>> I think the problem is on the options when I installed pgsql(both
>> 9.1 and 9.2)
>> Select the locale to be used by the new database cluster.
>>
>> Locale
>>
>> [1] [Default locale]
>> [2] C
>> [3] POSIX
>> [4] zh_CN.utf8
>> [5] zh_HK.utf8
>> [6] zh_SG.utf8
>> [7] zh_TW.utf8
>> Please choose an option [1] : 4
>> I chose 4 instead of 1. I guess the default locale(option 1) is with dash.
> Well, if you run that query on template0 in the old and new cluster, you
> will see something different in the two of them. Could you have used
> default in one and a non-dash in the other.
Yes, that's true. The upgrade is fine with both fresh installs(9.1 and
9.2) with option above(without-dash). The problem only happens when I
inited the 9.2 db with default locale(I guess that one has the dash).
Just wondering why pg installer provides options without dash.
> Did we change the way we
> canonicalize the locale between 9.1 and 9.2?
>
> I can send you a patch to test if the setlocale canonicalization works.
> Can you test it if I send it?
>

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Bruce Momjian 2012-09-25 03:00:17 Re: [ADMIN] pg_upgrade from 9.1.3 to 9.2 failed
Previous Message Greg Williamson 2012-09-24 23:10:19 file descriptors still open to deleted files

Browse pgsql-hackers by date

  From Date Subject
Next Message Stephen Frost 2012-09-25 01:18:00 Re: Doc patch to note which system catalogs have oids
Previous Message Brian Weaver 2012-09-25 00:20:30 Re: Patch: incorrect array offset in backend replication tar header