[[PageOutline]] = TFTP Server = A TFTP server is required for many steps involving gateworks boards. It sometimes is not trivial. '''Please use google to search around on instructions!.''' Here are some examples. == Windows TFTP == 1. Setup a TFTP server. If you are using a Windows machine you will need to install a TFTP server program such as TFTP32.EXE by Philippe Jounin. This program is an open source TFTP server which can be downloaded from:[[BR]][[BR]] [http://tftpd32.jounin.net/][[BR]][[BR]] [http://www.pcwdld.com/top-10-free-tftp-servers Other Free TFTP Servers for Windows][[BR]][[BR]] 2. On the TFTP server computer/laptop configure the IP address to: 192.168.3.1/ 255.255.255.0. Additionally, copy the needed files to your local TFTP32 directory (or whatever directory the TFTP server uses). Troubleshooting: * '''Please note, you will also need to turn off your Windows firewall or security program to allow access to the TFTP server.''' * May be necessary to go into tftpd64 and set the “Use anticipation window” to 65535 Bytes == Linux TFTP == Here are a few tutorials that may help with setting up a Linux TFTP Server.[[BR]] Notes: * The user may have to be set as a parameter user = root Links: * [http://www.cyberciti.biz/faq/install-configure-tftp-server-ubuntu-debian-howto/] * [https://linuxlink.timesys.com/docs/linux_tftp] === tftpd-hpa === Very popular TFTP server (recommended) Install the software on a Linux Desktop machine: {{{ sudo apt-get install tftpd-hpa }}} Modify the config file for the TFTP server software (/etc/default/tftpd-hpa) and set the directory to anything where you would like to host the files (example /var/www/html/tftpboot) {{{ # /etc/default/tftpd-hpa TFTP_USERNAME="tftp" TFTP_DIRECTORY="/var/www/html/tftpboot" TFTP_ADDRESS="0.0.0.0:69" TFTP_OPTIONS="--secure" }}} Be sure the tftpboot directory has modified permissions and ownership: {{{ sudo mkdir /var/www/html/tftpboot sudo chmod -R 777 /var/www/html/tftpboot sudo chown -R nobody /var/www/html/tftpboot }}} To start: {{{ test@test:~$ sudo service tftpd-hpa restart tftpd-hpa stop/waiting tftpd-hpa start/running, process 20566 }}} Running {{{ test@test:~$ ps -aef | grep tftp root 20566 1 0 2014 ? 00:00:00 /usr/sbin/in.tftpd --listen --user tftp --address 0.0.0.0:69 --secure /tftpboot }}} === atftpd === A common TFTP server Gateworks has used is '''atftpd''' (example shown on Ubuntu 12.10) {{{ sudo apt-get install atftpd }}} Modify the config file (/etc/default/atftpd) to below (where /tftpboot is the directory where files are placed, this can be changed to anything...): {{{ USE_INETD=false OPTIONS="--tftpd-timeout 300 --retry-timeout 5 --port=69 --maxthread 100 --verbose=7 /tftpboot" }}} Be sure the tftpboot directory has modified permissions and ownership: {{{ sudo mkdir /tftpboot sudo chmod -R 777 /tftpboot sudo chown -R nobody /tftpboot }}} To start and restart the service: {{{ sudo /etc/init.d/atftpd restart }}} To confirm the service is running: {{{ ryan@Ryan:/tftpboot$ ps -aef | grep atftpd nobody 4538 1 0 10:51 ? 00:00:00 /usr/sbin/atftpd --daemon --tftpd-timeout 300 --retry-timeout 5 --port=69 --maxthread 100 --verbose=7 /tftpboot }}} These are a set of guidelines. If your server is not starting, Gateworks encourages you to leverage the internet and google search regarding atftpd to get it up and running properly. A discussion: [http://askubuntu.com/questions/130231/tftp-server-atftpd-fails-to-start] == Troubleshooting == * Linux * It is possible to see the message below: {{{ ERROR: Need valid 'usbnet_devaddr' to be set }}} * This indeed is not a error. The bootloader tries the ethernet first. If there is anything wrong with the ethernet, it then tries to move to USB Ethernet. USB Ethernet most likely is not configured, and thus the message simply says 'it needs to be set'. * Verify the TFTP server is running on the Linux Desktop / Server * Verify with a ping the connection between the Gateworks SBC and TFTP server * Verify file permissions in the TFTP directory.