Upgrade Fails due to java.lang.IllegalArgumentException: port out of range
プラットフォームについて: 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 は除く
要約
When performing an upgrade for Confluence, the shutdown port cannot be set to a negative number. The Shutdown port provides an OS neutral way to close a Tomcat application (Confluence, Jira, etc.). This value must be set to a non-negative number.
環境
7.6.0
.
診断
The upgrade process fails before completion. Reviewing the logs, we find the following:
......
Your instance of Confluence is currently being upgraded.
Checking if Confluence has been shutdown...
In action "Check Confluence is shut [Run script]" (screen "Upgrade Actions [Form]"), property "Script":
java.lang.IllegalArgumentException: port out of range:-1
at java.base/java.net.InetSocketAddress.checkPort(Unknown Source)
at java.base/java.net.InetSocketAddress.<init>(Unknown Source)
at com.atlassian.inception.TomcatChecker.isTomcatRunning(TomcatChecker.java:15)
at com.install4j.script.I4jScript_Internal_72.eval(I4jScript_Internal_72.java:5)
at com.install4j.script.I4jScript_Internal_72.evaluate(I4jScript_Internal_72.java:*40)
at com.install4j.runtime.installer.helper.Script.evaluate(Script.java:33)
at com.install4j.runtime.installer.ContextImpl.runScript(ContextImpl.java:202)
原因
The shutdown port is using an invalid port number.
ソリューション
Update the shutdown port value. The shutdown port can be found at the very top of the server.xml file:
<Server port="7999" shutdown="SHUTDOWN" debug="0">
<Service name="Tomcat-Standalone">
.........
In order to resolve the port out of range error during an upgrade, we'll have to update the port value of the server.xml file to a non-negative value.