1 2 Previous Next 25 Replies Latest reply on Aug 24, 2016 1:40 PM by Intel Corporation

    NFS server on Edison

    if

      I'd like to mount Edison directories into my Ubuntu14.04's fs. I found some discussions about how to make the Edison an nfs client, but I suppose, I need the opposite.

       

      I found a note about reconfiguring the kernel, so I bitbaked the 3.0 image, and started menuconfig, only to find nfs had been enabled in the file system section already.

       

      Yet, when I add a line in my /etc/exports file on the Edison, reboot, and try to mount it from my desktop, it will time out in about a minute with no connection. (Network connection works, I can ssh to the Edison.)

       

      Could somebody please help me to proceed?

        • 1. Re: NFS server on Edison
          Intel Corporation
          This message was posted on behalf of Intel Corporation

          Hi,

          What steps have you done so far? According to https://communities.intel.com/message/263910#263910 , only NFS client is enabled by default, not NFS server. Have you made any configurations on the client side? Do you have any type of security on the Edison that deny any other devices that try to connect?

          Looking at some information on NFS, it’s recommended to configure /etc/hosts.allow besides /etc/exports. Have you tried to configure it? You can see more information here http://www.tldp.org/HOWTO/NFS-HOWTO/server.html

          -Sergio
           

          • 2. Re: NFS server on Edison
            if

            Intel Corporation wrote:

            What steps have you done so far? According to https://communities.intel.com/message/263910#263910 , only NFS client is enabled by default, not NFS server. Have you made any configurations on the client side? Do you have any type of security on the Edison that deny any other devices that try to connect?

            I reconfigured the Edison kernel. Marked NFS V3 (it had been selected already) and NFS V4, saved the .config and rebuilt it.

            It was not easy, because the instructions I have found are quite outdated. I used these two links:

             

            Creating a Custom Linux Kernel for the Edison (release 2.1) | Shawn Hymel

            IoT - Customizing the Linux* Kernel | Intel® Software

            (Many thanks for the authors)

             

            Then with scp I copied

            ldlinux.c32  ldlinux.sys  syslinux.cfgvmlinuz

            (and the kernel modules) onto the Edison, and restarted it.

             

            However I still cannot see NFS server working on the Edison. I tried rpcinfo -p and it says:

             

            root@edison1:~# rpcinfo -p

               program vers proto   port  service

                100000    4   tcp    111  portmapper

                100000    3   tcp    111  portmapper

                100000    2   tcp    111  portmapper

                100000    4   udp    111  portmapper

                100000    3   udp    111  portmapper

                100000    2   udp    111  portmapper

             

            I am not very much into rpc, but I think it should list nfs here.

             

            I also tried showmount from my client:

            showmount -a 192.168.80.201

            clnt_create: RPC: Program not registered

             

            I looked at the link you had given, and added my host ip address in /etc/hosts.allow. (Though the link says /etc/hosts.allow and /etc/hosts/deny cause a global permission/restriction situation in the system, and I think we hit wall, way before that.)

             

            I use my office server from this laptop, so it is most likey configured well as a client.

            • 3. Re: NFS server on Edison
              Intel Corporation
              This message was posted on behalf of Intel Corporation

              It seems the issue is in the kernel configuration. Can you list all the steps you made to configure it so we can try to replicate? Please be as detailed as possible.

              -Sergio
               

              • 4. Re: NFS server on Edison
                Intel Corporation
                This message was posted on behalf of Intel Corporation

                Were you able to configure the NFS server on the Edison?

                -Sergio
                 

                • 5. Re: NFS server on Edison
                  if

                  Sorry, it took long to get away from my everyday project. I knew reproduction of the kernel konfiguration would take long, so I had to wait for a weekend to reproduce the process. Unfortunately in the meantime the Edison Yocto source on the download site has changed, and this time I could not even build it anymore. Here is what I've done so far:

                   

                  I used the following links:

                  https://software.intel.com/en-us/node/593593

                  http://shawnhymel.com/585/creating-a-custom-linux-kernel-for-the-edison/

                  http://shawnhymel.com/724/creating-a-custom-linux-kernel-for-the-edison-yocto-2-1/

                  (The "Download" chapter of the last site contains the list of tools to download, but I had had these already.)

                   

                  Download

                  Downloaded the complete image of the Edison File system from here:

                  https://software.intel.com/en-us/iot/hardware/edison/downloads

                  Link: Intel Edison Board Firmware Software Release 3.5 / Sources - GPL/LGPL source files

                  The download site redirected me to here:

                  http://iotdk.intel.com/src/3.5/edison/

                  where the file to download was: iot-devkit-yp-poky-edison-20160606.zip . Not the same image I had got the last time I downloaded it.

                   

                  I downloaded and extracted it in my Edison_BSP directory. For simplicity I mounted it to /mnt/edison.

                   

                  From here my directory tree goes like this:

                  /mnt─ edison

                              ├── iot-devkit-yp-poky-edison-20160606

                              │  ├── iot-devkit-yp-poky-edison-20160606

                              │  │  ├── build_edison

                              │  │  └── poky

                              │  └── README.edison

                              └── iot-devkit-yp-poky-edison-20160606.zip

                   

                  Build

                  Further on I followed the instructions in README.edison:

                   

                  cd iot-devkit-yp-poky-edison-20160606/poky/

                  source oe-init-build-env ../build_edison/

                  bitbake edison-image u-boot

                   

                  Entered the "poky" folder, and executed:

                   

                  source oe-init-build-env ../build_edison/

                  In the poky folder I started the build process with:

                  bitbake edison-image u-boot

                  After some 3 hours the process stopped with Error messages:

                  ERROR: Function failed: do_compile (log file is located at /mnt/edison/iot-devkit-yp-poky-edison-20160606/iot-devkit-yp-poky-edison-20160606/build_edison/tmp/work/core2-32-poky-linux/oobe/1.2.0-r0/temp/log.do_compile.928)

                  ERROR: Logfile of failure stored in: /mnt/edison/iot-devkit-yp-poky-edison-20160606/iot-devkit-yp-poky-edison-20160606/build_edison/tmp/work/core2-32-poky-linux/oobe/1.2.0-r0/temp/log.do_compile.928

                   

                  and

                   

                  ERROR: Task 1181 (/mnt/edison/iot-devkit-yp-poky-edison-20160606/iot-devkit-yp-poky-edison-20160606/build_edison/../poky/meta-intel-edison/meta-intel-edison-distro/recipes-support/oobe/oobe_1.2.0.bb, do_compile) failed with exit code '1'

                  ERROR: Function failed: do_compile (log file is located at /mnt/edison/iot-devkit-yp-poky-edison-20160606/iot-devkit-yp-poky-edison-20160606/build_edison/tmp/work/core2-32-poky-linux/xdk-daemon/0.1.4-r0/temp/log.do_compile.935)

                  The error message was about a permission problem, of npm. I tried to run log.do_compile.928 manually, but I got the same error.  After some search I found that the access to npm working directory should be reconfigured to a local directory. I tried it, when finally I got a more descriptive message, stating that in fact npm was not installed. So

                  sudo apt-get install npm

                  and started the bitbake over again.

                  However after a few hours I get another error message:

                  DEBUG: Executing python function sstate_task_prefunc

                  DEBUG: Python function sstate_task_prefunc finished

                  DEBUG: Executing python function do_package_qa

                  NOTE: DO PACKAGE QA

                  DEBUG: Executing python function read_subpackage_metadata

                  DEBUG: Python function read_subpackage_metadata finished

                  ERROR: QA Issue: xdk-daemon: The compile log indicates that host include and/or library paths were used.

                           Please check the log '/mnt/edison/iot-devkit-yp-poky-edison-20160606/iot-devkit-yp-poky-edison-20160606/build_edison/tmp/work/core2-32-poky-linux/xdk-daemon/0.1.4-r0/temp/log.do_compile' for more information. [compile-host-path]

                  I found it was not a good idea to restart an interrupted build process, so I made a clean install again, and started it - this time with npm having been installed, but the process stopped with the same error.

                  I am not into bitbake, and I have no idea how and where could I modify the configuration so that the includes and library paths would be the right ones.

                  • 6. Re: NFS server on Edison
                    Intel Corporation
                    This message was posted on behalf of Intel Corporation

                    Hi,

                    Have you already seen Section 4 of the Edison BSP http://www.intel.com/content/www/us/en/support/boards-and-kits/000005616.html ? Section 4 is about creating custom images. It includes steps how to add libraries to the correct files. It also has steps to add lib PNG to an image. Look for the NFS server package in http://recipes.yoctoproject.org/rrs/recipes/2.2/M2/ and follow the guide to have that package added to your image.

                    -Sergio
                     

                    • 7. Re: NFS server on Edison
                      fexadom

                      Hi everybody,

                       

                      Has anyone solved this problem yet? I am trying to build the iot-devkit-yp-poky-edison-20160606 image for the Edison also. My host is a Ubuntu 14 LTS machine. After running

                       

                       

                      bitbake edison-image u-boot

                       

                      and waiting for a few hours, I get this error:

                       

                      ERROR: QA Issue: xdk-daemon: The compile log indicates that host include and/or library paths were used.

                              Please check the log '/home/federico/yocto_linux_stuff/edison/iot-devkit-yp-poky-edison-20160606/build_edison/tmp/work/core2-32-poky-linux/xdk-daemon/0.1.4-r0/temp/log.do_compile' for more information. [compile-host-path]

                      ERROR: QA Issue: iotkit-comm-js: The compile log indicates that host include and/or library paths were used.

                              Please check the log '/home/federico/yocto_linux_stuff/edison/iot-devkit-yp-poky-edison-20160606/build_edison/tmp/work/core2-32-poky-linux/iotkit-comm-js/0.2.0-r0/temp/log.do_compile' for more information. [compile-host-path]

                      WARNING: QA Issue: iotkit-comm-js-mdns requires libdns_sd.so, but no providers in its RDEPENDS [file-rdeps]

                      WARNING: QA Issue: ELF binary '/home/federico/yocto_linux_stuff/edison/iot-devkit-yp-poky-edison-20160606/build_edison/tmp/work/core2-32-poky-linux/xdk-daemon/0.1.4-r0/packages-split/xdk-daemon/opt/xdk-daemon/current/node_modules/mdns/build/Release/obj.target/dns_sd_bindings.node' has relocations in .text [textrel]

                      WARNING: QA Issue: xdk-daemon requires libdns_sd.so, but no providers in its RDEPENDS [file-rdeps]

                      ERROR: QA run found fatal errors. Please consider fixing them.

                      ERROR: Function failed: do_package_qa

                      ERROR: Logfile of failure stored in: /home/federico/yocto_linux_stuff/edison/iot-devkit-yp-poky-edison-20160606/build_edison/tmp/work/core2-32-poky-linux/iotkit-comm-js/0.2.0-r0/temp/log.do_package_qa.6774

                      ERROR: Task 1117 (/home/federico/yocto_linux_stuff/edison/iot-devkit-yp-poky-edison-20160606/build_edison/../poky/meta-intel-iot-middleware/recipes-devtools/iotkit-comm-js/iotkit-comm-js_0.2.0.bb, do_package_qa) failed with exit code '1'

                      ERROR: QA run found fatal errors. Please consider fixing them.

                      ERROR: Function failed: do_package_qa

                      ERROR: Logfile of failure stored in: /home/federico/yocto_linux_stuff/edison/iot-devkit-yp-poky-edison-20160606/build_edison/tmp/work/core2-32-poky-linux/xdk-daemon/0.1.4-r0/temp/log.do_package_qa.6773

                      ERROR: Task 1171 (/home/federico/yocto_linux_stuff/edison/iot-devkit-yp-poky-edison-20160606/build_edison/../poky/meta-intel-iot-devkit/recipes-devtools/xdk-daemon/xdk-daemon_0.1.4.bb, do_package_qa) failed with exit code '1'

                       

                      Looking at the log file that error points to, I find this:

                       

                      cc1plus: warning: include location "/usr/include/nodejs/src" is unsafe for cross-compilation [-Wpoison-system-directories]

                      cc1plus: warning: include location "/usr/include/nodejs/deps/uv/include" is unsafe for cross-compilation [-Wpoison-system-directories]

                      cc1plus: warning: include location "/usr/include/nodejs/deps/v8/include" is unsafe for cross-compilation [-Wpoison-system-directories]

                       

                      I haven't been able to fix this and I am stuck now unable to build this image. Any ideas how to fix it? Also, the link to the PDF here:

                       

                      http://www.intel.com/content/www/us/en/support/boards-and-kits/000005616.html

                       

                      is broken.

                       

                      Thanks in advance for your help.

                       

                      Best regards,

                      Federico

                      • 8. Re: NFS server on Edison
                        fexadom

                        UPDATE: If someone runs into the same problem, it helps if you clean the recipe cache with bitbake -c clean. For example, I ran:

                         

                        bitbake -c clean xdk-daemon

                        bitbake -c clean iotkit-comm-js

                         

                        and then restarted the process by running again:

                         

                        bitbake edison-image u-boot

                         

                        and that fixed the problem in my case.

                         

                        Cheers!

                        • 9. Re: NFS server on Edison
                          if

                          Thanks fexadom, it is light in the tunnel. The minute I'll have 6 hours to spare, I'll try it.

                          I read all over the BSP document (http://www.intel.com/content/www/us/en/support/boards-and-kits/000005616.html) , but it did not help me to solve the problem. The build process in it, is different  from what the README recommends, but the process ends with error messages again. It is quite frustrating, because the first version I could build flawlessly.

                          • 10. Re: NFS server on Edison
                            if

                            Nop,

                            Still errors:

                             

                            ERROR: QA Issue: iotkit-comm-js: The compile log indicates that host include and/or library paths were used.

                                     Please check the log '/mnt/edison/iot-devkit-yp-poky-edison-20160606/iot-devkit-yp-poky-edison-20160606/build_edison/tmp/work/core2-32-poky-linux/iotkit-comm-js/0.2.0-r0/temp/log.do_compile' for more information. [compile-host-path]

                            WARNING: QA Issue: iotkit-comm-js-mdns requires libdns_sd.so, but no providers in its RDEPENDS [file-rdeps]

                            WARNING: QA Issue: post-install requires /bin/bash, but no providers in its RDEPENDS [file-rdeps]

                            WARNING: QA Issue: systemd-kernel-install requires /bin/bash, but no providers in its RDEPENDS [file-rdeps]

                            ERROR: QA run found fatal errors. Please consider fixing them.

                            ERROR: Function failed: do_package_qa

                            ERROR: Logfile of failure stored in: /mnt/edison/iot-devkit-yp-poky-edison-20160606/iot-devkit-yp-poky-edison-20160606/build_edison/tmp/work/core2-32-poky-linux/iotkit-comm-js/0.2.0-r0/temp/log.do_package_qa.26439

                            ERROR: Task 1117 (/mnt/edison/iot-devkit-yp-poky-edison-20160606/iot-devkit-yp-poky-edison-20160606/build_edison/../poky/meta-intel-iot-middleware/recipes-devtools/iotkit-comm-js/iotkit-comm-js_0.2.0.bb, do_package_qa) failed with exit code '1'

                            NOTE: Tasks Summary: Attempted 5006 tasks of which 4907 didn't need to be rerun and 1 failed.

                             

                            No errror in the logfile above, but plenty of warnings complaining about the include path, which is apparently wrong:

                            cc1plus: warning: include location "/usr/include/nodejs/src" is unsafe for cross-compilation [-Wpoison-system-directories]

                             

                            But no idea, how could I adjust it.

                            • 11. Re: NFS server on Edison
                              fexadom

                              Just in case, but did you make sure that you have node installed in your host system? If not install it:

                               

                              sudo apt-get install nodejs

                               

                              clean the recipes and try again. Besides that, I have no other suggestion. Good luck!

                               

                              - Federico

                              • 12. Re: NFS server on Edison
                                if

                                I have returned back to the method described in the Edison BSP document. It went quite well, except some checksum fixes. But then I got stuck with an error again:

                                 

                                ERROR: Function failed: Unpack failure for URL: 'http://downloads.sourceforge.net/sshpass/sshpass-1.05.tar.gz'

                                 

                                Log:

                                Log data follows:

                                | DEBUG: Executing python function do_unpack

                                | DEBUG: Executing python function base_do_unpack

                                | NOTE: Unpacking /mnt/edison/iot-devkit-yp-poky-edison-20160606/iot-devkit-yp-poky-edison-20160606/poky/bbcache/downloads/sshpass-1.05.tar.gz to /mnt/edison/iot-devkit-yp-poky-edison-20160606/iot-devkit-yp-poky-edison-20160606/poky/out/linux64/build/tmp/work/core2-32-poky-linux/sshpass/1.05-r0.0/

                                |

                                | gzip: stdin: not in gzip format

                                | tar: Child returned status 1

                                | tar: Error is not recoverable: exiting now

                                | DEBUG: Python function base_do_unpack finished

                                | DEBUG: Python function do_unpack finished

                                | ERROR: Function failed: Unpack failure for URL: 'http://downloads.sourceforge.net/sshpass/sshpass-1.05.tar.gz'

                                 

                                Checked the downloaded sshpass-1.05.tar.gz and it is in fact a simple html message stating:

                                ...

                                <noscript>

                                We're sorry -- the Sourceforge site is currently in Disaster Recovery mode, and currently requires

                                the use of javascript to function.  Please check back later.

                                </noscript>

                                ...

                                • 13. Re: NFS server on Edison
                                  if

                                  6 hours later I downloaded the same file with wget, tested it, and this time I could unpack what I got.

                                  After a bitbake -c clean sshpass it was running again...

                                  ...for another 10 minutes. Then:

                                   

                                  ERROR: Function failed: do_compile (log file is located at /mnt/edison/iot-devkit-yp-poky-edison-20160606/iot-devkit-yp-poky-edison-20160606/poky/out/linux64/build/tmp/work/core2-32-poky-linux/xdk-daemon/0.0.35-r0/temp/log.do_compile.20428)

                                  ERROR: Logfile of failure stored in: /mnt/edison/iot-devkit-yp-poky-edison-20160606/iot-devkit-yp-poky-edison-20160606/poky/out/linux64/build/tmp/work/core2-32-poky-linux/xdk-daemon/0.0.35-r0/temp/log.do_compile.20428

                                  Log data follows:

                                  | DEBUG: Executing shell function do_compile

                                  | /mnt/edison/iot-devkit-yp-poky-edison-20160606/iot-devkit-yp-poky-edison-20160606/poky/out/linux64/build/tmp/work/core2-32-poky-linux/xdk-daemon/0.0.35-r0/temp/run.do_compile.20428: 125: [: i586: unexpected operator

                                  | npm WARN package.json keepAlive@ No repository field.

                                  | ncp@0.5.1 node_modules/ncp

                                  |

                                  | promise@5.0.0 node_modules/promise

                                  | └── asap@1.0.0

                                  | npm WARN package.json IoT_App_Daemon@ No repository field.

                                  | npm WARN package.json IoT_App_Daemon@ No README data

                                  |

                                  | > ws@0.4.31 install /mnt/edison/iot-devkit-yp-poky-edison-20160606/iot-devkit-yp-poky-edison-20160606/poky/out/linux64/build/tmp/work/core2-32-poky-linux/xdk-daemon/0.0.35-r0/xdk-daemon-0.0.35/current/node_modules/ws

                                  | > (node-gyp rebuild 2> builderror.log) || (exit 0)

                                  |

                                  |

                                  | > mdns@2.2.8 install /mnt/edison/iot-devkit-yp-poky-edison-20160606/iot-devkit-yp-poky-edison-20160606/poky/out/linux64/build/tmp/work/core2-32-poky-linux/xdk-daemon/0.0.35-r0/xdk-daemon-0.0.35/current/node_modules/mdns

                                  | > node-gyp rebuild

                                  |

                                  | Usage: gyp_main.py [options ...] [build_file ...]

                                  |

                                  | gyp_main.py: error: no such option: --no-parallel

                                  | gyp ERR! configure error

                                  | gyp ERR! stack Error: `gyp` failed with exit code: 2

                                  | gyp ERR! stack     at ChildProcess.onCpExit (/mnt/edison/iot-devkit-yp-poky-edison-20160606/iot-devkit-yp-poky-edison-20160606/poky/out/linux64/build/tmp/sysroots/x86_64-linux/usr/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:343:16)

                                  | gyp ERR! stack     at ChildProcess.emit (events.js:98:17)

                                  | gyp ERR! stack     at Process.ChildProcess._handle.onexit (child_process.js:820:12)

                                  | gyp ERR! System Linux 3.19.0-64-generic

                                  | gyp ERR! command "node" "/mnt/edison/iot-devkit-yp-poky-edison-20160606/iot-devkit-yp-poky-edison-20160606/poky/out/linux64/build/tmp/sysroots/x86_64-linux/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"

                                  | gyp ERR! cwd /mnt/edison/iot-devkit-yp-poky-edison-20160606/iot-devkit-yp-poky-edison-20160606/poky/out/linux64/build/tmp/work/core2-32-poky-linux/xdk-daemon/0.0.35-r0/xdk-daemon-0.0.35/current/node_modules/mdns

                                  | gyp ERR! node -v v0.10.38

                                  | gyp ERR! node-gyp -v v1.0.1

                                  | gyp ERR! not ok

                                  |

                                  | npm ERR! mdns@2.2.8 install: `node-gyp rebuild`

                                  | npm ERR! Exit status 1

                                  | npm ERR!

                                  | npm ERR! Failed at the mdns@2.2.8 install script.

                                  | npm ERR! This is most likely a problem with the mdns package,

                                  | npm ERR! not with npm itself.

                                  | npm ERR! Tell the author that this fails on your system:

                                  | npm ERR!     node-gyp rebuild

                                  | npm ERR! You can get their info via:

                                  | npm ERR!     npm owner ls mdns

                                   

                                  Investigation starts again.

                                  Not really a flawless process....

                                   

                                  I started a new search about gyp complaining about the --no-parallel option.

                                  It seems like it was introduced in a later version of gyp, but Ubuntu 14.04 repo contains an older one, which cannot interpret this option.
                                  I removed gyp with

                                  sudo apt-get --purge remove gyp

                                  and finally the build process went all the way.

                                   

                                  Now comes the interesting part: configure the kernel, install nfs in it, rebuild and flash it.

                                   

                                  Kernel configuration:

                                   

                                  Kernel configuration:

                                   

                                  in poky/out/linux64/build I issued:

                                  bitbake virtual/kernel -c menuconfig

                                   

                                  File Systems ---> Network File Systems --->

                                  <*>   NFS server support                                         │ │

                                    │ │    -*-     NFS server support for NFS version 3                     │ │

                                    │ │    [*]       NFS server support for the NFSv3 ACL protocol extension│ │

                                    │ │    [*]     NFS server support for NFS version 4 

                                   

                                  Then Save and Exit.

                                   

                                  The Path names in the BSP document don't match at all, so I did a search to find the .config with:

                                  find tmp/ -mmin -5

                                  which found the new .config here:

                                  tmp/work/edison-poky-linux/linux-externalsrc/1.0-r2/linux-externalsrc-1.0/.config

                                   

                                  Then the BSP document says:

                                  " When the configuration is completed, replace defconfig with .config, then rename it back to defconfig. We also

                                  suggest taking a backup of the defconfig file. Force bitbake to copy the modified defconfig file to the actual build

                                  directory. Then the new image with modified kernel is ready to build."

                                   

                                  This does not make too much sense for me. The path names in the document are totally different from the SDK  path names, and when I searched for defconfig I found dozens of it.

                                   

                                  Which is the valid one used by the kernel build process? After another couple of days spent with the build, it would be nice if someone could help me.

                                  • 14. Re: NFS server on Edison
                                    Intel Corporation
                                    This message was posted on behalf of Intel Corporation

                                    Hi if,

                                    Thank you for the detailed description of the process you’ve followed so far. We’ll definitively try to help you solve this issue. We’ll run some tests, compare our results and then come back to you.

                                    -Sergio 
                                     

                                    1 2 Previous Next