Linux.com

cannot execute binary file

Link to this post 14 Oct 09

Hi,

I am getting the error message "-bash: /bin/hostname: cannot execute binary file" while login to my server through SSH. Can anyone please help me to resolve this problem? I searched on the web, but not found useful solution.

Also, i could not use the command like,
1. cat /var/log/messages --- its working
2. cat /var/log/messages|more --- it gives the error message bash: /bin/more: cannot execute binary file

I am getting the error message whenever i run the command like, command | more, grep and rpm -qa

Thanks
Tamilselvan

Link to this post 14 Oct 09

check is there a executive permission on that command or use ldd
<command>

Link to this post 15 Apr 10

Tamilselvan,

what is your permission in /bin. maybe files mentioned in that folder are too restrictive. Loosen up a bit the permission and test if its working.

Link to this post 16 Apr 10

This problem sometimes occurs because either the application was built for 64-bits but you are running a 32-bit environment, or it was compiled for an incompatible processor type.

Who we are ?

The Linux Foundation is a non-profit consortium dedicated to the growth of Linux.

More About the foundation...

Frequent Questions

Join / Linux Training / Board