2 Replies Latest reply on Mar 16, 2015 6:10 PM by jojoba

    frequent npm install error

    jojoba

      Hello!

       

      I have a rather odd error that pops up rather frequently. I'll be able to run npm install on valid libraries for a few days and everything installs fine. However, after such time (and some reboots and power cycling),  when I again run "npm install" against a valid library I will get the following response (in this case I'm trying to install a piezo buzzer library):

       

      >>>>>>>>>>>>>>>>>

      root@mrdude:~/projects/mrdude/client# npm install jsupm_buzzer

      npm WARN package.json mrDudeNodeClient@0.0.1 No repository field.

      npm WARN package.json mrDudeNodeClient@0.0.1 No README data

      npm http GET https://registry.npmjs.org/jsupm_buzzer

      npm http GET https://registry.npmjs.org/jsupm_buzzer

      npm http GET https://registry.npmjs.org/jsupm_buzzer

      npm ERR! network getaddrinfo ENOTFOUND

      npm ERR! network This is most likely not a problem with npm itself

      npm ERR! network and is related to network connectivity.

      npm ERR! network In most cases you are behind a proxy or have bad network settings.

      npm ERR! network

      npm ERR! network If you are behind a proxy, please make sure that the

      npm ERR! network 'proxy' config is set properly.  See: 'npm help config'

       

      npm ERR! System Linux 3.10.17-poky-edison+

      npm ERR! command "/usr/bin/node" "/usr/bin/npm" "install" "jsupm_buzzer"

      npm ERR! cwd /home/root/projects/mrdude/client

      npm ERR! node -v v0.10.28

      npm ERR! npm -v 1.4.9

      npm ERR! syscall getaddrinfo

      npm ERR! code ENOTFOUND

      npm ERR! errno ENOTFOUND

      npm ERR!

      npm ERR! Additional logging details can be found in:

      npm ERR!     /home/root/projects/mrdude/client/npm-debug.log

      npm ERR! not ok code 0

      <<<<<<<<<<<<<<<<<<

       

      My network is funcitional and I don't have any bizarre configurations set up for it. This problem will go away (and the npm install command works great) if I run "reboot ota" and then update the repos again. This solution while it works is definitely not optimal. I was curious if anyone else has encountered such an issue?

       

      Thanks!

        • 1. Re: frequent npm install error
          CMata_Intel

          Hi jojoba

           

          Are you able to install  jsupm_buzzer after flashing the board?

          The error log says "This is most likely not a problem with npm itself and is related to network connectivity." So the issue might be with in your network. Check your DNS in /etc/resolv.conf

          When you have this issue, do you try to access the websites with your PC's browser?  I'm asking because in this moment the website https://registry.npmjs.org/jsupm_buzzer is not available so if the websites are not working you will have some issues.

           

          Regards;

          CMata

          • 2. Re: frequent npm install error
            jojoba

            Hello,

             

            After flashing the board I am not able to install jsupm_buzzer. But that's actually my fault! It appears that jsup_buzzer is not in the npm registry! So I was incorrect in my post above that it is a valid npm library. Sorry about that. However, I have seen this issue many times for valid npm libraries, where the only fix that worked was to flash the board and then retrying npm install on that library. I'll try to post an error when it happens agaien. Lastly, for what it's worth, jsupm_buzzer seems to load fine with require("jsup_buzzer") without any npm install. 

             

            Thanks