sudo apt-get install tftp tftpd
安装的同时会自动安装openbsb-inetd
然后建立或修改 /etc/inetd.conf 如下
#tftp dgram udp wait nobody /usr/sbin/tcpd /usr/sbin/in.tftpd /tftpboot
tftp dgram udp wait nobody /usr/sbin/tcpd /usr/sbin/in.tftpd /home/帐户/tftpboot
#:INTERNAL: Internal services
#e cho stream tcp nowait root internal
#e cho dgram udp wait root internal
#chargen stream tcp nowait root internal
#chargen dgram udp wait root internal
#discard stream tcp nowait root internal
#discard dgram udp wait root internal
#daytime stream tcp nowait root internal
#daytime dgram udp wait root internal
#time stream tcp nowait root internal
#time dgram udp wait root internal
#tftp dgram udp wait nobody /usr/sbin/tcpd/usr/sbin/in.tftpd/tftpboot
重新加载openbsb-inetd进程
sudo /etc/init.d/openbsd-inetd
在自己的帐号下建立文件夹
mkdir /home/帐户/tftpboot
chmod 777 tftpboot
测试
tptf 自己的IP地址
tptf>>get 文件名
阅读(1000) | 评论(0) | 转发(0) |