I've playing around with linux and noticed that for some开发者_如何学Python mysterious reason commands like '/bin/sh ' just will not work. Each time I'm trying to start a process it yields 'cannot execute binary file' error message.
m@sanctuary:~$ sh sed
/bin/sed: /bin/sed: cannot execute binary file
When I first launch sh and try to execute sed, it succeeds.
I'm starting to lose my wits. It would be just great, if somebody could help me.
Thank you.
"sed" isn't a shell script, so you don't execute it with sh. Just type sed ...args...
not sh sed ...args...
You're trying to run sed as a shell script, sed is just an ordinary executable. You can just run it as
m@sanctuary:~$ sed
sh
is expecting a shell script as an argument, but you're giving it a binary file.
精彩评论