When you need to update the core firmware on an old enterprise network router, or install an operating system onto a diskless computer over the local network (PXE boot), you cannot use a modern web browser or standard FTP. These deeply embedded hardware systems possess incredibly low memory and processing power, requiring an incredibly lightweight, bare-bones communication protocol. To interface with these devices and push or pull files across the network, you must use the tftp (Trivial File Transfer Protocol) command-line client.
How the tftp Command Works
Unlike standard FTP or secure SFTP, the Trivial File Transfer Protocol relies entirely on UDP packets rather than TCP connections. This makes it incredibly fast and lightweight, but utterly devoid of any security. It does not support encryption, and it does not even support basic usernames or passwords. It should only be used on a highly secure, private Local Area Network (LAN).
To connect to a TFTP server running on a network router at IP address 192.168.1.1, open your terminal and run:
tftp 192.168.1.1
Your terminal prompt will instantly change to a dedicated tftp> interface. Because the protocol is so lightweight, it does not actually check if the server exists until you attempt a data transfer.
How to Download (Pull) a File
Because TFTP is completely stripped down, it does not support advanced directory listing tools. You cannot run ls to see what files are on the server; you must already know the exact, specific filename you wish to retrieve.
If you want to download the router’s current configuration file (named router_config.bin), type the following command into the prompt:
get router_config.bin
The client will fire a UDP packet requesting the file. If the file exists, it will instantly download it into the directory on your local machine where you originally launched the tftp command.
How to Upload (Push) a File
If you have modified the configuration file locally and you need to push the updated firmware back onto the router hardware, you use the put command.
Ensure the file is located in your current working directory, and type:
put updated_firmware.bin
The client will blindly stream the file data via UDP directly to the remote router. Once the transfer is fully completed, type quit to cleanly exit the TFTP interface and return to your standard bash prompt.