tftp - bunnyamin/bunnix GitHub Wiki
The TFTP directory, for example /srv/tftp, is the root path for DHCPD.
- Permission
chmod -R 644 /srv/tftp, requires at least644. - Ownership
chown -R nobody:nobody /srv/tftpor change the user-group. For example:-
--user x --group yATFTP
-
| Test | Example |
|---|---|
| Does the TFTP server accept connections? | $ nc -zv 192.168.0.101 69 |
| Does the TFTP server accept upload? |
$ atftp 192.168.0.101, atftp> get test.txt
|
| Can the TFTP client download from the server? |
$ atftp 192.168.0.101, atftp> get test.txt
|
| Error | Cause | Remedy | Comment |
|---|---|---|---|
GRUB: File not found |
Change the permission for file to or above 644. |
||
atftpd: failed to setgid to group 99 (nobody). |
If --user and, or --group is set then try removing them. |
Not confirmed exactly from when but at least from 0.7.2-1 the --user and, or --group seem to cause the error. |
|
atftpd: <File> file not found. |
The file has no "read" permission |
- Enable logging to file. Recommended to disable when the TFTP server has been properly configured.
- Test (optional):
- Verify connection to server
nc -uvz 192.168.0.101 69. If theu(UDP) parameter is not assigned thenncassumest(TCP), and the respons could be<HOST.LOCALDOMAIN> <IP> <PORT> (tftp) Connection refusedbecause ATFTPD usesUDP. - Display all the sockets on the server (
a) in numeric values (n) and if they are listining (l) or have a processes using them (p)ss -alnp. - Boot up the client computer, it attempts to download the bootloader, and it will fail.
The attempt should be logged in assigned logfiler.
/var/atftpd.log
- Verify connection to server
- Install and configure the bootlader.
- Grub netboot
- Ensure that the owner to the files are "nobody"
chown -R nobody:nobodywithrwpermission to owner (6). execute and read (5) for other userschmod -R 655.
- Enable
systemctl enable atftpd. - Boot up the client computer, it attempts to download the bootloader, and it should succeed.
- If error
no DNS servers configured.then probably because the DCHP server is not set up, which is the next step; the error requires that thenext-server <DNS IP>;.
- If error
- Configure /etc/conf.d/atftpd
A client/server implementation of the TFTP protocol that implements RFC: 1350, 2090, 2347, 2348, 2349.
Permanently initialize ATFTP on boot systemctl enable atftpd.