AWS re:Post을(를) 사용하면 다음에 동의하게 됩니다. 이용 약관

How to install openjdk-11.0.16 version in amazon linux 2

0

I have to install a specific version of openjdk i.e, openjdk-11.0.16 in amazon linux 2. I don't want to install coretto11. we can install using amazon-linux-extras install java-openjdk11, but this approach always installs the latest version and not the specific version I require.

How to achieve this?

질문됨 13일 전9회 조회
1개 답변
0

HI,I used this step install openjdk-11-0.16 version in amz 2

wget https://builds.openlogic.com/downloadJDK/openlogic-openjdk-jre/11.0.16+8/openlogic-openjdk-jre-11.0.16+8-linux-x64.tar.gz
mv openlogic-openjdk-jre-11.0.16+8-linux-x64 /usr/jdk-11.0.16
# add this to your /etc/profile
export JAVA_HOME=/usr/jdk-11.0.16
export PATH=$PATH:$JAVA_HOME/bin

# then,you just source this env

source /etc/profile

# check the java version

[root@ip-172-31-23-10 ~]# java -version
openjdk version "11.0.16" 2022-07-19
OpenJDK Runtime Environment OpenLogic-OpenJDK (build 11.0.16+8-adhoc.root.jdk11u)
OpenJDK 64-Bit Server VM OpenLogic-OpenJDK (build 11.0.16+8-adhoc.root.jdk11u, mixed mode)

I hope this can help you,hava a nice day!

在此处输入图片描述

답변함 13일 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인