ubuntu14.0464bit主机中安装tftp服务器

2016.10.24:

今天在我的ubuntu14.04(64bit)主机中安装tftp服务器,并测试成功。


1.sos@sos:~$ sudo apt-get install tftpd tftp openbsd-inetd

2.sos@sos:~$ sudogedit /etc/inetd.conf

# /etc/inetd.conf: see inetd(8) for further informations.
# Internet superserver configuration database
# Lines starting with "#:LABEL:" or "#<off>#" should not
# be changed unless you kNow what you are doing!
# If you want to disable an entry so it isn't touched during
# package updates just comment it out with a single '#' character.
# Packages should modify this file by using update-inetd(8)
# <service_name> <sock_type> <proto> <flags> <user> <server_path> <args>
#:INTERNAL: Internal services
#discard stream tcp Nowait root internal
#discard dgram udp wait root internal
#daytime stream tcp Nowait root internal
#time stream tcp Nowait root internal
#:STANDARD: These are standard services.
#:BSD: Shell,login,exec and talk are BSD protocols.
#:MAIL: Mail,news and uucp services.
#:INFO: Info services
#:BOOT: TFTP service is provided primarily for booting. Most sites
# run this only on machines acting as "boot servers."
#tftp dgram udp wait nobody /usr/sbin/tcpd /usr/sbin/in.tftpd /srv/tftp
#修改如下文件
tftp dgram udp wait nobody /usr/sbin/tcpd /usr/sbin/in.tftpd /home/sns/share/tftpsever(tftp文件目录,根据需要自己创建)

#:RPC: RPC based services
#:HAM-RAdio: amateur-radio services
#:OTHER: Other services


3.sos@sos:~$ sudo mkdir /home/sns/share/tftpsever

4.sos@sos:~$ sudo chmod 777 /home/sns/share/tftpsever

5.sos@sos:~$ sudo /etc/init.d/openbsd-inetd restart

6.查看69端口是否有打开 :netstat -an | more| grep udp

sos@sos:~$ netstat -an | more | grep udp
udp 0 0 0.0.0.0:35697 0.0.0.0:*
udp 0 0 127.0.1.1:53 0.0.0.0:*
udp 0 0 0.0.0.0:69 0.0.0.0:*

7.在本机进行测试:

a. 将编译通过的uImage文件拷贝/home/sns/share/tftpsever
b. 在其他目录下测试:
    sos@sos:~$ pwd
    /home/sos
    sos@sos:~$ tftp 192.168.16.110(我主机的ip)     tftp> get uImage     Received 3019679 bytes in 0.1 seconds     tftp> q     sos@sns:~$

相关文章

目录前言一、创建Hadoop用户二、更新apt和安装Vim编辑器三、...
原文连接:https://www.cnblogs.com/yasmi/p/5192694.html ...
电脑重启后,打开VirtualBox,发现一直用的虚拟机莫名的消失...
参见:https://blog.csdn.net/weixin_38883338/article/deta...
Ubuntu 18.04 LTS 已切换到 Netplan 来配置网络接口。Netpla...
介绍每个 Web 服务都可以通过特定的 URL 在 Internet 上访问...