When using the root user, Search server cannot be started due to "don't run <search server> as root"
プラットフォームについて: 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 は除く
問題
Search server cannot be started, therefore Bitbucket Server cannot connect to it.
The following appears in the console output when running the start-search.sh
or the start-bitbucket.sh
script or the :
root@myserver:# cd /opt/atlassian/bitbucket/bin/
root@myserver:/opt/atlassian/bitbucket/bin# sh start-search.sh
Starting Elasticsearch bundled with Atlassian Bitbucket
BITBUCKET_HOME set to /var/atlassian/application-data/bitbucket
-e Starting Elasticsearch bundled with Atlassian Bitbucket as current user
-e
Elasticsearch bundled with Atlassian Bitbucket started successfully
root@myserver:/opt/atlassian/bitbucket/bin# Exception in thread "main" java.lang.RuntimeException: don't run elasticsearch as root.
at org.elasticsearch.bootstrap.Bootstrap.initializeNatives(Bootstrap.java:93)
at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:144)
at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:270)
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:35)
Refer to the log for complete error details.
診断
環境
- Operating system: Unix based
原因
Search server cannot be run as root.
ソリューション
- Login as the
atlbitbucket
user, or for some installations, bitbucket user - Run the start script
最終更新日 2022 年 5 月 24 日
Powered by Confluence and Scroll Viewport.