Cannot use tftp put files to server

Enable the tftp-hpa. input command "(to)" and put test.txt ,it is success.
but adding ports and input command "(to)" ,show errors(unknow host). why is that? thanks.

TCP port 21 is used for FTP

Totally different than TFTP, which uses UDP port 69.

1 Like

Thank you very much.
can I use FTP for transfer files? because my server supports FTP.
I noticed there was a wput option,but I didn't know how to use it.

transfer files where ?

TFTP is (here at this forum) mainly used for firmware installs, and nothing else.
if that's what you're doing, FTP isn't an option
if you're transferring random files, then yes, FTP is supported, and works.

Thanks. I want to transfer files(.txt format) to the cloud server in shell mode. the cloud server has port 21.
Here is the shell code, but it doesn't work. show: ftp:not found.

ftp -n<<EOF
open ...:21 #cloud server IP
user username userpwd # ftp server name and password
cd /usr/ftptemp
lcd /usr/ftptemp
put test.txt

then you need to install a FTP client, seems lftp is the one available in openwrt.

1 Like

Thank you very much. I'll try.