Re: [LIP] Problem executing scripts Bad Interpreter
Binand Sethumadhavan <[email protected]>
| Newsgroups | gmane.user-groups.linux.india.programmers |
|---|---|
| Message-ID | <[email protected]> |
Vardhman Jain posted in linux-india-programmers: > this time and also previously, when I copied some executable here and > tried to execute them I got the error " > "-bash: ./configure: /bin/bash: bad interpreter: Permission denied" > > with "/bin/bash" and also "/usr/bin/env python". I have checked the file > permissions to be executable by all. The strange thing is that I am able > to run the script by saying "python <scriptname>" and not by > ./scriptname(for the python script containing #!/usr/bin/env python at the top). There are two reasons this might be happening. 1. In your /fun, shebang scripts are not supported. Very unlikely. I don't think shebang support is dependent on the underlying filesystem, anyway. 2. Your scripts have CRLF for newline. Run them through dos2unix and then try running them. This seems more likely than (1). Probably you copied your script from a Windows partition, or FTP'ed the script using ASCII mode. Post the output of this command here: head -1 /path/to/your/script | xxd Binand -- [[email protected] root]# uptime 11:55am up 58 days, 4:49, 2 users, load average: 1023.78, 419.92, 158.90 ------------------------------------------------------- This SF.Net email is sponsored by: Oracle 10g Get certified on the hottest thing ever to hit the market... Oracle 10g. Take an Oracle 10g class now, and we'll give you the exam FREE. http://ads.osdn.com/?ad_id=3149&alloc_id=8166&op=click