• Join
  • Sign In with my.TI Login
Texas Instruments
  • Products
  • Applications
  • Tools & Software
  • Support & Community
  • Sample & Buy
  • About TI
Sample & Purchase Cart Sample & Purchase Cart
  • Search
  • Advanced
TI E2E™ Community
  • Support Forums
  • Blogs
  • Groups
  • Videos
  • 简体中文
  • More ...
TI Home » TI E2E Community » Support Forums » Embedded Software » Linux » Linux forum » virtualbox ubuntu and tftp
Share
Linux
  • Forum
Options
  • Subscribe via RSS

Forums

virtualbox ubuntu and tftp

This question is answered
oliver wilhelm
Posted by oliver wilhelm
on Apr 17 2012 08:07 AM
Prodigy180 points

Good Afternoon

If got a problem:

I've setup the boot by sd card an can startup the evm.

I'm building the helloworld regarding the "DM814x AM387x EZ 5.02 Software Developers Guide".

I put the helloworld* into the folder regarding the description there:

host $ mkdir ${HOME}/targetfs/home/root/dm814x
host $ cp helloworld ${HOME}/targetfs/home/root/dm814x

At the target I'm entering

root@dm814x-evm:~# /home/root/dm814x/helloworld

and get the answer

-sh: /home/root/dm814x/helloworld: not found

From host and target side I can ping at get the right result.

tftp file transfer is not possible. For these commands I get "tftf timed out."

timeout ist set to 60.
iptables was called with "iptables -F" before. So it should allow data handling in ay way.
 Aswell I switch of the windows firewall.

What is wrong for calling the helloworld?

Many thanks and best regards

Oliver




DaVinci ethernet Linux file system EZSDK dm8148
Report Abuse
  • Reply
You have posted to a forum that requires a moderator to approve posts before they are publicly available.
All Replies
  • Kirill Brilliantov
    Posted by Kirill Brilliantov
    on Apr 17 2012 12:29 PM
    Genius3470 points

    You create directory on host and after boot board you try run application from this directory, I am right?

    If you must run application on your board you must copy it on board or mount directory with application, e.g. on NFS.

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Anil
    Posted by Anil
    on Apr 17 2012 12:51 PM
    Expert6655 points

    Hi Oliver,

    Make sure that your copied location (directory) and accessing from the target are same.

    I have some questions here,

    Which file system you are using? NFS/SD/JFFS2?

    Does tftp server is running on your virtual machine (ubuntu)? Do you copy the helloworld application to tftp folder?

    Regards

    AnilKumar

    Please mark this Forum post as answered via the Verify Answer button below if it helps answer your question.  Thanks!

    PSP dm8148 helloworld
    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • oliver wilhelm
    Posted by oliver wilhelm
    on Apr 18 2012 02:07 AM
    Prodigy180 points

    Many thanks for your prompt reply. You
    gave me the inspiration not to take a timeout.

    What I basically not understand is the
    way how the target can find the “path” to the folder where the wanted
    application is located. What do I have to mount?

     

    What I did until now is the following:

     

    ./setup.sh

    iptables –F

    windows 7 firewall all to off

     

    File system  nfs.

     

    For the SD-card I was using

    host
    $ sudo ${EZSDK}/bin/mksdboot.sh --device /dev/sdb --sdk ${EZSDK}” as shown in
    the manuals

     

    On host xinet is used:

    host:~$ ps aux | egrep '[xi]netd'

    root      1018 
    0.0  0.0   2492   888
    ?        Ss   07:15  
    0:00 /usr/sbin/xinetd -pidfile /var/run/xinetd.pid -stayalive -inetd_compat
    -inetd_ipv6

     

    /etc/default/aftftpd

    #USE_INETD=true

    USE_INETD=false

    OPTIONS="--tftpd-timeout 300 --retry-timeout 5
    --mcast-port 1758 --mcast-addr 239.239.239.0-255 --mcast-ttl 1 --maxthread 100
    --verbose=5 /tftpboot"

     

    at “etc/xinet.d/tftp”

                   
    service tftp

    {

    protocol = udp

    port = 69

    socket_type = dgram

    wait = yes

    user = nobody

    server = /usr/sbin/in.tftpd

    server_args = -s -c /tftpboot

    disable = no

    }

     

    I’m restarting

                   
    /etc/init.d/xinetd restart

     

    /tftpboot is

                   
    drwxrwxrwx   2 nobody root  4096 2012-04-17 15:43 tftpboot/

     

    Test tftp

                   
    echo "Hello, embedded world" > /tftpboot/hello.txt

     

    ll /tftpboot

    drwxrwxrwx  2 nobody root    
    4096 2012-04-18 07:51 ./

    drwxr-xr-x 23 root  
    root     4096 2012-04-18 07:50 ../

    -rw-r--r--  1 nobody owilhelm   22
    2012-04-18 07:51 hello.txt

    -rwxr-xr-x  1 nobody owilhelm 5686 2012-04-17
    14:27 helloworld

                   

    Test tftp

    host:~$ tftp localhost

    tftp> get hello.txt

    Received 23 bytes in 0.0 seconds

    tftp> quit

     

    ~/targetfs

    drwxr-xr-x 18 owilhelm
    owilhelm       4096 2012-04-12 07:22 targetfs/

    drwxrwsrwx  3 owilhelm owilhelm 4096 2011-12-09
    13:52 home/

    drwxrwsrwx  3 owilhelm owilhelm 4096 2012-04-16
    11:39 root/

                   
    drwxrwsrwx 2 owilhelm owilhelm 4096 2012-04-16 11:40 dm814x/

                   
    and at dm814x

                                  
    -rwxrwxrwx 1 owilhelm owilhelm 5686 2012-04-16 11:40 helloworld*

     

    On target via putty or minicom

                   
    Dm814x-evm login: root

                   
    root@ Dm814x-evm:~# /home/root/dm814x/helloworld

                   
    -sh; /home/root/dm814x/helloworld: not found

     

    Many thanks

     

    Oliver

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • oliver wilhelm
    Posted by oliver wilhelm
    on Apr 18 2012 02:09 AM
    Prodigy180 points

    Many thanks for your prompt reply. You
    gave me the inspiration not to take a timeout.

    What I basically not understand is the
    way how the target can find the “path” to the folder where the wanted
    application is located. Do I have to mount anything?

     

    What I did until now is the following:

     

    ./setup.sh

    iptables –F

    windows 7 firewall all to off

     

    File system  nfs.

     

    For the SD-card I was using

    host
    $ sudo ${EZSDK}/bin/mksdboot.sh --device /dev/sdb --sdk ${EZSDK}” as shown in
    the manuals

     

    On host xinet is used:

    host:~$ ps aux | egrep '[xi]netd'

    root      1018 
    0.0  0.0   2492   888
    ?        Ss   07:15  
    0:00 /usr/sbin/xinetd -pidfile /var/run/xinetd.pid -stayalive -inetd_compat
    -inetd_ipv6

     

    /etc/default/aftftpd

    #USE_INETD=true

    USE_INETD=false

    OPTIONS="--tftpd-timeout 300 --retry-timeout 5
    --mcast-port 1758 --mcast-addr 239.239.239.0-255 --mcast-ttl 1 --maxthread 100
    --verbose=5 /tftpboot"

     

    at “etc/xinet.d/tftp”

                   
    service tftp

    {

    protocol = udp

    port = 69

    socket_type = dgram

    wait = yes

    user = nobody

    server = /usr/sbin/in.tftpd

    server_args = -s -c /tftpboot

    disable = no

    }

     

    I’m restarting

                   
    /etc/init.d/xinetd restart

     

    /tftpboot is

                   
    drwxrwxrwx   2 nobody root  4096 2012-04-17 15:43 tftpboot/

     

    Test tftp

                   
    echo "Hello, embedded world" > /tftpboot/hello.txt

     

    ll /tftpboot

    drwxrwxrwx  2 nobody root    
    4096 2012-04-18 07:51 ./

    drwxr-xr-x 23 root  
    root     4096 2012-04-18 07:50 ../

    -rw-r--r--  1 nobody owilhelm   22
    2012-04-18 07:51 hello.txt

    -rwxr-xr-x  1 nobody owilhelm 5686 2012-04-17
    14:27 helloworld

                   

    Test tftp

    host:~$ tftp localhost

    tftp> get hello.txt

    Received 23 bytes in 0.0 seconds

    tftp> quit

     

    ~/targetfs

    drwxr-xr-x 18 owilhelm
    owilhelm       4096 2012-04-12 07:22 targetfs/

    drwxrwsrwx  3 owilhelm owilhelm 4096 2011-12-09
    13:52 home/

    drwxrwsrwx  3 owilhelm owilhelm 4096 2012-04-16
    11:39 root/

                   
    drwxrwsrwx 2 owilhelm owilhelm 4096 2012-04-16 11:40 dm814x/

                   
    and at dm814x

                                  
    -rwxrwxrwx 1 owilhelm owilhelm 5686 2012-04-16 11:40 helloworld*

     

    On target via putty or minicom

                   
    Dm814x-evm login: root

                   
    root@ Dm814x-evm:~# /home/root/dm814x/helloworld

                   
    -sh; /home/root/dm814x/helloworld: not found

     

    Many thanks

     

    Oliver

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Anil
    Posted by Anil
    on Apr 18 2012 02:54 AM
    Verified Answer
    Verified by oliver wilhelm
    Expert6655 points

    Hi Oliver,

    -rwxrwxrwx 1 owilhelm owilhelm 5686 2012-04-16 11:40 helloworld*

    Why the file is helloworld* instead of helloworld?

    Can you do tftp from target?

    $ tftp -g <tftp server ip> -r hello.txt

    and

    $ tftp -g <tftp server ip> -r helloworld

    Regards

    AnilKumar

    Please mark this Forum post as answered via the Verify Answer button below if it helps answer your question.  Thanks!

    PSP TFTP
    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • oliver wilhelm
    Posted by oliver wilhelm
    on Apr 18 2012 04:05 AM
    Prodigy180 points

    Hello Anil

    Thanks for your answer.

    This command I've tried on target yesterday, too.

    I do "ifconfig eth0 192.168.0.154 netmask 255.255.255.0" on target

    The exact command I've set on target is "tftp -g 192.168.0.154 -r hello.txt". The ip is the what I get with windows command ipconfig at the host.

    For that I get "tftp: timeout".

    Regards

    Oliver

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Anil
    Posted by Anil
    on Apr 18 2012 04:22 AM
    Expert6655 points

    Hi Oliver,

    Can you answer to my first question in my previous post?

    ipaddress should be get from ubuntu not from windows, because your tftp server is running on ubuntu not on windows.

    Another way is you can install tftp server in windows and you can tftp from there.

    I think you missed out the Network bridge connection in virtualbox.

    Regards

    AnilKumar

    Please mark this Forum post as answered via the Verify Answer button below if it helps answer your question.  Thanks!

    PSP TFTP
    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • oliver wilhelm
    Posted by oliver wilhelm
    on Apr 18 2012 05:55 AM
    Prodigy180 points

    Hello Anil

    helloworld is "helloworld*" after make. I'm just using the examples out of the manual "DM814x AM387x EZ 5.02 Software Developers Guide"

    Regards

    Oliver

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Anil
    Posted by Anil
    on Apr 18 2012 06:13 AM
    Expert6655 points

    Hi Oliver,

    Can you try building with static keyword?

    linux-host$ arm-arago-linux-gnueabi-gcc -static -o helloworld helloworld.c

    Regards

    AnilKumar

    Please mark this Forum post as answered via the Verify Answer button below if it helps answer your question.  Thanks!

    PSP dm8148 helloworld
    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • oliver wilhelm
    Posted by oliver wilhelm
    on Apr 18 2012 06:55 AM
    Prodigy180 points

    Hi Anil

    nothing changed. The file is just 10 times larger.

    I've changed the network ip of ubuntu to 192.168.0.155 with netmask 255.255.255.0.

    by using command tftp -g 192.168.0.155 -r helloworld I get tftp timeout

    Regards

    Oliver

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Anil
    Posted by Anil
    on Apr 18 2012 07:08 AM
    Expert6655 points

    Hi Oliver,

    Can try these commands in you host machine (ubuntu)? You should call these from any where except /tftpboot

    linux-host$ sudo tftp 192.168.0.155

    tftp > bin

    tftp > get helloworld

    tftp > quit

    linux-host$

    Regards

    AnilKumar

    PSP TFTP
    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • oliver wilhelm
    Posted by oliver wilhelm
    on Apr 18 2012 07:17 AM
    Prodigy180 points

    Hi Anil

    the server works:

    host$ sudo tftp 192.168.0.155

    tftp> bin

    tftp> get helloworld

    Received 5686 bytes in 0.1 seconds

    tftp> quit

    Regards

    Oliver

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • oliver wilhelm
    Posted by oliver wilhelm
    on Apr 27 2012 03:11 AM
    Verified Answer
    Verified by oliver wilhelm
    Prodigy180 points

    Hello

    When I was following the intrduction of "DM814x AM387x EZ5.02Software Developers Guide" and starting setup.sh and using the outputs at the end of script I could start communication with the eval board.

    Oliver

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • ChangHoon Shin
    Posted by ChangHoon Shin
    on Jun 10 2012 21:56 PM
    Prodigy130 points

    Hello

    I got same problem.

    How did you fix it???

    chshin@chshin-desktop:~$ sudo tftp 192.168.0.189
    [sudo] password for chshin:
    tftp> bin
    tftp> get helloworld
    Received 5686 bytes in 0.0 seconds
    tftp> quit

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Anil
    Posted by Anil
    on Jun 10 2012 23:19 PM
    Expert6655 points

    Hi Shin,

    Have you followed the exact steps specified in "DM814x AM387x EZ5.02Software Developers Guide"?

    Can you try this command on board?

    $ tftp -g <tftp server ip> -r helloworld

    Regards

    AnilKumar

    Please mark this Forum post as answered via the Verify Answer button below if it helps answer your question.  Thanks!

    PSP TFTP dm8148
    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
12
TI E2E™ Community
  • Support Forums
  • Blogs
  • Videos
  • Groups
  • Site Support & Feedback
  • Settings
TI E2E™ Community Groups
  • TI University Program
  • Make the Switch
  • Microcontroller Projects
  • Motor Drive & Control
Other Communities
  • Deyisupport
  • Designsomething.org
  • beagleboard.org
  • TI on Element 14
  • TI on TechXchangeSM
Other Technical & Support Resources
  • WEBENCH® Design Center
  • Product Information Centers
  • Technical Documents
  • TI Design Network
  • TI Technical Articles
  • TI Training

All content and materials on this site are provided "as is". TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with regard to these materials, including but not limited to all implied warranties and conditions of merchantability, fitness for a particular purpose, title and non-infringement of any third party intellectual property right. TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with respect to these materials. No license, either express or implied, by estoppel or otherwise, is granted by TI. Use of the information on this site may require a license from a third party, or a license from TI.

Content on this site may contain or be subject to specific guidelines or limitations on use. All postings and use of the content on this site are subject to the Terms of Use of the site; third parties using this content agree to abide by any limitations or guidelines and to comply with the Terms of Use of this site. TI, its suppliers and providers of content reserve the right to make corrections, deletions, modifications, enhancements, improvements and other changes to the content and materials, its products, programs and services at any time or to move or discontinue any content, products, programs, or services without notice.

Follow Us Texas Instruments on Facebook Texas Instruments on Twitter Texas Instruments on LinkedIn Texas Instruments on Google+
TI Worldwide | Contact Us | my.TI Login | Site Map | Corporate Citizenship | mobile m.ti.com (Mobile Version)

TI is a global semiconductor design and manufacturing company. Innovate with 100,000+ analog ICs and
embedded processors, along with software, tools and the industry’s largest sales/support staff.

© Copyright 1995-2013 Texas Instruments Incorporated. All rights reserved.
Trademarks | Privacy Policy | Terms of Use