dragonwell-project / dragonwell8

Alibaba Dragonwell8 JDK
http://dragonwell-jdk.io
GNU General Public License v2.0
4.21k stars 497 forks source link

[Bug] yum 安装后,没有 jps 指令 #554

Closed russell7 closed 1 year ago

russell7 commented 1 year ago

Description java-1.8.0-alibaba-dragonwell 安装后有 java ,没有 jps java-1.8.0-alibaba-dragonwell-debug 安装后有 java 和 jps ,但是没有注入到 path

Steps to Reproduce

  1. 使用 "Alibaba Cloud Linux 3.2104 LTS 64位 等保2.0三级版" 镜像初始化 ECS
  2. 安装 yum install -y java-1.8.0-alibaba-dragonwell-debug
  3. java 存在于 '/opt/alibaba/java-1.8.0-alibaba-dragonwell-8.8.8.302.b1-1.al8-debug/bin/java' 和 '/opt/alibaba/java-1.8.0-alibaba-dragonwell-8.8.8.302.b1-1.al8-debug/jre/bin/java', jps 存在于 '/opt/alibaba/java-1.8.0-alibaba-dragonwell-8.8.8.302.b1-1.al8-debug/bin/jps' 但是均没有注入 path,或通过 alternatives 管理。因此不能直接执行。
  4. 安装 yum install -y java-1.8.0-alibaba-dragonwell
  5. java 指令注入到 path 中。链接路径是 "/bin/java -> /etc/alternatives/java -> /usr/lib/jvm/java-1.8.0-alibaba-dragonwell-1.8.0.362-1.1.al8.x86_64/jre/bin/java"

Expected behavior jps 等指令在安装后可直接使用。或在安装手册明确人工调整方式。

JDK version java-1.8.0-alibaba-dragonwell-debug openjdk version "1.8.0_302-debug" OpenJDK Runtime Environment (Alibaba Dragonwell 8.8.8-b01) (build 1.8.0_302-debug-b1) OpenJDK 64-Bit Server VM (Alibaba Dragonwell 8.8.8-b01) (build 25.302-b1-debug, mixed mode)

java-1.8.0-alibaba-dragonwell openjdk version "1.8.0_362" OpenJDK Runtime Environment (Alibaba Dragonwell Extended Edition 8.14.15) (build 1.8.0_362-b03) OpenJDK 64-Bit Server VM (Alibaba Dragonwell Extended Edition 8.14.15) (build 25.362-b03, mixed mode)

Execution environment

关联阿里云工单 0001Z94KB6

russell7 commented 1 year ago

另: java-1.8.0-alibaba-dragonwell.x86_64 在 repo 中的描述属于 JDK ,但是从可执行文件和目录来看,更像一个 JRE 。

Name         : java-1.8.0-alibaba-dragonwell
Epoch        : 3
Version      : 1.8.0.362
Release      : 1.1.al8
Architecture : x86_64
Size         : 1.1 M
Source       : java-1.8.0-alibaba-dragonwell-1.8.0.362-1.1.al8.src.rpm
Repository   : @System
From repo    : alinux3-plus
Summary      : Alibaba Dragonwell 1.8.0 JDK
URL          : https://github.com/alibaba/Dragonwell8
License      : GPL-v2
Description  : Alibaba Dragonwell 1.8.0 JDK
sendaoYan commented 1 year ago

安装java-1.8.0-alibaba-dragonwell-devel包,才有jps这类jdk工具

image

russell7 commented 1 year ago

安装 java-1.8.0-alibaba-dragonwell-devel 后解决。