• tftp服务器


    1.安装tftp所需的软件

      tftp-hpa   : 是客户端软件;              sudo apt-get install tftp-hpa 
      tftpd-hpa : 是服务程序;                 sudo apt-get install tftpd-hpa
      xinetd      : 是新一代进程守护程序。       sudo apt-get install xinetd

    2.配置xinetd.conf配置文件

    进入/etc目录,首先看目录中有没有一个xinetd.conf文件,如果没有则新建一个,有的话查看其内容:

    hyx@hyx:tftp$ cat xinetd.conf

    看是否与下面的一致,内容如下所示:

    若不一致则运行如下命令,修改为相同即可。

    # Simple configuration file for xinetd
    #
    # Some defaults, and include /etc/xinetd.d/
    
    defaults
    {
    
    # Please note that you need a log_type line to be able to use log_on_success
    # and log_on_failure. The default is the following :
    # log_type = SYSLOG daemon info
    
    }
    
    includedir /etc/xinetd.d

     3.配置tftpd-hpa配置文件

    hyx@hyx:tftp$ sudo gedit /etc/default/tftpd-hpa
    # /etc/default/tftpd-hpa
    
    
    TFTP_USERNAME="tftp" 
    TFTP_DIRECTORY="/home/hyx/tftp" 
    TFTP_ADDRESS="0.0.0.0:69" 
    TFTP_OPTIONS="-l -c -s"
    chmod 777 /home/hyxtftp/

    4.配置tftp配置文件

    进入/etc下面的xinetd.d文件夹,查看是否有一个tftp文件,如果没有的话,就新建一个并输入以下内容,如果有的话就查看内容是否与下面的一致,不一致则修改,内容如下:

    service tftp
        {
           disable = no
           socket_type = dgram
           protocol = udp
           wait = yes
           user = root
           server = /usr/sbin/in.tftpd
           server_args = -s /tftpboot -c
           per_source = 11
           cps = 100 2
           flags =IPv4
        }
    hyx@hyx:service tftpd-hpa restart
    
    hyx@hyx:/etc/init.d/xinetd reload
    
    hyx@hyx:/etc/init.d/xinetd restart
  • 相关阅读:
    如何复用网页
    sap
    学习方法
    spring + ehcache 实例
    200个 jquery插件
    vs 示例代码浏览器 搜索
    struts jquery 整合
    eclipse clean 后clease 为空
    mvc相关
    css 框架
  • 原文地址:https://www.cnblogs.com/huang-y-x/p/11240959.html
Copyright © 2020-2023  润新知