AWS CRT binary not present in any of the following locations - Raspberry Pi 3B+
See original GitHub issueWhen I’m running the pub sub example as described below I get: The error I receive every time: (none of the solutions in #119 helped…
/home/pi/aws-iot-device-sdk-js-v2/node_modules/aws-crt/dist/native/binding.js:60
throw new Error("AWS CRT binary not present in any of the following locations:\n\t" + search_paths.join('\n\t'));
^
Error: AWS CRT binary not present in any of the following locations:
/home/pi/aws-iot-device-sdk-js-v2/node_modules/aws-crt/dist/bin/native/aws-crt-nodejs
/home/pi/aws-iot-device-sdk-js-v2/node_modules/aws-crt/dist/bin/linux-arm/aws-crt-nodejs
at Object.<anonymous> (/home/pi/aws-iot-device-sdk-js-v2/node_modules/aws-crt/dist/native/binding.js:60:11)
at Module._compile (internal/modules/cjs/loader.js:1063:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1092:10)
at Module.load (internal/modules/cjs/loader.js:928:32)
at Function.Module._load (internal/modules/cjs/loader.js:769:14)
at Module.require (internal/modules/cjs/loader.js:952:19)
at require (internal/modules/cjs/helpers.js:88:18)
at Object.<anonymous> (/home/pi/aws-iot-device-sdk-js-v2/node_modules/aws-crt/dist/native/crt.js:22:35)
at Module._compile (internal/modules/cjs/loader.js:1063:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1092:10)
I have a Raspberry Pi 3B+:
PRETTY_NAME="Raspbian GNU/Linux 10 (buster)"
NAME="Raspbian GNU/Linux"
VERSION_ID="10"
VERSION="10 (buster)"
VERSION_CODENAME=buster
ID=raspbian
ID_LIKE=debian
HOME_URL="http://www.raspbian.org/"
SUPPORT_URL="http://www.raspbian.org/RaspbianForums"
BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs"
- Node: 14.15.3
- aws-iot-device-sdk-v2: 1.5.2
- aws-crt: 1.8.1
I tried the solutions here https://github.com/aws/aws-iot-device-sdk-js-v2/issues/119 but nothing helped.
I followed exact example as described in AWS IoT but still, this error occurs.
The commands I ran after trying the installed and updated in the following order:
sudo apt-get update
sudo apt-get upgrade
sudo apt-get install cmake
sudo apt-get install libssl-dev
sudo apt-get install -y nodejs
restarted by sudo shutdown -r 0
cd ~
npm install aws-crt
npm install aws-iot-device-sdk-v2
cd ~
git clone https://github.com/aws/aws-iot-device-sdk-js-v2.git
cd ~/aws-iot-device-sdk-js-v2
npm install
cd ~
mkdir certs
(I copied the certs and changed the name accordingly...)
cd ~/aws-iot-device-sdk-js-v2/samples/node/pub_sub
npm install
node dist/index.js --topic topic_1 --root-ca ~/certs/Amazon-root-CA-1.pem --cert ~/certs/device.pem.crt --key ~/certs/private.pem.key --endpoint <endpoint>
(I swap the <endpoint> with my own....)
I can’t run the pub_sub example…
by the way the pythonv2 works, but I prefer using the node.js sdk…
_Originally posted by @yonatangross in https://github.com/aws/aws-iot-device-sdk-js-v2/issues/119#issuecomment-864529554_
Issue Analytics
- State:
- Created 2 years ago
- Comments:5 (2 by maintainers)
Top Results From Across the Web
AWS CRT binary not present in any of the following locations
Hi, I'm trying to use the AWS IoT SDK on Raspberry Pi Zero W but facing a problem when doing npm install aws-crt...
Read more >AWS CRT binary not present in any of the following ...
I received an answer in aws-iot-device-sdk-js-v2 repository from jmklix that solved my problem: Currently, the maintainers of the package ...
Read more >Connect a Raspberry Pi or another device - AWS IoT Core
On the Raspberry Pi, the home directory is ~/ , which is used as the home directory in the following commands.
Read more >SOLUTIONS MANUAL
This manual contains solutions to all of the review questions and homework problems in Cryptography and Network Security, Fourth Edition. If you spot...
Read more >Mosquitto MQTT Broker
How to Install The Mosquitto MQTT Broker on Linux (Ubuntu) ... It means that the error is occurring because there is no server...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
We currently don’t include the pre-compiled binaries for raspberry pi, but you can do this manually if you want to.
Go here and follow the install instructions (I have also included them below)
Then you will want to copy the folder containing
aws-crt-nodejs.node
to the location mentioned in the error message:You’ll likely need to install/build aws-crt manually and then point the sdk to your installation (or copy the installation into the SDK’s or application’s node_modules). We just added pre-built binary support for armv8/aarch64 (v1.8.5 of aws-crt, v1.5.5 of the sdk) but armv7a support is more difficult and I don’t know when it will get done.