This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

NFS setup and TFTP setup failed with processor SDK linux setup script

Hi,

I am trying to run the setup.sh script, which I get from "processor SDK Linux Getting Started Guide step 4" to set up NFS and TFTP for beaglebone black board, in order that beaglebone black boots from TFTP and NFS on the host. The whole setup process looks no errors, besides the setup script asks to select kernel images in /tftproot, I expect to see zImage, but it provides zImage-am3w35x-evm.bin instead (I manually copy zImage to /tftproot). After the setup is completed, I don't see the target file system mounted on the host. I have tried number of times, but still get the same failure.

Any help will be appreciated.

  • Hi Bruce,

    Which AM335x TI SDK you are using? 02_00_02_11 or older?

    Regards,
    Pavel
  • Hi Pavel,

    I am using ti-processor-sdk-linux-am335x-evm-02.00.01.07-Linux-x86-Install.bin

    Thanks,

    Bruce

  • Bruce,

    Bruce Gao said:
    The whole setup process looks no errors, besides the setup script asks to select kernel images in /tftproot, I expect to see zImage, but it provides zImage-am3w35x-evm.bin instead

    This is not an issue. The zImage-am335x-evm.bin comes from the {SDK}/board-support/prebuilt-images/ folder. You can use it or rename it to zImage. You can also create your own zImage (from the linux kernel source) and place it in /tftproot

    Bruce Gao said:
    After the setup is completed, I don't see the target file system mounted on the host. I have tried number of times, but still get the same failure.

    Can you provide me full console log when you run setup.sh? I can see the target file system mounted on my host Ubuntu 12.04:

    pbotev@mms-0306:~/AM335x/ti-processor-sdk-linux-am335x-evm-02.00.01.07/targetNFS$ ls
    bin  boot  dev  etc  home  include  lib  media  mnt  opt  proc  run  sbin  srv  sys  tmp  usr  var  www

    BR
    Pavel

  • Hi Pavel,

    Thanks for your response. I am trying to collect the logs, what part of logs are you more interested?

    I have some other questions:

    1. how do you mount NSF from target board (beagbone black for my case) after you run setup.sh?

    2. What changes do you make on your host during NFS setup? I add one line of code to /etc/exports

    /home/bruce/ti-processor-sdk-linux-am335x-evm-02.00.01.07/targetNFS *(rw,nohide,insecure,no_subtree_check,async,no_root_squash)

    I am running ubuntu 14.04.1  on Oracle VM VirtualBox as host. 

    Thanks,

  • Bruce Gao said:
    I am trying to collect the logs, what part of logs are you more interested?

    It is only one log. I am interested in the setup.sh output log.

    Bruce Gao said:
    1. how do you mount NSF from target board (beagbone black for my case) after you run setup.sh?

    You need to pass the targetNFS path to your boot arguments in u-boot. The setup.sh script provide you the correct boot arguments for the targetNFS.

    Bruce Gao said:
    2. What changes do you make on your host during NFS setup?

    None. No changes are needed, the setup.sh script configures targetNFS enough and correct.

    Regards,
    Pavel

  • Hi Pavel,

    Below is output log when I ran ./setup.sh

    ///////////////////////////////////////////////////////////////////////
    bruce@bruce-VirtualBox:~/ti-processor-sdk-linux-am335x-evm-02.00.01.07$ sudo ./setup.sh
    [sudo] password for bruce:
    -------------------------------------------------------------------------------
    TISDK setup script
    This script will set up your development host for SDK development.
    Parts of this script require administrator priviliges (sudo access).
    -------------------------------------------------------------------------------

    --------------------------------------------------------------------------------
    Verifying Linux host distribution
    Ubuntu 12.04 LTS and Ubuntu 14.04 LTS is being used, continuing..
    --------------------------------------------------------------------------------

    Starting with Ubuntu 12.04 serial devices are only accessible by members of the 'dialout' group.
    A user must be apart of this group to have the proper permissions to access a serial device.

    Are you running this script using sudo? The detected username is 'root'.
    Verify and enter your Linux username below
    [ root ] root

    User 'root' is already apart of the 'dialout' group

    -------------------------------------------------------------------------------
    setup package script
    This script will make sure you have the proper host support packages installed
    This script requires administrator priviliges (sudo access) if packages are to be installed.
    -------------------------------------------------------------------------------
    System has required packages!
    --------------------------------------------------------------------------------
    Package verification and installation successfully completed
    --------------------------------------------------------------------------------
    --------------------------------------------------------------------------------
    In which directory do you want to install the target filesystem?(if this directory does not exist it will be created)
    [ /home/bruce/ti-processor-sdk-linux-am335x-evm-02.00.01.07/targetNFS ]
    --------------------------------------------------------------------------------

    --------------------------------------------------------------------------------
    This step will extract the target filesystem to /home/bruce/ti-processor-sdk-linux-am335x-evm-02.00.01.07/targetNFS

    Note! This command requires you to have administrator priviliges (sudo access)
    on your host.
    Press return to continue
    /home/bruce/ti-processor-sdk-linux-am335x-evm-02.00.01.07/targetNFS already exists
    (r) rename existing filesystem (o) overwrite existing filesystem (s) skip filesystem extraction
    [r] o
    Old /home/bruce/ti-processor-sdk-linux-am335x-evm-02.00.01.07/targetNFS removed

    Successfully extracted tisdk-rootfs-image-am335x-evm.tar.gz to /home/bruce/ti-processor-sdk-linux-am335x-evm-02.00.01.07/targetNFS
    --------------------------------------------------------------------------------

    --------------------------------------------------------------------------------
    This step will set up the SDK to install binaries in to:
    /home/bruce/ti-processor-sdk-linux-am335x-evm-02.00.01.07/targetNFS/home/root/am335x-evm

    The files will be available from /home/root/am335x-evm on the target.

    This setting can be changed later by editing Rules.make and changing the
    EXEC_DIR or DESTDIR variable (depending on your SDK).

    Press return to continue
    Rules.make edited successfully..
    --------------------------------------------------------------------------------

    --------------------------------------------------------------------------------
    This step will export your target filesystem for NFS access.

    Note! This command requires you to have administrator priviliges (sudo access)
    on your host.
    Press return to continue
    /home/bruce/ti-processor-sdk-linux-am335x-evm-02.00.01.07/targetNFS already NFS exported, skipping..

    * Stopping NFS kernel daemon [ OK ]
    * Unexporting directories for NFS kernel daemon... [ OK ]
    * Exporting directories for NFS kernel daemon... [ OK ]
    * Starting NFS kernel daemon [ OK ]
    --------------------------------------------------------------------------------
    --------------------------------------------------------------------------------
    Which directory do you want to be your tftp root directory?(if this directory does not exist it will be created for you)
    [ /tftpboot ]
    --------------------------------------------------------------------------------

    --------------------------------------------------------------------------------
    This step will set up the tftp server in the /tftpboot directory.

    Note! This command requires you to have administrator priviliges (sudo access)
    on your host.
    Press return to continue

    /tftpboot already exists, not creating..

    /tftpboot/zImage-am335x-evm.bin already exists. The existing installed file can be renamed and saved under the new name.
    (r) rename (o) overwrite (s) skip copy
    [r] s
    Skipping copy of zImage-am335x-evm.bin, existing version will be used

    /tftpboot/am335x-boneblack.dtb already exists. The existing installed file can be renamed and saved under the new name.
    (o) overwrite (s) skip copy
    [o] s
    Skipping copy of am335x-boneblack.dtb, existing version will be used

    /tftpboot/am335x-bone.dtb already exists. The existing installed file can be renamed and saved under the new name.
    (o) overwrite (s) skip copy
    [o] s
    Skipping copy of am335x-bone.dtb, existing version will be used

    /tftpboot/am335x-evm.dtb already exists. The existing installed file can be renamed and saved under the new name.
    (o) overwrite (s) skip copy
    [o] s
    Skipping copy of am335x-evm.dtb, existing version will be used

    /tftpboot/am335x-evmsk.dtb already exists. The existing installed file can be renamed and saved under the new name.
    (o) overwrite (s) skip copy
    [o] s
    Skipping copy of am335x-evmsk.dtb, existing version will be used

    /etc/xinetd.d/tftp already exists..
    /tftpboot already exported for TFTP, skipping..

    Restarting tftp server
    * Stopping internet superserver xinetd [ OK ]
    * Starting internet superserver xinetd [ OK ]
    --------------------------------------------------------------------------------

    --------------------------------------------------------------------------------"
    This step will set up minicom (serial communication application) for
    SDK development


    For boards that contain a USB-to-Serial converter on the board such as:
    * BeagleBone
    * Beaglebone Black
    * AM335x EVM-SK
    * AM57xx EVM
    * K2H, K2L, and K2E EVMs

    the port used for minicom will be automatically detected. By default Ubuntu
    will not recognize this device. Setup will add a udev rule to
    /etc/udev/ so that from now on it will be recognized as soon as the board is
    plugged in.

    For other boards, the serial will defualt to /dev/ttyS0. Please update based
    on your setup.

    --------------------------------------------------------------------------------


    NOTE: If your using any of the above boards simply hit enter
    and the correct port will be determined automatically at a
    later step. For all other boards select the serial port
    that the board is connected to.
    Which serial port do you want to use with minicom?
    [ /dev/ttyS0 ] /dev/ttyUSB0

    Copied existing /home/bruce/.minirc.dfl to /home/bruce/.minirc.dfl.old

    Configuration saved to /home/bruce/.minirc.dfl. You can change it further from inside
    minicom, see the Software Development Guide for more information.
    --------------------------------------------------------------------------------

    --------------------------------------------------------------------------------
    This step will set up the U-Boot variables for booting the EVM.

    Autodetected the following ip address of your host, correct it if necessary
    [ 10.90.0.219
    10.0.3.15 ]

    Select Linux kernel location:
    1: TFTP
    2: SD card

    [ 1 ] 1

    Select root file system location:
    1: NFS
    2: SD card

    [ 1 ] 1

    Available kernel images in /tftproot:
    am335x-bone.dtb
    am335x-boneblack.dtb
    am335x-evm.dtb
    am335x-evmsk.dtb
    zImage
    zImage-am335x-evm.bin

    Which kernel image do you want to boot from TFTP?
    [ zImage-am335x-evm.bin ] zImage
    --------------------------------------------------------------------------------
    Would you like to create a minicom script with the above parameters (y/n)?
    [ y ] y

    Successfully wrote /home/bruce/ti-processor-sdk-linux-am335x-evm-02.00.01.07/bin/setupBoard.minicom

    A BeagleBone (Black) or StarterKit board has been detected
    Do you want to configure U-Boot for one of the boards mentioned
    above? An answer of 'n' will configure U-Boot for the
    General Purpose EVM instead
    (y/n)
  • "After the setup is completed, I don't see the target file system mounted on the host."

    Here it is:

    Bruce Gao said:
    Successfully extracted tisdk-rootfs-image-am335x-evm.tar.gz to /home/bruce/ti-processor-sdk-linux-am335x-evm-02.00.01.07/targetNFS

    BR
    Pavel

  • Hi Pavel,

    Thank you very much for your help.

    Bruce
  • Hi Pavel,

    I have tried to use following command to pass the targetNFS path to your boot arguments in u-boot:

    setenv serverip <your host ip>

    setenv rootpath <SDK path>/trainingNFS

    setenv bootfile zImage

    setenv ip_method dhcp

    setenv nfs_bootfile 'nfs ${loadaddr} ${serverip}:${rootpath}${bootdir}/${bootfile}'

    setenv nfs_fdtfile 'nfs ${fdtaddr} ${serverip}:${rootpath}${bootdir}/${fdtfile}'

    setenv bootcmd 'setenv autoload no; dhcp; run nfs_bootfile; run findfdt; run nfs_fdtfile; run netargs; bootz ${loadaddr} - ${fdtaddr}'

    which comes from processors.wiki.ti.com/.../Processor_SDK_Linux_Training:_Introduction_to_Device_Driver_Development

    but it failed. I am wondering how you pass the targetNFS to boot argument in u-boot.

    In my case, I am using the created SDK SD card to boot beaglebone black.

    Thanks for your help.

     

  • Bruce,

    The wiki page you pointed is valid when no setup.sh script is used and you have to make the things manually. The setup.sh script set up the u-boot variables in {SDK}/bin/setupBoard.minicom file. When you run the setup.sh script, you will see this message "This step will set up the U-Boot variables for booting EVM". Follow the instructions of the setup.sh script after you see this message.

    Regards,
    Pavel