Skip to content

Instantly share code, notes, and snippets.

@BadUncleX
Last active April 11, 2018 02:22
Show Gist options
  • Save BadUncleX/0c7b2d1b1280a7841e04bb8e391f2bdd to your computer and use it in GitHub Desktop.
Save BadUncleX/0c7b2d1b1280a7841e04bb8e391f2bdd to your computer and use it in GitHub Desktop.
AIX系统安装JDK [smit 命令, jdk, jre]

reference: http://bit.ly/2qcnXYS IBM jdk/jre download page: https://ibm.co/2IBPfPc see official site: http://www-01.ibm.com/support/docview.wss?uid=isg3T1022693 1.查看os系统版本信息

-bash-4.3# whoami
root
-bash-4.3# oslevel -r
6100-02
-bash-4.3# oslevel   
6.1.0.0
-bash-4.3# bootinfo -y
64
-bash-4.3# bootinfo -K
64

2.查看AIX系统版本与jdk版本的支持情况列表:https://www.ibm.com/developerworks/java/jdk/aix/service.html 通过列表找到本系统所支持的jdk的版本和,点击Java SE Version x,选择合适的32或64位数并点击DownloadNow进入下载界面(注意:下载需要注册账户):

以jdk1.7 64bit为例下载界面:IBM 64-bit SDK for AIX®, JavaTM Technology Edition, Version 7 Release 1 选择download using http: 选择下载以下jre和jdk包:

Java Runtime Environment
Java7_64.jre.7.1.0.401.tar.gz  (140519989)

Development Kit
Java7_64.sdk.7.1.0.401.tar.gz  (12815185)

3.解压安装包 .tar.gz的解压方式如下

gunzip -c Java7_64.jre.7.1.0.401.tar.gz | tar -xvpf -
gunzip -c Java7_64.sdk.7.1.0.401.tar.gz  | tar -xvpf -

4.安装 执行smit命令,打开图形化安装包,依次选择:

选择“Software Installation and Maintenance”,Enter
下一步,选择“Install and Update Software”,Enter
下一步,选择“Install Software”,Enter
下一步,在“INPUT device / directory for software”后面,写上要安装包的路径:/home/Java7_64.sdk,Enter 
下一步,“accept new license agreements”把对应的"no"设置成“yes”
下一步,确认界面,Enter

5.修改系统变量 方法1:修改/etc/下的environment文件 添加/usr/java7_64/jre/bin;/usr/java7_64/bin; 方法2:export PATH=/usr/java7_64/jre/bin:/usr/java7_64/bin

# lslpp -l |grep Java(查看安装了的JDK)
# lslpp -l|grep Java
 Java7_64.sdk                7.0.0.113 COMMITTED  Java SDK 64-bit
 Java7_64.sdk                7.0.0.113 COMMITTED  Java SDK 64-bit
# java-version
java version"1.7.0"

安装成功!

命令:df -g以G为单位查看aix下面的各个目录大小

参考文档: AIX下安装JDK的方法

AIX6.1下安装JDK1.7

AIX安装JDK

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment