jeet
jeet

Reputation: 629

Error: Could not locate bindings file node-librdkafka.node

Suddenly I have started seeing below error while running a Node.js app using node-rdkafka. It was working before, not sure what triggered this error.

Error: Could not locate the bindings file. Tried -> /home/...../node-librdkafka.node ...

I tried npm install, npm rebuild, all of them work without giving any issue, just that the bindings do not get created.

this is on debian-jessie guest in Virtual box running on Windows as host.

Thanks!

Upvotes: 3

Views: 2742

Answers (2)

Anis
Anis

Reputation: 33

this solved the issue:

my ~/.npmrc has

ignore-scripts=true

basically you can switch it to false and try remove the node_modules and then reinstall node-rdkafka again.

the other option go to node-rdkafka package: "cd ./node_module/node-rdkafka" and run the following command

node-gyp configure && npm run build

Upvotes: 0

jeet
jeet

Reputation: 629

npm install node-rdkafka resolved this issue.

Upvotes: 5

Related Questions