pfaffman
(Jay Pfaffman)
1
I’ve got a standard install that is failing to upgrade to 2.8.0.beta2 with this error:
PG::UniqueViolation: ERROR: could not create unique index "unique_post_links_ccnew"
it’s from
I, [2021-06-25T18:35:47.756688 #1] INFO -- : == 20210525112226 RemoveLengthConstrainFromTopicLinkUrl: migrating ============
It doesn’t look like a corrupt index.
Does this help?
[6] pry(main)> TopicLink.where(url: bad_url).pluck(:id, :topic_id, :post_id, :user_id)
=> [[15733, 14351, 63616, 911], [16131, 14505, 63986, 911], [27141, 14505, 63986, 1152]]
I ended up just appending a badX to the duplicate URLs and then it worked. I’m not quite clear what problems this might generate in the future…
我々の経験では、古いバージョンのPostgresには、いわゆる「不可能」なインデックス破損バグが多くありました。あなたはまだこれを見ていますか?
「いいね!」 1
pfaffman
(Jay Pfaffman)
3
pg12にアップグレードしてから見ていないと思います。
「いいね!」 1
PG13 まで行きましたが、それが(インデックスの破損)問題をほぼ解決したと思います。@sam さん、そうですよね?
「いいね!」 2
sam
(Sam Saffron)
5
@saj がこの問題を突き止めました。インフラで解決しました。ほとんどのセルフホスティングユーザーはすでに回避策を見つけています。
過去にオープンソースイメージの PG をアップグレードするために使用したメカニズムには、PG のバージョン間で libc が内部的に変更されるために、固有の安全上の問題がありました。
この問題は、より広範なエコシステムではほとんど解消されたと思いますが、古いアップグレードではまだ直面する可能性があります。既存のオープンソースアップグレードスクリプトを修正し、PG アップグレードの膨大なマトリックスに対処するのは悪夢となるでしょう。
とはいえ、少なくとも問題の原因は現在非常によく認識されており、今後それに対処する準備が整っています。
「いいね!」 2
system
(system)
クローズされました:
6
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.