更新后tftpd-hpa无法启动

Sonex

我已经安装了tftpd-hpa(Ubuntu 16.04 LTS)。最近,也许在进行了一些更新(或卸载了具有大量依赖关系的应用程序)之后,tftpd-hpa不再启动。tftpd-hpa设置是:

TFTP_USERNAME="tftp"
TFTP_DIRECTORY="/var/lib/tftpboot"
TFTP_ADDRESS=":69"
TFTP_OPTIONS="--secure --create"

默认的根目录是/var/lib/tftpbootsystemctl status tftpd-hpa.servicejournalctl -xe命令的输出

testlab@Amtek:~$ systemctl status tftpd-hpa.service
● tftpd-hpa.service - LSB: HPA's tftp server
   Loaded: loaded (/etc/init.d/tftpd-hpa; bad; vendor preset: enabled)
   Active: failed (Result: exit-code) since Tue 2017-04-18 01:47:32 EEST; 2min 8
     Docs: man:systemd-sysv-generator(8)
  Process: 4764 ExecStart=/etc/init.d/tftpd-hpa start (code=exited, status=71)

Apr 18 01:47:32 Amtek systemd[1]: Stopped LSB: HPA's tftp server.
Apr 18 01:47:32 Amtek systemd[1]: Starting LSB: HPA's tftp server...
Apr 18 01:47:32 Amtek tftpd-hpa[4764]:  * Starting HPA's tftpd in.tftpd
Apr 18 01:47:32 Amtek in.tftpd[4777]: cannot bind to local IPv4 socket: Addre
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Control process exited, 
Apr 18 01:47:32 Amtek systemd[1]: Failed to start LSB: HPA's tftp server.
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Unit entered failed stat
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Failed with result 'exit
lines 1-14/14 (END)

testlab@Amtek:~$ journalctl -xe
-- 
-- Unit tftpd-hpa.service has finished shutting down.
Apr 18 01:47:32 Amtek systemd[1]: Starting LSB: HPA's tftp server...
-- Subject: Unit tftpd-hpa.service has begun start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit tftpd-hpa.service has begun starting up.
Apr 18 01:47:32 Amtek tftpd-hpa[4764]:  * Starting HPA's tftpd in.tftpd
Apr 18 01:47:32 Amtek in.tftpd[4777]: cannot bind to local IPv4 socket: Addre
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Control process exited, 
Apr 18 01:47:32 Amtek systemd[1]: Failed to start LSB: HPA's tftp server.
-- Subject: Unit tftpd-hpa.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit tftpd-hpa.service has failed.
-- 
-- The result is failed.
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Unit entered failed stat
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Failed with result 'exit
Apr 18 01:47:32 Amtek polkitd(authority=local)[885]: Unregistered Authenticat
Apr 18 01:48:46 Amtek kernel: [drm:intel_pipe_update_end [i915]] *ERROR* Atom
lines 1276-1298/1298 (END)
-- 
-- Unit tftpd-hpa.service has finished shutting down.
Apr 18 01:47:32 Amtek systemd[1]: Starting LSB: HPA's tftp server...
-- Subject: Unit tftpd-hpa.service has begun start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit tftpd-hpa.service has begun starting up.
Apr 18 01:47:32 Amtek tftpd-hpa[4764]:  * Starting HPA's tftpd in.tftpd
Apr 18 01:47:32 Amtek in.tftpd[4777]: cannot bind to local IPv4 socket: Addres
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Control process exited, c
Apr 18 01:47:32 Amtek systemd[1]: Failed to start LSB: HPA's tftp server.
-- Subject: Unit tftpd-hpa.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit tftpd-hpa.service has failed.
-- 
-- The result is failed.
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Unit entered failed state
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Failed with result 'exit-
Apr 18 01:47:32 Amtek polkitd(authority=local)[885]: Unregistered Authenticati
Apr 18 01:48:46 Amtek kernel: [drm:intel_pipe_update_end [i915]] *ERROR* Atomi
lines 1276-1298/1298 (END)
-- 
-- Unit tftpd-hpa.service has finished shutting down.
Apr 18 01:47:32 Amtek systemd[1]: Starting LSB: HPA's tftp server...
-- Subject: Unit tftpd-hpa.service has begun start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit tftpd-hpa.service has begun starting up.
Apr 18 01:47:32 Amtek tftpd-hpa[4764]:  * Starting HPA's tftpd in.tftpd
Apr 18 01:47:32 Amtek in.tftpd[4777]: cannot bind to local IPv4 socket: Address already in use
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Control process exited, code=exited status=71
Apr 18 01:47:32 Amtek systemd[1]: Failed to start LSB: HPA's tftp server.
-- Subject: Unit tftpd-hpa.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit tftpd-hpa.service has failed.
-- 
-- The result is failed.
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Unit entered failed state.
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Failed with result 'exit-code'.
Apr 18 01:47:32 Amtek polkitd(authority=local)[885]: Unregistered Authentication Agent for unix-process:4752:17293
Apr 18 01:48:46 Amtek kernel: [drm:intel_pipe_update_end [i915]] *ERROR* Atomic update failure on pipe A (start=58
lines 1276-1298/1298 (END)
-- 
-- Unit tftpd-hpa.service has finished shutting down.
Apr 18 01:47:32 Amtek systemd[1]: Starting LSB: HPA's tftp server...
-- Subject: Unit tftpd-hpa.service has begun start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit tftpd-hpa.service has begun starting up.
Apr 18 01:47:32 Amtek tftpd-hpa[4764]:  * Starting HPA's tftpd in.tftpd
Apr 18 01:47:32 Amtek in.tftpd[4777]: cannot bind to local IPv4 socket: Address already in use
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Control process exited, code=exited status=71
Apr 18 01:47:32 Amtek systemd[1]: Failed to start LSB: HPA's tftp server.
-- Subject: Unit tftpd-hpa.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit tftpd-hpa.service has failed.
-- 
-- The result is failed.
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Unit entered failed state.
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Failed with result 'exit-code'.
Apr 18 01:47:32 Amtek polkitd(authority=local)[885]: Unregistered Authentication Agent for unix-process:4752:172933
Apr 18 01:48:46 Amtek kernel: [drm:intel_pipe_update_end [i915]] *ERROR* Atomic update failure on pipe A (start=585
lines 1276-1298/1298 (END)
-- 
-- Unit tftpd-hpa.service has finished shutting down.
Apr 18 01:47:32 Amtek systemd[1]: Starting LSB: HPA's tftp server...
-- Subject: Unit tftpd-hpa.service has begun start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit tftpd-hpa.service has begun starting up.
Apr 18 01:47:32 Amtek tftpd-hpa[4764]:  * Starting HPA's tftpd in.tftpd
Apr 18 01:47:32 Amtek in.tftpd[4777]: cannot bind to local IPv4 socket: Address already in use
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Control process exited, code=exited status=71
Apr 18 01:47:32 Amtek systemd[1]: Failed to start LSB: HPA's tftp server.
-- Subject: Unit tftpd-hpa.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit tftpd-hpa.service has failed.
-- 
-- The result is failed.
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Unit entered failed state.
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Failed with result 'exit-code'.
Apr 18 01:47:32 Amtek polkitd(authority=local)[885]: Unregistered Authentication Agent for unix-process:4752:1729339 (system
Apr 18 01:48:46 Amtek kernel: [drm:intel_pipe_update_end [i915]] *ERROR* Atomic update failure on pipe A (start=585206 end=5
lines 1276-1298/1298 (END)
-- 
-- Unit tftpd-hpa.service has finished shutting down.
Apr 18 01:47:32 Amtek systemd[1]: Starting LSB: HPA's tftp server...
-- Subject: Unit tftpd-hpa.service has begun start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit tftpd-hpa.service has begun starting up.
Apr 18 01:47:32 Amtek tftpd-hpa[4764]:  * Starting HPA's tftpd in.tftpd
Apr 18 01:47:32 Amtek in.tftpd[4777]: cannot bind to local IPv4 socket: Address already in use
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Control process exited, code=exited status=71
Apr 18 01:47:32 Amtek systemd[1]: Failed to start LSB: HPA's tftp server.
-- Subject: Unit tftpd-hpa.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit tftpd-hpa.service has failed.
-- 
-- The result is failed.
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Unit entered failed state.
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Failed with result 'exit-code'.
Apr 18 01:47:32 Amtek polkitd(authority=local)[885]: Unregistered Authentication Agent for unix-process:4752:1729339 (system 
Apr 18 01:48:46 Amtek kernel: [drm:intel_pipe_update_end [i915]] *ERROR* Atomic update failure on pipe A (start=585206 end=58
lines 1276-1298/1298 (END)
-- 
-- Unit tftpd-hpa.service has finished shutting down.
Apr 18 01:47:32 Amtek systemd[1]: Starting LSB: HPA's tftp server...
-- Subject: Unit tftpd-hpa.service has begun start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit tftpd-hpa.service has begun starting up.
Apr 18 01:47:32 Amtek tftpd-hpa[4764]:  * Starting HPA's tftpd in.tftpd
Apr 18 01:47:32 Amtek in.tftpd[4777]: cannot bind to local IPv4 socket: Address already in use
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Control process exited, code=exited status=71
Apr 18 01:47:32 Amtek systemd[1]: Failed to start LSB: HPA's tftp server.
-- Subject: Unit tftpd-hpa.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit tftpd-hpa.service has failed.
-- 
-- The result is failed.
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Unit entered failed state.
Apr 18 01:47:32 Amtek systemd[1]: tftpd-hpa.service: Failed with result 'exit-code'.
Apr 18 01:47:32 Amtek polkitd(authority=local)[885]: Unregistered Authentication Agent for unix-process:4752:1729339 (system bus name :1.
Apr 18 01:48:46 Amtek kernel: [drm:intel_pipe_update_end [i915]] *ERROR* Atomic update failure on pipe A (start=585206 end=585207) time 9
lines 1276-1298/1298 (END)

编辑:下面是sudo netstat -lnp | grep 69输出

udp        0      0 0.0.0.0:69              0.0.0.0:*                           851/inetd       
unix  2      [ ACC ]     STREAM     LISTENING     20940    1069/Xorg           @/tmp/.X11-unix/X0
unix  2      [ ACC ]     STREAM     LISTENING     20941    1069/Xorg           /tmp/.X11-unix/X0
亚龙

结合信息的两个部分:

最近,收到一些更新后

并出现以下错误:

4月18日01:47:32 Amtek in.tftpd [4777]:无法绑定到本地IPv4套接字:地址已在使用中

启动tftp服务器时,似乎问题在于tftp端口(69)已在使用中。这可能是由于最近安装/更新了新程序造成的。

运行以下命令将帮助您确定机器上正在使用tftp端口(69)的进程:

netstat -lnp | grep 69

netstat人

-l,--listening仅显示侦听套接字。(默认情况下将省略这些内容。)

--numeric,-n显示数字地址,而不是尝试确定符号主机,端口或用户名。

-p,--program显示每个套接字所属的程序的PID和名称。

注意:| grep 69筛选结果,将仅显示其中包含69行

编辑:

当您添加到问题中时,的结果netstat -lnp表明现在inetd正在udp / port 69上运行,它有可能将tftp client作为一部分执行inetd,因此您不能在此端口上运行tftpd-hpa。

注意:请检查是否tftpd正在运行,如果效果足够好,可以避免使用tftpd-hpa

您有两种选择:

  • tftp服务器移动到使用其他端口,这可以通过更改在69端口设置tftp的以下行来完成:

    TFTP_ADDRESS =“:69”

    要使用其他端口,例如6900:

    TFTP_ADDRESS =“:6900”

注意:使用此解决方案将要求tftp-client使用新的端口号

  • 停止inetd使用udp / 69您可以检查tftp configuration文件inetd夹中是否存在文件,然后使用以下名称搜索文件:

    /etc/xinetd.d/tftp

或者

 /etc/inetd.d/tftp

本文收集自互联网,转载请注明来源。

如有侵权,请联系[email protected] 删除。

编辑于
0

我来说两句

0条评论
登录后参与评论

相关文章

来自分类Dev

更新后Apache无法启动

来自分类Dev

systemd更新后安装后无法启动

来自分类Dev

tftpd-hpa --verbosity选项如何工作?

来自分类Dev

Windows更新后,Tomcat无法启动

来自分类Dev

更新后无法启动PhpStorm 2016.1

来自分类Dev

软件更新后Kubuntu 13.04无法启动

来自分类Dev

Java更新后,Eclipse将无法启动

来自分类Dev

系统更新后无法启动Ubuntu 16.04

来自分类Dev

软件更新后Kubuntu 13.04无法启动

来自分类Dev

Ubuntu在系统更新后无法启动,但

来自分类Dev

更新后WebStorm 8 EAP无法启动

来自分类Dev

在Arch上更新grub后无法启动

来自分类Dev

安装更新后无法启动Ubuntu 14.04

来自分类Dev

更新内核Rhel 6.7后无法启动

来自分类Dev

系统更新后无法启动Ubuntu 16.04

来自分类Dev

软件更新后系统将无法启动

来自分类Dev

Virtualbox更新后无法启动VM

来自分类Dev

在20.04更新后,Chromium无法启动

来自分类Dev

更新后libreoffice将无法启动

来自分类Dev

从 18.10 更新到 19.04 后无法启动

来自分类Dev

BIOS 更新后 Ubuntu 19.04 无法启动

来自分类Dev

BIOS更新启动修复磁盘失败后,Ubuntu无法启动

来自分类Dev

更新启动分区表后无法启动到Windows

来自分类Dev

BIOS 更新后无法启动到 Ubuntu(双启动)

来自分类Dev

X在Ubuntu 14.04上重启后更新后无法启动

来自分类Dev

更新后启动缓慢

来自分类Dev

传输文件后终止TFTPD

来自分类Dev

OS X Yosemite更新后,IntelliJ无法启动

来自分类Dev

更新后无法启动mysql服务器