No such file or directory: Cannot execute but is visible to ls, file and tab-completion

后端 未结 1 1104
夕颜
夕颜 2021-01-14 23:34

I\'m installing flexnet on an amazon lightsail instance. I\'ve just extracted the contents to /opt and in trying to run any lm* command. With ls I

相关标签:
1条回答
  • 2021-01-15 00:16

    If you try to run an executable and you get the "no such file or directory" error, this often means that the executable is unable to find the correct dynamic loader. If you look at the output from the file command, you see:

    ...interpreter /lib64/ld-lsb-x86-64.so.3...
    

    Does your system have /lib64/ld-lsb-x86-64.so.3? If not, that suggests that these binaries were built for a different architecture (e.g., 64 bit vs 32 bit) or for a different version of the C library (glibc).

    Solutions include:

    • Install packages that contain the necessary interpreter.

    • Find a set of executables that have been compiled for the version of the C library installed on your system.

    • Run things inside a Docker container or chroot environment that has the appropriate C library installed.

    A hacky solution would be to use the patchelf command to change the interpreter path embedded in the binaries. Depending on your environment, that might work or it just may make everything crash.

    Also, just symlinking from the .so.2 to .so.3 might work.

    0 讨论(0)
提交回复
热议问题