TFTP(1)

๐Ÿ’– TFTP(1) ๐Ÿ’–

okay bestie, so this is the man page for tftp โ€” it lives in the User's Manual section of the manual pages, and I'm gonna walk you through every single bit of it. grab a snack, we're going in ๐Ÿ“


โœจ NAME โœจ

tftp โ€” IPv4 Trivial File Transfer Protocol client

like, that's it, that's the whole vibe. it's a client for moving files over the network. lowercase trivial, capital File Transfer Protocol, don't question it, that's the name ๐Ÿ’…


๐ŸŒธ SYNOPSIS ๐ŸŒธ

tftp [ options... ] [host [port]] [-c command]

yep. that's how you summon it. options first if you want, then maybe a host, maybe a port, and if you're feeling spicy you slap -c command at the very end. โœจ


๐Ÿฆ‹ DESCRIPTION ๐Ÿฆ‹

so tftp is a client for the Trivial File Transfer Protocol. you use it to send files to remote machines and pull files back from them, and โ€” this is the fun part โ€” it works with some very minimalistic systems, usually embedded ones. think routers, think tiny boxes, think little gizmos that don't have room for fancy things. no cap. ๐Ÿ‘‘

and here's a cute lil thing: you can put the remote host right there on the command line. if you do, tftp uses that host as the default host for all your future transfers. (the connect command below does the same job if you'd rather do it from inside the prompt, iykyk.)


โœจ OPTIONS โœจ

  • -4 โ€” IPv4 only, periodt. even if IPv6 support was compiled in, this makes it connect with IPv4 and nothing else.
  • -6 โ€” IPv6 only, if it was compiled in. (if it wasn't, well, rip ๐Ÿซถ)
  • -c command โ€” run command as if you'd typed it at the tftp prompt. heads up: it has to be the very last thing on the command line. last. final. no takebacks.
  • -l โ€” default to literal mode. this exists so that a : in a file name doesn't get special treatment. protect your colons, bestie ๐Ÿ›ก๏ธ
  • -m mode โ€” set the default transfer mode to mode. usually you'd pair this with -c. iconic duo fr fr.
  • -R port:port โ€” force the originating port number to be inside the specified range of port numbers. so like, port:port, a little range, cute.
  • -v โ€” default to verbose mode. more talking, more info.
  • -V โ€” print the version number and configuration to standard output, then exit gracefully like the main character it is. ๐ŸŽ€

๐Ÿ’… COMMANDS ๐Ÿ’…

once tftp is actually running, it gives you the prompt

tftp>

and it recognizes all these commands. here we go, one by one, no skipping:

  • ? command-name...
  • help command-name... โ€” print help information. (yes, ? and help are the same energy ๐Ÿ’–)
  • ascii โ€” shorthand for mode ascii.
  • binary โ€” shorthand for mode binary.
  • connect host [port] โ€” set the host (and if you want, the port) for transfers. and now the important lore: the TFTP protocol, unlike the FTP protocol, does not maintain connections between transfers. so connect doesn't actually create a connection โ€” it just remembers which host to use next time you transfer. it's giving "saving their name in your contacts", not "calling them". ๐Ÿ“ฑ and also โ€” you don't even have to use connect at all, because you can just say the remote host right in the get or put command. options, we love options.
  • get file
  • get remotefile localfile
  • get file1 file2 file3... โ€” get a file, or a whole set of files, from the sources you specified. a remote filename can show up in one of two forms: either a plain filename on the remote host (only if the host has already been set), or a string like host:filename to name the host AND the file at the same time. if you use that second form, the last hostname you specified becomes the default for future transfers. and psst โ€” enable literal mode if you don't want : to get special treatment (looking at you, C:\dir\file). ๐Ÿ™ˆ
  • literal โ€” toggle literal mode. when it's set, this mode prevents special treatment of : in filenames. colon protection squad, assemble. ๐Ÿ›ก๏ธ
  • mode transfer-mode โ€” choose the mode for transfers. transfer-mode can be either ascii (or netascii) or binary (or octet). the default is ascii.
  • put file
  • put localfile remotefile
  • put file1 file2 file3... remote-directory โ€” put a file, or a bunch of files, to the remote file or directory you picked. the destination comes in two forms: a filename on the remote host (if the host is already set), or a string like host:filename to name both host and filename together. if you use the second form, the hostname you specify becomes the default for future transfers. and if you use the remote-directory form, the remote host is assumed to be a UNIX system โ€” or another system that uses / as the directory separator. same deal as get: enable literal mode so : doesn't get the special treatment (again, C:\dir\file, we see you). ๐Ÿ’–
  • quit โ€” exit tftp. also, end-of-file will exit too. bye bestie ๐Ÿ‘‹
  • rexmt retransmission-timeout โ€” set the per-packet retransmission timeout, in seconds.
  • status โ€” show current status. a lil vibe check for your session โœจ
  • timeout total-transmission-timeout โ€” set the total transmission timeout, in seconds. (different from rexmt! one is per-packet, one is total. don't mix them up ๐Ÿ’€)
  • trace โ€” toggle packet tracing. it's a debugging feature. ๐Ÿ”
  • verbose โ€” toggle verbose mode. more words, more better.

๐Ÿ’€ NOTES ๐Ÿ’€

okay, serious moment, no bit:

the TFTP protocol provides no provisions for authentication or security.

so, yeah. none. zero. zilch. ๐Ÿ˜ญ because of that, the remote server will probably implement some kinds of access restriction or firewalling. and those access restrictions are likely to be site- and server-specific โ€” meaning what works on one server might just not be a thing on another. that's not a bug, that's just how it is. fr fr.


๐Ÿ‘‘ AUTHOR ๐Ÿ‘‘

this version of tftp is maintained by H. Peter Anvin <hpa@zytor.com>. ๐Ÿ’œ

it was derived from an OpenBSD source base โ€” but has substantially diverged from it โ€” and it's got added patches by Markus Gutschke and Gero Kulhman. shoutout to the whole friend group ๐Ÿซถ


๐ŸŒˆ SEE ALSO ๐ŸŒˆ

  • tftpd(8) โ€” the server side of the story, go read it bestie

and that's the whole page!! this was brought to you by tftp-hpa 5.4, dated 23 July 2008, living in section TFTP(1) of the manual. slay, go transfer some files responsibly โœจ๐ŸŽ€๐Ÿ’–

๐Ÿ“ฆ where this page comes from
  • ubuntu stonking: tftp-hpa 5.4-2 ยท BSD-4
  • ๐Ÿ“œ the page's license: BSD-4-Clause-UC
  • ๐Ÿ’– girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms