Friday, July 20, 2018

Java installation and configuration on AIX

Hello everyone today i am going to share how to install and configure JAVA5 on AIX. Generally JAVA required Pre-requisite for some installation .Example . TSM installation and configuration,oracle installation and configuration.

So lets see how configure JAVA on AIX.

First thing need to check was to confirm which version of JAVA was installed on AIX. execute following command to  check java version

#lslpp -l |grep -i java 

if above command not showing any output then there is no java installed on AIX .
AIX admin can install and keep multiple version of JAVA and do environment setting according to requirement of application. whether application or TSM team require 32 bit or 64 bit JAVA version.


#Java -version

Above command will show java -version currently configured on AIX .

So here i am going share method to install java 5 ,32 bit version on AIX and same method can be used to install other new version also.


In our case TSM admin need JAVA 5 ,32 bit version. So first copied required installation files on AIX LPAR.

1. First install Java5.sdk using SMIT install.
2.If in case AIX admin want to update current JAVA5 then simply copy required update fileset on current path and do smitty_update all.
3.After this, edit /etc/environment file and add java5 path .There is chances that already some PATH are present in /etc/environment file ,according to syntax of file AIX admin can add JAVA5 setting. if AIX admin want to add this setting for specific user he can do changes in .profile file of specific user and to reload .profile after changes execute command  #. .profile

PATH=/usr/java5/jre/bin:/usr/java5/bin

AIX admin can do PATH setting according to requirement by other team,by changing PATH setting in /etc/environment variable.


4. After installation and PATH setting execute following command to check currently configured JAVA version.

#Java -version



To test whether java is properly configured or not on AIX  node ,we are going to execute following JAVA test program.

root@AIX_LPAR# cat testjavaprog.java
class 
testjavaprog
{
        public static void main(String args[])
        {
           System.out.println("Java test program");
        }
}

3. compile program  with javac:
root@AIX_LPAR#javac testjavaprog.java

4. run the program using following command
root@AIX_LPAR# java testjavaprog

Java test program

IF everything is correctly configured then after running program
output will be "Java test program".


Thanks  !!!




No comments:

Post a Comment