Skip to main content

/bin/sh: bad interpreter: Permission denied

Hello Guys, hope you all doing great. After a major gap I am back to my blog to write some useful information which could help someone who is working on Linux servers :) 

For Freelance Work & Queries Contact me by Email Id support@linuxforeveryone.com

So, today i am going to discuss about a general error which comes on linux servers when we try to install any package or making changes in some directories.There might be other reason as well when this errors comes. So error which i am talking about is 

Error:


 /bin/sh: bad interpreter: Permission denied

Understanding the error:

Most of you might have come across this error.So question comes up what this error is saying:
and as per me its saying about some permission denied to the bash not able to access/write/execute the certain directory on linux server.

What directory is being denied:

The directory being denied is generally /tmp, because /bin/sh shell tries to execute some raw calculations inside the /tmp directory which is generally mounted and having permission set as no execute permission for /tmp partition.

How to get rid of it:

Just run below command to make the /tmp partition to execute the commands inside for the users.
 
Where we are remounting the /tmp partition with execute permissions, so that our error could get away and we can move forward with our work.

Once you will run above command, your error should be gone, but take a IMP note here, once you are done with your task whatever it may be, dont forget to remount the /tmp with default permissions.

and doing so is the good practice :) and to do that run the below command.

   
For Freelance Work & Queries Contact me by Email Id support@linuxforeveryone.com

Comments

  1. Very nice post..After reading your post,thanks for taking the time to discuss this, I feel happy about and I love learning more about this topic.
    This article inspired me to read more. keep it up.
    Reactjs Training in Chennai |
    Best Reactjs Training Institute in Chennai |
    Reactjs course in Chennai

    ReplyDelete

Post a Comment

Popular posts from this blog

Multiple instances of redis

In the last post I have covered how to install redis server on Centos/Rhel using rpm method and yum method and some troubleshooting skills. In this post i am going to cover how to install and configure redis to run with multiple ports.                                                                           But why we need more ports ? If you have read my earlier post , you already know that by default redis runs on single port 6379, which any one can use it for small website to cache the data. But for heavy website like magento we need to use additional ports along with 6379 to serve different cache from different ports. Like in Magento there is simple cache which is normally stored under /var/cache directory. Then there is Full Page Cache which is stored under /var/full_page_cache...

Optimization of Redis

In this Post, I am going to cover how to optimized REDIS  (recently i was reading this random blog giving more clear insight on what is redis and what the use of it in real world) instances as per our requirement. if you are not aware about REDIS at all, you can refer to my previous post where i have covered How To install REDIS on Centos/Redhat servers which goes here . How To Create Multiple instances of REDIS which goes here . What is the Best Standard method to configure REDIS which goes here . So, Lets see how to optimize our redis server. few points you need to keep in mind that which are important while doing optimization and we are going to learn more about shortly. For Freelance Work & Queries Contact me by Email Id support@linuxforeveryone.com Remove any errors you are seeing under redis logs Check the amount of cache size your site is using for each port Set proper eviction policy for redis keys Set proper kernel Settings t...

arbtd: Package isn't signed with proper key

  If you are System Admin and worked on linux machine or servers in your current job or in past. Chances are you might come across linux service abrtd, even if you have not worked on it. but might be through some other work. same thing happened to me, while I was doing my regular work of installing php packages on linux  servers , i came across this error for which spent couple of hours actually to resolve it. T he error was