I have a strange problem while trying to execute a system process from a Java program. Permission denied:
java.io.IOException: cannot start program "pwd.sh": error = 13, Permission denied
Very similar to this:
Java rejection error resolved for chmod command
He works for me on one machine, and not on another. I tried setting permissions to 777 in the pwd.sh file and no luck. The problem does not occur when I run the java program as "user1", but this happens when I start with root with "sudo -u user1 java ..." (which I ultimately need to do.)
So, any ideas what is going on? Is there a way in Eclipse to check my user ID and present the working directory before calling the program?
source
share