Operating System - HP-UX
1748239 Members
3622 Online
108759 Solutions
New Discussion юеВ

java execute permission denied

 
SOLVED
Go to solution
Subentu
Frequent Advisor

java execute permission denied

I have a Rx7620 server.

When I try to run java as the user "reports" (java home directory in his home folder - /home/reports/apps/javaapp/jre1.6.0_04/bin), it gives the following error message:

su: /home/reports/apps/javaapp/jre1.6.0_04/bin/java: Execute permission denied.

I added these entries to the .profile file of the user "reports", but it still doesn't work.

export JAVA_HOME=/home/reports/apps/javaapp/jre1.6.0_04/bin/java

export PATH=$PATH:/home/reports/apps/javaapp/jre1.6.0_04/bin/

The same error message is given when I try to run it as the root.

Can you guys please help me.

Thanks
19 REPLIES 19
Jeeshan
Honored Contributor

Re: java execute permission denied

hi subentu

did you check the execute permission in
home/reports/apps/javaapp/jre1.6.0_04/bin/java ??
a warrior never quits
Yogeeraj_1
Honored Contributor

Re: java execute permission denied

hi,

is this a new installation?

Please post the output of the following command:
ll /home/reports/apps/javaapp/jre1.6.0_04/bin/java

revert!

kind regards
yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
Subentu
Frequent Advisor

Re: java execute permission denied

Thanks for the quick replies.

the output:
-rwxrwxrwx 1 reports users 47116 May 15 14:10 /home/reports/apps/javaapp/jre1.6.0_04/bin/java
Yogeeraj_1
Honored Contributor

Re: java execute permission denied

hi again,

can you also try the following command as the reports user:
cd /home/reports/apps/javaapp/jre1.6.0_04/bin/

./java -version


revert!
kind regards
yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
Subentu
Frequent Advisor

Re: java execute permission denied

Java version is jre1.6.0_04

requested output is:

$ cd /home/reports/apps/javaapp/jre1.6.0_04/bin/
$ java -version
su: java: Execute permission denied.
$

Thanks
Yogeeraj_1
Honored Contributor

Re: java execute permission denied

hi,

>$ cd /home/reports/apps/javaapp/jre1.6.0_04/bin/
>$ java -version
>su: java: Execute permission denied.
>$

Please run the java command as follows (using the "./")
./java -version

We need to make sure that the java is really from the mentioned directory.

Also post the output of:
echo $PATH


revert!
kind regards
yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
Subentu
Frequent Advisor

Re: java execute permission denied

$ ./java -version
su: ./java: Execute permission denied.


echo $PATH
/usr/bin:/usr/ccs/bin:/usr/contrib/bin:/usr/contrib/Q4/bin:/opt/perl/bin:/opt/hparray/bin:/opt/nettladm/bin:/opt/fcms/bin:/usr/contrib/kwdb/bin:/usr/bin/X11:/opt/graphics/common/bin:/opt/upgrade/bin:/opt/ipf/bin:/opt/resmon/bin:/opt/ignite/bin:/opt/sec_mgmt/bastille/bin:/opt/gnome/bin:/opt/mozilla:/opt/wbem/bin:/opt/wbem/sbin:/opt/mx/bin:/opt/sec_mgmt/spc/bin:/opt/perf/bin:/opt/hpnpl//bin:/usr/local/bin:/usr/contrib/bin/X11:/home/reports/apps/javaapp/jre1.6.0_04/bin/:/usr/contrib/bin:/usr/sbin:/app/oracle/product/9.2.0/bin


Thanks
Yogeeraj_1
Honored Contributor

Re: java execute permission denied

hi again,

is this a new installation?

Post the output of:
file java


It could also be that the version is not right!
Where did you download this software from?

Post more information like:
OS version
OS mode

revert!



kind regards
yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
Subentu
Frequent Advisor

Re: java execute permission denied

output is

# file java
java: cannot open
#


OS is 11iv2
Im running multiuser mode

Can it be a bad installation?

Thanks