3

I am using HPA's tftp server for PXE boot. When I try downloading an image from my tftp server using curl, the transfer rate is less than 3 MB/s, even on my 1Gb network.

curl -o initrd.gz tftp://192.168.0.4:69/boot/debian/initrd.gz

Is this an inherent limitation of the tftp protocol, or can this be configured?

  • Same problem here,hpux and solaris tftp are really fast Linux tftp is ultraslow(slackware) – elbarna Dec 6 '14 at 23:54
4
  • Try to increase the maximum block size on the server (e.g. --blocksize 1468).
  • Check with server in debug mode, see if there are retransmits.
  • Check if you really have Gb connection end-to-end.
  • Test on a different client node.
  • Check if there is some other problem not related to tftp - try iperf, tcpdump, ethtool ...
  • 1
    setting --blocksize 1468 on the server alone did not help. I had to specify the block size on the client as well, i.e. curl --tftp-blksize 1468. Then I get around 6.5 MB/s. This still does not seem very impressive. With ftp, I get over 100 MB/s on the same machines. – Martin Vegter Mar 29 '14 at 11:29
2

iperf, jperf (java based iperf) and ethtool will help a ton in figuring this out!

TFTP is a "block by block" file transfer protocol which makes it a completely different beast from FTP/SFTP/FTPS. Each block that is transferred is checked(acknowledged) to make sure it made it across the link intact. If every little block of data is not perfect, those blocks get re-transmitted, slowing down your transfer considerably. I have gone up to a 16384 block size on a GB network link with no problems, but I have also had to knock that back considerably on less reliable GB links...the smaller the block size, the greater chance of a successful block transfer, thus less re-transmissions. It's a bit of a balancing act finding what works best on your network, but a little trial and error should make quick work of figuring that out!

This relates more to Windows as it involves TFTP Windowsizing (RFC 7440) to transmit more blocks at a time, but is a great guide to illustrating the process of figuring out the settings that are going to yield better transfers on your network. https://ccmexec.com/2016/09/tweaking-pxe-boot-times-in-configuration-manager-1606/

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.