Troubleshooting -bash: Cannot Execute Binary File: Exec Format Error

bashbinarytroubleshooting

I have a mining rig and am trying to run a program ./garlicoind but I get this error:

-bash: ./garicoind: cannot execute binary file: Exec format error

Is this a common problem? What does it indicate?

Best Answer

The program you have is most likely a binary compiled for a different architecture than the machine on which you're trying to run.

You can obtain the binary's architecture type by running

file garlicoind

and you can obtain your machine's architecture type by

uname -m

If they are different, you need either to get the correct binary for your architecture, or to get the code source of the program and compile it yourself.

Related Question