LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   perl: bad interpreter: Permission denied (https://www.linuxquestions.org/questions/linux-software-2/perl-bad-interpreter-permission-denied-42889/)

bulliver 01-26-2003 09:00 PM

perl: bad interpreter: Permission denied
 
Hello all,

I am trying to run a simple perl script that converts mp3s to oggs, but it throws errors:
Code:

bash: ./mp32ogg: /usr/bin/perl: bad interpreter: Permission denied
I have tried as a user and as root. I am not perl savvy enough to tell if it is the fault of the script.
The permission of perl5.8.0 is:
Code:

-rwxr-xr-x
The permission of the perl symlink is:
Code:

lrwxrwxrwx
Do I need to install a less bunked up version of perl?
Any thoughts are appreciated.

Sorry, I should mention it isn't my script, I downloaded it ...

born4linux 01-26-2003 09:24 PM

try this first:

which perl

then compare the output to the entry in the script.

bulliver 01-26-2003 10:41 PM

Which perl gives me /usr/bin/perl, which is the same as the shebang line in the script...

I guess I'm just trying figure out if this is a bad script or a bad perl. I'm thinking bad perl because of the 'bad interpreter', bit, but the permissions thing is making me think perhaps the script is trying to do something that it is not allowed to (it has to delete files, and create new ones), but everywhere I have the script working is publically rwx'able.

What a noodle scratcher.Anyone seen this error before?

EDIT: I just wrote "hello world" in perl and it worked fine. Looks like I have a bunk script.

j-ray 01-27-2003 08:29 AM

it is an errror message u receive when your perl script is not
0755 executable. u're talking of a symlink that has permissions set to 0777. as a matter of fact symlinks tend to have these permission by default but u should check out permissions of your original perl script and set it to 0755 or similar. i dont think there are 'broken versions' of perl5.8 available.
cheers, jens

bulliver 01-27-2003 03:12 PM

He he, I'm not totally green, the first thing I checked was the permissions of the script. As I said, other perl scripts work fine, so I just got a script that won't work for me. Rather than waste a bunch of time debugging it I just wrote my own shell script which does the same thing (convert mp3s to oggs).


All times are GMT -5. The time now is 07:10 AM.