tftpd-hpa service must be restarted before working after fresh boot

Posted by Steve on Server Fault See other posts from Server Fault or by Steve
Published on 2014-05-28T14:39:57Z Indexed on 2014/05/28 15:31 UTC
Read the original article Hit count: 388

Filed under:
|
|

I'm running Ubuntu 12.04 inside a VirtualBox VM. I've installed tftpd-hpa so I can boot an embedded Linux device via tftp.

My problem is that after a fresh boot of the VM, tftpd doesn't seem to work until I restart the service, after which is works great until the system is rebooted. The transcript below should explain the situation.

EDIT: After the fresh boot, I execute netstat -a | grep tftp and find nothing. After restarting the service, the same command returns udp 0 0 *:tftp *:* (whitespace removed). I think this might be the key to the problem, I'm just not sure how to resolve it.

I don't think it's related to this specific issue, but I had another problem with tftpd that was asked and answered in this question.

steve@steve-VirtualBox:~$ cat /etc/default/tftpd-hpa 
# /etc/default/tftpd-hpa

TFTP_USERNAME="tftp"
TFTP_DIRECTORY="/var/lib/tftpboot"
TFTP_ADDRESS="0.0.0.0:69"
TFTP_OPTIONS="--secure"
steve@steve-VirtualBox:~$ ls -l /var/lib/tftpboot
total 8204
-rw-r--r-- 1 root root   34352 May 28 08:22 am335x-boneblack.dtb
-rw-r--r-- 1 root root   33206 May 28 08:22 am335x-bone.dtb
-rw-r--r-- 1 root root   41564 May 28 08:22 am335x-evm.dtb
-rw-r--r-- 1 root root   38048 May 28 08:22 am335x-evmsk.dtb
-rwxr-xr-x 1 root root 4117904 May 20 09:39 zImage
-rw-r--r-- 1 root root 4117616 May 28 08:22 zImage-am335x-evm.bin
steve@steve-VirtualBox:~$ tftp localhost
tftp> get zImage
Transfer timed out.

tftp> quit
steve@steve-VirtualBox:~$ sudo service tftpd-hpa restart
[sudo] password for steve: 
tftpd-hpa stop/waiting
tftpd-hpa start/running, process 2106
steve@steve-VirtualBox:~$ tftp localhost
tftp> get zImage
Received 4143798 bytes in 1.4 seconds
tftp> quit
steve@steve-VirtualBox:~$

© Server Fault or respective owner

Related posts about linux

Related posts about ubuntu