-bash: ./configure: /bin/sh: bad interpreter: Permission denied
SlackwareThis Forum is for the discussion of Slackware Linux.
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
I get this error when I try to compile on a partition mounted from fstab with "user" option. I found this on the LFS FAQ page that explains the issue and the solution:
You're most likely getting this while building binutils in Chapter 5 of the LFS Book. The problem is most likely your mount options. You probably have a line in /etc/fstab like:
/dev/hda10 /mnt/lfs ext2 user 1 2
'user' is the mount flag, and it's the problem. To quote from the mount man page:
user: Allow an ordinary user to mount the file system. This option implies the options noexec, nosuid, and nodev (unless overridden by subsequent options, as in the option line user,exec,dev,suid).
So change the line in /etc/fstab like this:
/dev/hda10 /mnt/lfs ext2 defaults 1 2
The directory is just my storage hdd
suggests that this directory is mounted from fstab - perhaps with the offending options.
Another option would be to try to ./configure from /home/user or /tmp.
The error you are getting is the same you would get when you try to run a script that is not executable. This is where you should probably focus your efforts. Can you run just a plain test script on the same drive? same directory? Does it make a diffrence when you run 'sh script' or './script'? Try to narrow down the problem as much as possible.
I had to rerun my x setup this AM on that box (due to reinstalling /a), and I had to use 'sh NVID...' on the box, not just './NVID...'. I cannot run anytype of configure script on that machine, no matter where it came from...
Distribution: Slackware & Slamd64. What else is there?
I run my /tmp noexec as a security measure. I outsmarted myself today and when I realized what I did I came here to post a warning to anybody else who might have this problem- but I see my buddy CW already did it on a different mountpoint
Thanks man! I did the same goddam thing and I was like, WTF? I couldn't imagine having gotten a configure file that was cr/lf format, but checked it anyway -- and I have had problems with bash, when called as /bin/sh, screwing up on script files that have CR/LF (I dont remember which version however). Yea, I'm recycling some quick build-a-gentoo scripts I made last year and I forgot that I set my tmpfs mounts to noexec!
Thanks for this thread
edit: actually, I'm thinking this problem was a busybox ash shell, I can't remember which (might have been HP-UX crap too)
Last edited by daniel.santos; 02-25-2007 at 08:30 PM.
I just had the same problem but had nothing to do with bash, etc. I was going to rebuild my machine from Ubuntu 10.4 to 10.10 and copied my home folder to an external NTFS hard drive to back it up. After loading 10.10, I copied everything back to my new home folder. In this process, all my executable ./configure files had their "executable" flag reset to not be executable. When I edited the properties of the ./configure file and clicked "Allow executing..." it worked again.
Apparently symbolic links AND executable script attributes don't pass through Windows file format successfully.