1823198 Members
3883 Online
109648 Solutions
New Discussion юеВ

java in HP UX

 
SOLVED
Go to solution
DnD_1
Regular Advisor

java in HP UX

Hi guys,

I'm cleaning up the disk spaces in our HP UX, and saw 2 Java folder which are java1.2 and java1.3 in /opt.

I was wondering, can I delete one of them ?

2001 java1.2
2006 java1.3

thanks !!
9 REPLIES 9
Pete Randall
Outstanding Contributor
Solution

Re: java in HP UX

It's going to take a little effort and some investigation to determine which one is actually being used. I would start by using the find command, grepping for java1.2 or java1.3 to see which of your applications might be using one or the other, then proceed from the there:

find /apps -exec grep -l "java1.2" {} \;


Pete

Pete
Jeeshan
Honored Contributor

Re: java in HP UX

this is not a good idea. because there may be some dependency in perspective from your applications.
a warrior never quits
Dennis Handly
Acclaimed Contributor

Re: java in HP UX

You do know there are also java1.4 and java1.5 available.
TTr
Honored Contributor

Re: java in HP UX

You should check the access time of files in each of the java directories. Specifically the binary "java" itself but access to any significant file would indicate they are in
use.

Something like

find /opt/java1.4 -type f -atime -30

would show you the files that have been accessed in the last 30 days. To find out when they were accessed use

find /opt/java1.4 -type f -atime -30 -exec ll -u {} \;

Also think about what is running on the server. Is it likely that any of the products would use java? And keep in mind that most add-on apps and databases (including HP-UX bundled products) supply their own java and rarely depend on the OS one.

If you decide that these two are not being use, do not just delete them, use swremove to remove them. But do download and install a recent java version before you delete any of the old ones.
DnD_1
Regular Advisor

Re: java in HP UX

hi TTR..

thanks !!

when i run the command you gave me..

it return nothing...like

hpux:/opt>find java1.2 -type f -atime -30
hpux:/opt>find java1.3 -type f -atime -30

is does mean they not been used ? and i can safely swremove them ?

thanks again !
TTr
Honored Contributor

Re: java in HP UX

It looks that way. But to be sure go to each java binary folder and look at the access time with "ll -u".
Bill Hassell
Honored Contributor

Re: java in HP UX

Leave them as is...Java is a painful study in backwards incompatibility. Unless Java code writers take extraordinary steps to avoid compatibility issues, your web server will probably need on of these older versions someday. I have found no simple way to remove these different versions -- some depend on each other.

Now if no one on your system is writing and Java programs, and you're not running a web server (ie, Apache), then you can try using swremove to remove all the code.


Bill Hassell, sysadmin
dirk dierickx
Honored Contributor

Re: java in HP UX

you can delete both of them, if nothing on the box you use needs java.

you can't delete any of them, if there are several tools on the system that need java, and they need different versions.
DnD_1
Regular Advisor

Re: java in HP UX

As advised, let it be