Reputation: 831
I pasted tomcat folder in Linux machine. User is root . When I go to bin folder and execute ./startup.sh
I'm getting an error:permission denied
. [This is what I got]
How to rectify this issue.
Upvotes: 5
Views: 48745
Reputation: 795
It is also worthwhile to check which bash you are using with
which bash
This is because you might see the error
Cannot find ./catalina.sh
when your bash is /usr/bin/bash but is working perfectly fine when bash is /usr/bash
Upvotes: 0
Reputation: 141
As color of file name is white, I suppose file is not executable; try the following command
ls -l
It gives you file list with its permission. Try using command
chmod a+x startup.sh
If still permission denied. Try
sudo chmod a+x startup.sh
Then try using ./startup.sh If still permission denied. Then try
sudo ./startup.sh
Hope it will be helpful.
Upvotes: 12
Reputation: 831
give:
chmod -R 777 startup.sh
Then error will come as:Cannot find ./catalina.sh then give:
chmod -R 777 catalina.sh
Tomcat will start. the problem was because there was no permission for executing. u can see if permission is there or not by giving:
ls -l
Upvotes: 19
Reputation: 31
Verify, that your filesystem with the new tomcat folder isn't mounted with "noexec". Please run a "ls -l", "file start.sh" and a "head start.sh" .
Tom
Upvotes: 2