Hipchat Server upgrade fails with Chef error

お困りですか?

アトラシアン コミュニティをご利用ください。

コミュニティに質問

プラットフォームについて: Server および Data Center のみ。この記事は、Server および Data Center プラットフォームのアトラシアン製品にのみ適用されます。

Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.

*Fisheye および Crucible は除く

問題

An upgrade of Hipchat Server fails and throws the following line to /var/log/hipchat/update.log:

There was an unexpected error: Command '['sudo', '/opt/atlassian/hipchat/sbin/cs']' returned non-zero exit status 1

/var/log/chef.log に次のメッセージが表示される。

[2016-10-17T08:17:14+00:00] INFO: Forking chef instance to converge...
[2016-10-17T08:17:14+00:00] INFO: *** Chef 11.8.2 ***
[2016-10-17T08:17:14+00:00] INFO: Chef-client pid: 16048
[2016-10-17T08:17:15+00:00] INFO: Setting the run_list to ["role[btf]"] from JSON
[2016-10-17T08:17:15+00:00] ERROR: Role btf (included by 'top level') is in the runlist but does not exist. Skipping expand.
[2016-10-17T08:17:15+00:00] FATAL: Stacktrace dumped to /usr/local/src/chef-stacktrace.out
[2016-10-17T08:17:15+00:00] ERROR: The expanded run list includes nonexistent roles: btf
================================================================================
Error expanding the run_list:
================================================================================
Missing Role(s) in Run List:
----------------------------
btf included by 'top level'
Original Run List
-----------------
role[btf]
[2016-10-17T08:17:14+00:00] INFO: Forking chef instance to converge...
[2016-10-17T08:17:15+00:00] FATAL: Chef::Exceptions::ChildConvergeError: Chef run process exited unsuccessfully (exit code 1)
allow custom /etc files
re-enabling monitoring
-----------------------------

診断

環境

  • This can happen in any Hipchat Server environment. 

Diagnostic Steps

  • Run a health check of the Hipchat Server Chef package:

    dpkg -s hc-chef-repo

    Even if the command returns an "Status: install ok installed" please proceed to the workaround steps.

原因

The root cause of the Chef failure is a broken/corrupt Chef repo in Hipchat Server.  

回避策

  1. Re-install the Chef repo: 

    sudo dont-blame-hipchat -c 'apt-get --reinstall install hc-chef-repo'
  2. Restart the upgrade: 

    hipchat upgrade --upgrade
  3. If the upgrade fails again, force it: 

    hipchat upgrade --force-upgrade
  4. If the upgrade fails again, run it offline

ソリューション

There's no permanent resolution to this upgrade failure as it might be caused by several events. The workaround has to be executed every time this issue is encountered. 

The error is nevertheless logged as a bug in HCPUB-1197.

 

最終更新日 2018 年 11 月 2 日

この内容はお役に立ちましたか?

はい
いいえ
この記事についてのフィードバックを送信する
Powered by Confluence and Scroll Viewport.