Bash: No such file or directory?

I bet you miss dynamic linker. Just do a

readelf --all ./wkhtmltopdf | grep interpreter

You should get an output like this:

[Requesting program interpreter: /lib64/]

There are high chances that you system lacks the interpreter (/lib64/ in the example). In this case bash would yell No such file or directory, just like when the binary itself is missing.

You can try to use a different linker. Sometime you can succeed. Just do a:

/path/to/the/linker /path/to/your/executable

This command:

find /lib* -name ld-linux\*

will help you find the linkers on your system. Or you can do the readelf command on some command that does run. It will show you correct, working linker.

OR, since you are running Debian system, just do a

sudo apt-get install wkhtmltopdf

to install native version of the tool 🙂

Leave a Comment