Category: node.js

../binding.cc:28:17: fatal error: zmq.h: No such file or directory 0

../binding.cc:28:17: fatal error: zmq.h: No such file or directory

../binding.cc:28:17: fatal error: zmq.h: No such file or directory Solution CentOS : sudo yum install -y zeromq-devel Debian : sudo apt-get install libzmq3-dev Full log of error make: Entering directory `/home/frank/product/js/services/node_modules/zmq/build' CXX(target) Release/obj.target/zmq/binding.o ../binding.cc:28:17: fatal...

readv() failed (104: Connection reset by peer) while reading upstream 0

readv() failed (104: Connection reset by peer) while reading upstream

[error] 1528#1528: *599 readv() failed (104: Connection reset by peer) while reading upstream, client: 10.65.11.207, server: localhost, request: "POST /apis/v2/system/upgrade/upload HTTP/1.1", upstream: "http://127.0.0.1:8085/apis/v2/system/upgrade/upload", host: "10.65.11.219", referrer: "https://10.65.11.219/admin/update" Understanding: This message "(XXX: Connection reset by...

NodeJS v8 0

NodeJS v8 "err": {"message": "fsReadFileAsync(...).then(...).then(...).catch(...).done is not a function",

After upgrading code and libraries, you might run into "err":{"message":"fsReadFileAsync(...).then(...).then(...).catch(...).done is not a function", An example erroneous code const fsReadFileAsync = util.promisify(fs.readFile.bind(fs)); const fsWriteFileAsync = util.promisify(fs.writeFile.bind(fs)); // First apply changes to fstab fsReadFileAsync(this._fstabFilename, "utf8")...

npm not found when under sudo 0

npm not found when under sudo

[dev@squarepants www]$ sudo npm install -g bbb sudo: npm: command not found Solution You have probably like me installed node with nvm (node version manager). This installs node locally for the user and root...

Install a node workstation with nvm 0

Install a node workstation with nvm

1 NVM 1.1 Install nvm Note: Get the latest command from https://github.com/creationix/nvm $> curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.9/install.sh | bash $> export NVM_DIR="$HOME/.nvm" $> [ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh" # This loads nvm 1.2 Verify it...

Node.js reloading modules solution 0

Node.js reloading modules solution

In node.js, if you make change to a module's exported variable, the changes will not propagate to another module that already imported it. So what solution can we do to go around this "caching"...