DB移行でRebuild Upgradeが失敗する(Postgresの問題?)

皆さん、

データベース移行の問題で再構築が失敗しています。数年間、このインストールで継続的に再構築を行ってきましたが、何かが古すぎるのでしょうか?

ビルドログの末尾から情報を抽出できるか、それとももっと前の情報が必要か、教えていただけますでしょうか?

ご協力ありがとうございます!

I, [2022-11-30T10:15:55.248687 #1]  INFO -- : cd /var/www/discourse & su discourse -c 'bundle exec rake db:migrate'
rake aborted!
[discourse-signatures] Handlebars templates can no longer be included via `register_asset`.
Any hbs files under `assets/javascripts` will be automatically compiled and included."
/var/www/discourse/lib/plugin/instance.rb:590:in `register_asset'
/var/www/discourse/plugins/discourse-signatures/plugin.rb:48:in `activate!'
/var/www/discourse/lib/plugin/instance.rb:677:in `instance_eval'
/var/www/discourse/lib/plugin/instance.rb:677:in `activate!'
/var/www/discourse/lib/discourse.rb:314:in `block in activate_plugins!'
/var/www/discourse/lib/discourse.rb:311:in `each'
/var/www/discourse/lib/discourse.rb:311:in `activate_plugins!'
/var/www/discourse/config/application.rb:212:in `block in <class:Application>'
/var/www/discourse/lib/plugin.rb:6:in `initialization_guard'
/var/www/discourse/config/application.rb:211:in `<class:Application>'
/var/www/discourse/config/application.rb:82:in `<module:Discourse>'
/var/www/discourse/config/application.rb:81:in `<top (required)>'
/var/www/discourse/Rakefile:7:in `require'
/var/www/discourse/Rakefile:7:in `<top (required)>'
/var/www/discourse/vendor/bundle/ruby/2.7.0/gems/rake-13.0.6/exe/rake:27:in `<top (required)>'
/usr/local/bin/bundle:25:in `load'
/usr/local/bin/bundle:25:in `<main>'
(See full trace by running task with --trace)
I, [2022-11-30T10:15:56.291184 #1]  INFO -- :
I, [2022-11-30T10:15:56.292222 #1]  INFO -- : Terminating async processes
I, [2022-11-30T10:15:56.292556 #1]  INFO -- : Sending INT to HOME=/var/lib/postgresql USER=postgres exec chpst -u postgres:postgres:ssl-cert -U postgres:postgres:ssl-cert /usr/lib/postgresql/13/bin/postmaster -D /etc/postgresql/13/main pid: 41
I, [2022-11-30T10:15:56.292812 #1]  INFO -- : Sending TERM to exec chpst -u redis -U redis /usr/bin/redis-server /etc/redis/redis.conf pid: 102
2022-11-30 10:15:56.293 UTC [41] LOG:  received fast shutdown request
102:signal-handler (1669803356) Received SIGTERM scheduling shutdown...
2022-11-30 10:15:56.300 UTC [41] LOG:  aborting any active transactions
2022-11-30 10:15:56.306 UTC [41] LOG:  background worker "logical replication launcher" (PID 50) exited with exit code 1
2022-11-30 10:15:56.308 UTC [45] LOG:  shutting down
2022-11-30 10:15:56.340 UTC [41] LOG:  database system is shut down
102:M 30 Nov 2022 10:15:56.383 # User requested shutdown...
102:M 30 Nov 2022 10:15:56.384 * Saving the final RDB snapshot before exiting.
102:M 30 Nov 2022 10:15:56.481 * DB saved on disk
102:M 30 Nov 2022 10:15:56.482 # Redis is now ready to exit, bye bye...


FAILED
--------------------
Pups::ExecError: cd /var/www/discourse & su discourse -c 'bundle exec rake db:migrate' failed with return #<Process::Status: pid 1433 exit 1>
Location of failure: /usr/local/lib/ruby/gems/2.7.0/gems/pups-1.1.1/lib/pups/exec_command.rb:117:in `spawn'
exec failed with the params {"cd"=>"$home", "hook"=>"db_migrate", "cmd"=>["su discourse -c 'bundle exec rake db:migrate'"]}
bootstrap failed with exit code 1

<s

一番上の行から、discourse-signatures の問題の可能性があると、とりあえず言っておきます。それを除外して再構築してみて、うまくいくか確認してもらえますか?

実際、これは先日あったことと関連があるようです。

もう一度再構築してみて、一時的な問題かどうか確認してもらえますか?

「いいね!」 1

実は、先ほど3回試しました…署名プラグインをコメントアウトして、もう一度試すことができます。

また報告します。

「いいね!」 1

JammyDodger様、ありがとうございます!

プラグインをコメントアウトしたところ、再構築が正常に完了しました。

他のスレッドでは、修正が提出されたようです…おそらく、それを aml ファイルで再度有効にしてもう一度試せば機能するのではないでしょうか?

そうでなければ、今のところ、それはなくても大丈夫です。

「いいね!」 2

The issue should be fixed in the latest version of discourse-signatures. Are you using some other branch/fork of the plugin? :thinking: Can you share the signatures line from your app.yml?

「いいね!」 3

いつ追加したのかはかなり前なので、どのフォークか分かりませんが、これです。

#- git clone https://github.com/xfalcox/discourse-signatures.git

「いいね!」 1

なるほど。それを公式の https://github.com/discourse/discourse-signatures に更新すれば、もっとうまくいくはずです。

@Falco 公式リポジトリへの移行を支援するために何かすべきだと思います。GitHub に元のリポジトリのコピーをリダイレクトしてもらうことはできますか?もしそれができないなら、次のようなことを行うことができるかもしれません。

「いいね!」 6

それは素晴らしいでしょう。

私がフォーラムに追加した、その後安定化され、メインリリースに含まれた可能性のある最先端の機能が、後々同じことを行う可能性があることは十分に考えられます。

迅速な対応ありがとうございます!

「いいね!」 1

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.