install tftp server on MacOS Ventura

I used the following procedure to enable tftp server on my MacBookPro running Ventura:


sudo launchctl load -F /System/Library/LaunchDaemons/tftp.plist


On my target device running Linux OS, I could use "tftp -g -r <filename> host_IP" to get a file under MBP's /private/tftpboot folder.


However, when my target board boots into the boatload, using tftp from bootloader returns "TFTP error 2: Access violation". After reading quite a few old online stories, I tried to remove the the top two lines from the default /System/Library/LaunchDaemons/tftp.plist.


<key>Disabled</key>

<true/>


There are two problems though:

  1. the /System/Library/LaunchDaemons/tftp.plist is not writable, even with "sudo".
  2. I copied the /System/Library/LaunchDaemons/tftp.plist to my local home directory and made the above modification there, then relaunched tftpd with the local plist file:

launchctl load -F tftp-test.plist

now my target device doesn't report access violation, but it reported "Failed: Timeout occured" error.


Can you tell me what is the working procedure to enable tftp server on MacOS Ventura? or how to address above two problems? Thanks!

Posted on Jun 6, 2023 4:29 PM

Reply

Similar questions

1 reply

Jun 6, 2023 6:23 PM in response to yue86

The Disabled key really has no effect on loading or running. The enabled status is stored externally, the value is just a default.

If you add -w to the options for launchctl load, it will write the enabled (or disabled for unload) bit, thus having it re-load at restart. I don't believe that has anything to do with the access violation.


Unless run from the /Library/LaunchAgents folder, it won't be run as root.

It doesn't sound as though the server was started. I don't know if that is the reason.


This part of the man page is interesting:

 Because there is no user-login or validation within the TFTP protocol, the remote site will probably
 have some sort of file-access restrictions in place.  The exact methods are specific to each site 
 and therefore difficult to document here.

Looking at the directory permissions, it doesn't appear to be locked down.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

install tftp server on MacOS Ventura

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.