TFTP(Trivial File Transfer Protocol,简单文件传输协议)是一个基于UDP协议的简单文件传输协议,通常用于小型文件的传输。它比FTP(File Transfer Protocol)更简单,但功能也相对有限。
TFTP:
TFTP主要有两种模式:
tftp [option]... host [port]
get
:从服务器下载文件。get
:从服务器下载文件。put
:上传文件到服务器。put
:上传文件到服务器。TFTP服务器通常通过配置文件(如 /etc/xinetd.d/tftp
或 /etc/inetd.conf
)进行设置。
原因:
解决方法:
原因:
解决方法:
tftp 192.168.1.1
tftp> get config.txt
编辑 /etc/xinetd.d/tftp
文件:
service tftp
{
socket_type = dgram
protocol = udp
wait = yes
user = nobody
server = /usr/sbin/in.tftpd
server_args = -s /var/lib/tftpboot
disable = no
}
重启xinetd服务:
sudo systemctl restart xinetd
通过以上步骤,你可以基本掌握TFTP的使用方法和常见问题解决方法。
领取专属 10元无门槛券
手把手带您无忧上云