Difference between revisions of "Troubleshoot TFTP"

From FOG Project
Jump to: navigation, search
Line 24: Line 24:
 
Newer systems:
 
Newer systems:
  
check status
+
status/enable/start
<pre>systemctl status xinetd.service</pre>
+
<pre>systemctl status xinetd.service
enable/start
+
systemctl enable xinetd.service
<pre>systemctl enable xinetd.service
 
 
systemctl start xinetd.service</pre>
 
systemctl start xinetd.service</pre>
  

Revision as of 14:23, 15 April 2015

Testing TFTP

Create a file named test.txt with some content in /tftpboot path of the tftp server

sudo echo "Is my TFTP service working?" > /tftpboot/test.txt

Try to get the file with Linux:

tftp x.x.x.x
tftp> get test.txt
//Sent 159 bytes in 0.0 seconds
tftp> quit
cat test.txt

Try to get the file with Windows:

tftp x.x.x.x get test.txt


TFTP Service

Fedora

Newer systems:

status/enable/start

systemctl status xinetd.service
systemctl enable xinetd.service
systemctl start xinetd.service

Ubuntu


newer systems:

status/enable/start

sudo service xinetd status
sudo service xinetd restart
sudo service xinetd enable

older systems:

sudo /etc/init.d/xinetd status
sudo /etc/init.d/xinetd restart
sudo /etc/init.d/xinetd enable


Troubleshooting TFTP

To test from windows, TFTP Client must be installed and the Firewall must allow TFTP Traffic.

Control Panel -> Programs and Features -> Turn Windows Features on or off -> TFTP Client

TFTP Client in Windows.png




Checking/verifying Firewall

Disable & Stop Firewall in Fedora 21

systemctl disable firewalld.service
systemctl stop firewalld.service

Can be undone with "start" and "enable".

Check Firewall in Fedora 21

systemctl status firewalld.service


Check Firewall in Debian/Ubuntu

sudo iptables -L

If disabled, the output should look like this:

Chain INPUT (policy ACCEPT)
target prot opt source destination 

Chain FORWARD (policy ACCEPT)
target prot opt source destination 

Chain OUTPUT (policy ACCEPT)
target prot opt source destination

Temporarily disable Windows firewall

TFTP Windows Firewall.png


Permissions

Check permissions on /tftpboot directory by using:

ls -ld /tftpboot

Check permissions on files in /tftpboot directory by using:

ls -ld /tftpboot/*.*

Set permissions to allow everyone full access to /tftpboot and all contents:

chmod -R 777 /tftpboot

See example permissions below:

TFTP Permissions.png