Score:0

Oracle Linux 8 TFTP Server Failure

lv flag

I'm configuring a TFTP server on Oracle Linux 8 and running into some weird issues.

Configuration files:

/etc/systemd/system/tftp-server.service
::::::::::::::
[Unit]
Description=Tftp Server
Requires=tftp-server.socket
Documentation=man:in.tftpd

[Service]
ExecStart=/usr/sbin/in.tftpd -c -p -s /tftpboot
StandardInput=socket

[Install]
WantedBy=multi-user.target
Also=tftp-server.socket
::::::::::::::
/etc/systemd/system/tftp-server.socket
::::::::::::::
[Unit]
Description=Tftp Server Activation Socket

[Socket]
ListenDatagram=69
BindIPv6Only=both

[Install]
WantedBy=sockets.target

Both tftp-server and tftp.socket are running and enabled:

● tftp-server.service - Tftp Server
   Loaded: loaded (/etc/systemd/system/tftp-server.service; enabled; vendor preset: disabled)
   Active: active (running) since Tue 2022-12-13 09:08:41 EST; 11min ago
     Docs: man:in.tftpd
 Main PID: 6308 (in.tftpd)
    Tasks: 1 (limit: 48835)
   Memory: 200.0K
   CGroup: /system.slice/tftp-server.service
           └─6308 /usr/sbin/in.tftpd -c -p -s /tftpboot

Dec 13 09:08:41 systemd[1]: Started Tftp Server.

● tftp.socket - Tftp Server Activation Socket
   Loaded: loaded (/usr/lib/systemd/system/tftp.socket; enabled; vendor preset: disabled)
   Active: active (running) since Tue 2022-12-13 09:08:37 EST; 11min ago
   Listen: [::]:69 (Datagram)
    Tasks: 0 (limit: 48835)
   Memory: 0B
   CGroup: /system.slice/tftp.socket

Dec 13 09:08:37 systemd[1]: Closed Tftp Server Activation Socket.
Dec 13 09:08:37 systemd[1]: Stopping Tftp Server Activation Socket.
Dec 13 09:08:37 systemd[1]: Listening on Tftp Server Activation Socket.

The /tftpboot directory permissions are set to world-readable (777) and there is a world-readable text file in the directory. When I attempt to TFTP from the same server, I get a "Error code 1: File not found". When I attempt a TFTP get from a server on the same local VLAN, the get starts and I eventually get a "Transfer timed out" error. The iptables on the server is configured to allow UDP port 69 inbound.

I'm not sure what I'm missing here. I followed the instructions at https://linuxhint.com/tftp_server_centos8/ but I simply cannot make a connection, even from the localhost. Any ideas would be greatly appreciated!

Score:0
dz flag

I believe I figured out the issue. Running some status checks I noticed tftp and tftp-server were both running, but using different config files:

systemctl status tftp
● tftp.service - Tftp Server
   Loaded: loaded (/usr/lib/systemd/system/tftp.service; indirect; vendor preset: disabled)
   Active: active (running) since Wed 2022-12-14 10:56:41 EST; 10min ago
     Docs: man:in.tftpd
 Main PID: 9604 (in.tftpd)
    Tasks: 1 (limit: 48835)
   Memory: 244.0K
   CGroup: /system.slice/tftp.service
           └─9604 /usr/sbin/in.tftpd -s /var/lib/tftpboot

Dec 14 10:56:41 systemd[1]: Started Tftp Server.

systemctl status tftp-server
● tftp-server.service - Tftp Server
   Loaded: loaded (/etc/systemd/system/tftp-server.service; enabled; vendor preset: disabled)
   Active: inactive (dead) since Tue 2022-12-13 12:57:45 EST; 22h ago
     Docs: man:in.tftpd
 Main PID: 6832 (code=exited, status=0/SUCCESS)

Dec 13 12:42:45 systemd[1]: Stopped Tftp Server.
Dec 13 12:42:45 systemd[1]: Started Tftp Server.
Dec 13 12:57:45 systemd[1]: tftp-server.service: Succeeded.

Copying the syntax from /etc/systemd/system/tftp-server.service to /usr/lib/systemd/system/tftp.service got TFTP working again. I'm not entirely clear why this happened, but at least TFTP is working now.

I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.