Bitbucket 服务器安装错误

Bitbucket Server Installation Error

我正在尝试在我的 linux 服务器上安装 Bitbucket 服务器。我正在按照步骤 here 进行操作。我卡在了第 3 步。我已经安装了 Bitbucket 服务器,现在尝试 "Setup Bitbucket Server" 我无法从我的浏览器访问它。

我做了以下事情:

  1. 我使用 SSH 进入了包含 /atlassian/bitbucket/4.4.1/
  2. 的目录
  3. 我运行命令bin/start-bitbucket.sh.

它给出以下消息:

Starting Atlassian Bitbucket as current user

-------------------------------------------------------------------------------
  JAVA_HOME "/usr/local/jdk" does not point to a valid Java home directory.
-------------------------------------------------------------------------------

----------------------------------------------------------------------------------
Bitbucket is being run with a umask that contains potentially unsafe settings.
The following issues were found with the mask "u=rwx,g=rwx,o=rx" (0002):
 - access is allowed to 'others'. It is recommended that 'others' be denied
   all access for security reasons.
 - write access is allowed to 'group'. It is recommend that 'group' be
   denied write access. Read access to a restricted group is recommended
   to allow access to the logs.

The recommended umask for Bitbucket is "u=,g=w,o=rwx" (0027) and can be
configured in setenv.sh
----------------------------------------------------------------------------------
Using BITBUCKET_HOME:      /home/wbbstaging/atlassian/application-data/bitbucket
Using CATALINA_BASE:   /home/wbbstaging/atlassian/bitbucket/4.4.1
Using CATALINA_HOME:   /home/wbbstaging/atlassian/bitbucket/4.4.1
Using CATALINA_TMPDIR: /home/wbbstaging/atlassian/bitbucket/4.4.1/temp
Using JRE_HOME:        /usr/local/jdk
Using CLASSPATH:       /home/wbbstaging/atlassian/bitbucket/4.4.1/bin/bitbucket-bootstrap.jar:/home/wbbstaging/atlassian/bitbucket/4.4.1/bin/bootstrap.jar:/home/wbbstaging/atlassian/bitbucket/4.4.1/bin/tomcat-juli.jar
Using CATALINA_PID:    /home/wbbstaging/atlassian/bitbucket/4.4.1/work/catalina.pid
Existing PID file found during start.
Removing/clearing stale PID file.
Tomcat started.

Success! You can now use Bitbucket at the following address:

http://localhost:7990/

If you cannot access Bitbucket at the above location within 3 minutes, or encounter any other issues starting or stopping Atlassian Bitbucket, please see the troubleshooting guide at:

我尝试访问 http://myserveraddress:7990,但收到 ERR_CONNECTION_REFUSED 消息。是因为消息JAVA_HOME "/usr/local/jdk" does not point to a valid Java home directory?

我的服务器是 运行ning: CentOS Linux release 7.2.1511

我正在尝试安装 Bitbucket Server 4.4.1

  1. 确保你已经通过 运行 java --version
  2. 安装了 java
  3. 如果没有安装,从这里开始。如果已安装,请通过 运行 find /-name java
  4. 验证位置
  5. 通过文本编辑器打开 /root/.bash_profile。 (我比较喜欢用vi编辑器) 并粘贴下面给出的两行(注意我下面的版本可能与你看到的不同)

    导出 JAVA_HOME=/usr/java/jdk1.7.0_21 导出 PATH=/usr/java/jdk1.7.0_21/bin:$PATH

  6. 现在启用 Java 变量无需系统重启(在系统重启时默认设置 java 变量)

    来源/root/.bash_profile

  7. 现在检查 Java 版本,JAVA_HOME 和 PATH variables.It 应该会显示您设置的正确信息。

    java --版本

    回声$JAVA_HOME

    echo $PATH

下面是我系统的根bash_profile文件

[root@localhost ~]# cat /root/.bash_profile
# .bash_profile

# Get the aliases and functions
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi

# User specific environment and startup      programs

PATH=$PATH:$HOME/bin

export PATH

export JAVA_HOME=/usr/java/jdk1.7.0_21
export PATH=/usr/java/jdk1.7.0_21/bin:$PATH
[root@localhost ~]#