I am trying to run tomcat 6 in linux when I invoke startup.sh I see this error in catalina.out
/home/***/apache-tomcat-6.0.29/bin/catalina.sh: line 338: /home/***/jre/bin/java: Permission denied
How can I get it running ? please help.
For solving this error, you need to add the correct permissions to the file to execute. However, you need to be a “root” user or have sudo access for changing the permission. For changing the permission, Linux offers a chmod command. The chmod stands for change mod.
To fix the permission denied error in Linux, one needs to change the file permission of the script. Use the “chmod” (change mode) command for this purpose.
We can provide the executable permission by using the below command, chmod +x filename.sh. chmod (Change Mode) - Using chmod we can change the access permissions to file system objects. +x - It makes the file executable.
This error occurs when the user does not have the privileges to make edits to a file. Root has access to all files and folders and can make any edits. Other users, however, may not be allowed to make such edits. Remember that only root or users with Sudo privileges can change permissions for files and folders.
Go to that folder and type the following code.
chmod 777 *
and try running it.
Its because of the permissions set.
If you are specific with permissions give excecute permission to it. Or
cd home/
chmod 777 apache-tomcat6.0
cd apache-tomcat6.0/bin
sh startup.sh
Try this:
cd /home/***/jre/bin/
$ chmod +x java
and then do:
$ sudo startup.sh
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With