1.安装tftp服务客户端
sudo apt-get install tftp

2.安装tftp服务器端
sudo apt-get install tftpd

3.安装xinetd
注意同类似的还有openbsd-inetd和inetutils-inetd,而netkit-inetd是不存在的,是个虚拟包
sudo apt-get install xinetd

4.建立tftp目录
cd /
sudo mkdir tftpboot
sudo chmod 777 tftpboot
 
5.配置xinetd及tftp
在/etc/inetd.conf中加入如下一行:
tftp        dgram    udp    wait    nobody    /usr/sbin/tcpd    /usr/sbin/in.tftpd /tftpboot

编辑/etc/xinetd.d/tftp文件
-------------------------------
service tftp
{
    socket_type     =dgram
    protocol        =udp
    wait            =yes
    user            =root
    server          =/usr/sbin/in.tftpd
    server_args     =-s /tftpboot
    disable         =no
    per_source      = 11
    cps             = 100 2
    flags        = IPv4
}
-------------------------------

6.重启xinetd
sudo /etc/init.d/xinetd reload

7.测试tftp

cd /tftpboot
touch aaa

然后在另一个文件夹中
cd ~
tftp localhost
$tftp->get aaa
$tftp->q

 

http://blog.sina.com.cn/s/blog_8738908f0100v864.html

相关文章:

  • 2021-07-12
  • 2021-05-30
  • 2021-05-17
  • 2022-01-11
  • 2022-12-23
  • 2022-12-23
  • 2022-03-01
  • 2021-07-25
猜你喜欢
  • 2021-08-01
  • 2021-08-11
  • 2022-12-23
  • 2021-06-26
  • 2021-12-29
  • 2021-08-26
相关资源
相似解决方案