Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.
bash: ./myscript: /usr/bin/env: bad interpreter: Text file busy

"myscript" begins with #!/usr/bin/env python. Just retrying starting it fixed the problem.

Why system program env sporadically becomes "busy"? Can it be caused by prelink (but cron should start it not at that time...)

share|improve this question
1  
It's not env that's busy, it's the script itself. (By an editor or viewer, most likely.) –  David Schwartz May 9 '12 at 9:51
2  
Here "busy" means "a process has ./myscript opened for writing", according to execve(2). An editor usually does this only while saving edits to disk. –  grawity May 9 '12 at 11:45
    
OK, someone should add this as answer. –  Vi. May 9 '12 at 15:52

2 Answers 2

up vote 3 down vote accepted

Commenters say that it is script busy, not env or python and is caused by text editor saving it.

share|improve this answer

Usualy it's "./myscript" witch is busy because another program modify the file. It can be a text editor (when save it) but also a remote copy (This can be long if the download rate is low) or another program.

share|improve this answer

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.