Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I am trying to install some packes on my machine running CentOS 5.5 but when i run ./config or ./Configure, I am returned:

-bash: ./config: /bin/sh: bad interpreter: Permission denied

-bash: ./Configure: Permission denied

What do I need to change to correct the issue? I am connected as the root user

share|improve this question
    
Autoconf scripts are usually named lower-case 'configure', what are you trying to install? –  McJeff May 21 '10 at 20:35
    
openssl-1.0.0 ; configure lower case is no such file and does not work –  JM4 May 21 '10 at 20:37
add comment

3 Answers

up vote 0 down vote accepted

It looks like you got it right the first time with ./config

The problem seems to lie in /bin/sh; you may try using bash ./config instead, or otherwise fix /bin/sh's permissions or ownership.

Out of curiosity, can you do: ls -l /bin/sh* for us?

Is the partition or drive where you are trying to build this mounted noexec, like /tmp or similar?

The output of mount should show us whether that's the case :)

*edited

share|improve this answer
    
-rwxr-xr-x 1 root root 93560 Feb 28 16:33 /bin/ls –  JM4 May 21 '10 at 21:03
    
I think he meant /bin/sh :) –  voretaq7 May 21 '10 at 21:31
    
lrwxrwxrwx 1 root root 4 May 19 15:32 /bin/sh -> bash –  JM4 May 21 '10 at 21:37
    
Yes, /bin/sh; thank you voretaq7, I have ls on the brain apparently :) –  jrod May 21 '10 at 23:24
add comment

How about just ls -l inside the openssl directory, not ls -l /bin/ls like jrod wrongly suggested.

Either set the executable permission on the file your are trying to run with chmod like so:

chmod +x config

the run it:

./config

or just run it directly with the shell like so:

sh ./config

Can you not just use the openssl packages included with CentOS?

share|improve this answer
    
openssl packages icluded with CentOS 5.5 are severly outdated. Check the repositories. They only go to version 0.9.8e for 5.5 - PHP it outdated, as is Apache HTTPD. The list goes on and on –  JM4 May 21 '10 at 21:36
add comment

If you haven't gotten it resolved already... Are you trying to install as root? You should be. Otherwise, you might 'sudo'.

Others have suggested that the permissions problem is on the /bin/sh executable, but if that isn't it, make sure you can execute config / Configure (as appropriate). To do this, look at the file's permissions and consider who you are (whoami). If you aren't root or the file owner, you may be having problems because of that.

.

share|improve this answer
    
I am installing as root - just had to change permissions temporarily –  JM4 May 21 '10 at 21:50
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.