6 Replies Latest reply on Sep 22, 2015 5:30 AM by Lohith

    Error in Build/Install in Intel XDK_Iot_edition using Galileo gen 2

    Lohith

      hey,

      I’m doing a project on the board, but i thought I'll start off first with uploading the blinking on-board led using the server client example.I've followed all steps given in the main.js file and the readme file. I’ve also included the repository suggested and tried opkg update, which was largely successful apart from the lone error.

      * opkg_conf_parse_file: Duplicate src declaration (mraa-upm http://iotdk.intel.com/repos/1.1/intelgalactic). Skipping.

       

      I was able to connect the board through manual connection. These errors show up when I try to Install/Build.

       

      npm ERR! syscall getaddrinfo                                                                                                                              

      npm ERR! code ESRCH                                                                                                                                       

      npm ERR! errno ESRCH                                                                                                                                      

      npm ERR!                                                                                                                                                  

      npm ERR! Additional logging details can be found in:                                                                                                      

      npm ERR!     /home/root/.node_app_slot/npm-debug.log                                                                                                      

      npm ERR! not ok code 0                                                                                                                                    

      |================================================================                                                                                         

      |    NPM INSTALL COMPLETE![ 1 ]   [ 1 ]                                                                                                                   

      |================================================================

      has anyone faced the same error? Is there a workaround? or am i doing something wrong?

      I have been able to upload and run some other examples without a problems . looks like there is an error installing "accepts".

        • 1. Re: Error in Build/Install in Intel XDK_Iot_edition using Galileo gen 2
          Intel_Alvarado

          Hi,

           

          I’ve found some information on the getting started guide you might find useful:

          1. From the bottom toolbar, click the Manage your daemon/IoT device icon. Select Sync PC time w/ clock on target board to avoid computer and device timing issues.
          2. Click the Install/Build icon. In the dialog box that opens, click Build.
          3. To upload your project to the development board, click the Upload icon.
          4. To run your project on the device, click the Run icon. Any runtime errors in the program are displayed in the console log bar. You can show or hide the console log bar by clicking the Toggle console window icon in the bottom right.
          5. Check your board for a blinking LED.

           

          If this doesn’t work on the first try you can try:

          1. Connect to your board using a serial communication session.
          2. Enter the following commands:
          echo "src mraa-upm http://iotdk.intel.com/repos/1.1/intelgalactic" > /etc/opkg/intel-iotdk.conf
          opkg update
          opkg upgrade
          

            3. Click the Run icon again.

           

          Source: IoT - Getting started with the Intel® XDK IoT Edition | Intel® Developer Zone

           

          Let me know your results

           

          Sergio

          • 2. Re: Error in Build/Install in Intel XDK_Iot_edition using Galileo gen 2
            Lohith

            Hi,

            I did follow the IoT - Getting started with the Intel® XDK IoT Edition | Intel® Developer Zone extensively, just to make sure, I'm doing it again and the results, are as follows...

             

            Sync time:

                                                                                                                                                                        
            New System Time: Wed Sep 09 2015 05:26:25 GMT+0000 (UTC)                                                                                                    
                                                                                                                                                                        
            New System Time: Wed Sep 09 2015 05:26:41 GMT+0000 (UTC)    
            

             

            Build/Install:

            UPLOADING: Uploading project bundle to IoT device.                                                                                                          
            [ Upload Complete ]                                                                                                                                         
            Intel XDK - Message Received: install  
                                                                                                                                                                        
            |================================================================                                                                                           
            |    Intel (R) IoT - NPM Install - (may take several minutes)                                                                                               
            |================================================================                                                                                           
            npm WARN package.json websockets@0.0.0 No repository field.                                                                                                 
            npm ERR! Error: getaddrinfo ESRCH                                                                                                                           
            npm ERR!     at errnoException (dns.js:37:11)                                                                                                               
            npm ERR!     at Object.onanswer [as oncomplete] (dns.js:124:16)                                                                                             
            npm ERR! If you need help, you may report this *entire* log,                                                                                                
            npm ERR! including the npm and node versions, at:                                                                                                           
            npm ERR!     <http://github.com/npm/npm/issues>   
                                                                                                                                                                        
            npm ERR! System Linux 3.8.7-yocto-standard                                                                                                                  
            npm ERR! command "node" "/usr/bin/npm" "install" "--color=always" "--nodedir=/usr/include/node-gyp/0.10.38"                                                 
            npm ERR! cwd /home/root/.node_app_slot                                                                                                                      
            npm ERR! node -v v0.10.38                                                                                                                                   
            npm ERR! npm -v 1.4.28                                                                                                                                      
            npm ERR! syscall getaddrinfo                                                                                                                                
            npm ERR! code ESRCH                                                                                                                                         
            npm ERR! errno ESRCH                                                                                                                                        
            npm ERR!                                                                                                                                                    
            npm ERR! Additional logging details can be found in:  
            npm ERR!     /home/root/.node_app_slot/npm-debug.log                                                                                                        
            npm ERR! not ok code 0                                                                                                                                      
            |================================================================                                                                                           
            |    NPM INSTALL COMPLETE![ 1 ]   [ 1 ]                                                                                                                     
            |================================================================                                                                                           
                                                                                 
            
            
            

             

            Run:

             

             

            Below are the screen shots of the npm-debug.log:

            And every time i try opkg update, I can see a lot of files being updated, but somehow always end with this:

            * opkg_conf_parse_file: Duplicate src declaration (mraa-upm http://iotdk.intel.com/repos/1.1/intelgalactic). Skipping.

            opkg upgrade runs perfectly fine though.

            Thanks in advance, really appreciate your help.

            Regards,

            Lohith

            • 3. Re: Error in Build/Install in Intel XDK_Iot_edition using Galileo gen 2
              Lohith

              hey,

              I just reflashed the sd card, reinstalled xdk(latest), Still facing the same issue.Looks like thers's a problem with npm install accepts.

              • 4. Re: Error in Build/Install in Intel XDK_Iot_edition using Galileo gen 2
                Intel_Alvarado

                Hi,

                 

                I tried to replicate this issue. I used the Yocto image. First I ran the command:

                echo "src mraa-upm http://iotdk.intel.com/repos/1.1/intelgalactic" > /etc/opkg/intel-iotdk.conf
                

                and then opkg update.I got the exact same error as you.

                I noticed in this image that there isn’t a file called intel-iotdk.conf. The echo command created it.

                If you do a cat on both mraa-upm.conf and intel-iotdk.conf you’ll notice that the contents are the same.

                I deleted the intel-iotdk.conf with rm intel-iotdk.conf and then ran opkg update again.

                 

                This time I received no errors. Follow these steps and let me know your results.

                 

                Sergio

                • 5. Re: Error in Build/Install in Intel XDK_Iot_edition using Galileo gen 2
                  Lohith

                  hi,

                  Thanks for the speedy reply. I removed  intel-iotdk.conf . And as You said I got no errors during the update.

                  But I still face the same issue building the template. It is imperative I get it to work as my original code works on similar lines.

                  Any thoughts on that?

                  regards

                  Lohith

                  • 6. Re: Error in Build/Install in Intel XDK_Iot_edition using Galileo gen 2
                    Lohith

                    Hey,

                    I finally got it to work!!

                    I found a [Failed] Loading kernel modules when the board was booting up, maybe the my kernel modules were getting corrupted for some unknown reason.

                    Re-flashed the board one last time,then ran a few of these:

                    $ npm install -g express-generator@4

                    $ express /tmp/foo && cd /tmp/foo

                    $ npm install

                    $ npm start

                    It works!!