cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
689
Views
4
Helpful
3
Replies

TFTP or FTP for backup

Is there any advantage between the two?

3 Replies 3

Joseph W. Doherty
Hall of Fame
Hall of Fame

FTP generally is faster if there's much more than typical LAN latency. Some TFTP servers won't process files more than 32 MB.

Devlin

Joseph correctly identifies one possible issue with file sizes and the fact that some TFTP servers can not process files over a certain size. And he says that there is a performance difference which he seems to link to LAN latency. In fact there are greater efficiencies in FTP as compared to TFTP (TFTP uses a smaller block size than FTP and TFTP sends a single packet and must receive an acknowledgement before it can send the next packet where FTP uses windowing and can have several packets in flight before it must wait for an acknowledgement). So as the size of the file that you are transferring gets larger there are more performance advantages in using FTP rather than TFTP.

HTH

Rick

HTH

Rick

Rick is quite correct about the inherent FTP efficiencies compared to TFTP. However, the one he mentions about "in flight", usually isn't very noticable on LANs due to the minimal latency, unlike a LFN. In fact, once the sender has expanded it's send window to match the receiver's receive window, TCP (e.g. FTP) also "self clocks" on ACKs (NB: also the major reason TCP's performance can be much slower than expected on LFNs.)

Since FTP uses TCP, there are other advantages over TCP, but many of these deal with possible sequencing or lost packet issues that often are very useful across WANs, not so much over "typical" LANs.

You didn't describe what was to be backed up. If you have something like small device config files in mind, across the LAN you probably wouldn't see much performance difference between TFTP or FTP, unless saving some milliseconds was important to you. If you wanted to backup something much larger, e.g. IOS images, here I would lean toward FTP (for reasons such as Rick's or other TCP improvements), but on a LAN, if you were reading/writing to flash, flash I/O would likely be the bottleneck and you might still not see any major transfer performance difference.

Another major difference between the two, TFTP servers are much simpler to implement, primary reason, I believe, for "trivial" in the protocol name.

[edit]

BTW, another valid issue Rick raises is different block size supported between FTP and TFTP, but TFTP's 512 octet limitation is addressed by later TFTP RFCs, although being an option, I wouldn't presume both sides would support it. Although TFTP that supports > 32 MBs, i.e. TFTP Option Extension, might. (In other words, TFTP that doesn't support > 32 MBs, I believe, can't support > 512 octet blocks.)

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: