In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article mainly introduces "how to set up a TFTP server on Fedora". In daily operation, I believe many people have doubts about how to set up a TFTP server on Fedora. The editor consulted all kinds of materials and sorted out simple and easy-to-use operation methods. I hope it will be helpful to answer the questions of "how to set up a TFTP server on Fedora". Next, please follow the editor to study!
Install the TFTP server
The first thing you need to do is install the TFTP client and TFTP server:
Dnf install tftp-server tftp- y
The above command creates tftp.service and tftp.socket files for systemd in the / usr/lib/systemd/system directory.
/ usr/lib/systemd/system/tftp.service/usr/lib/systemd/system/tftp.socket
Next, copy the two files to the / etc/systemd/system directory and rename them.
Cp / usr/lib/systemd/system/tftp.service / etc/systemd/system/tftp-server.servicecp / usr/lib/systemd/system/tftp.socket / etc/systemd/system/tftp-server.socket modification file
When you copy and rename these files, you can add some extra parameters. Here's what tftp-server.service looks like at first:
[Unit] Description=Tftp ServerRequires=tftp.socketDocumentation=man:in.tftpd [Service] ExecStart=/usr/sbin/in.tftpd-s / var/lib/tftpbootStandardInput=socket [Install] Also=tftp.socket
Add the following in the [Unit] section:
Requires=tftp-server.socket
Modify the [ExecStart] line:
ExecStart=/usr/sbin/in.tftpd-c-p-s / var/lib/tftpboot
Here are what these options mean:
The-c option allows you to create a new file
The-p option indicates that there is no additional permission check on top of the permission check provided by the normal system
-s recommends using this option to ensure security and compatibility with certain boot ROM that do not easily include directory names in their requests.
The default upload and download locations are located at / var/lib/tftpboot.
Next, modify the contents of the [Install] section
[Install] WantedBy=multi-user.targetAlso=tftp-server.socket
Don't forget to save your changes.
Here is the complete content of the / etc/systemd/system/tftp-server.service file:
[Unit] Description=Tftp ServerRequires=tftp-server.socketDocumentation=man:in.tftpd [Service] ExecStart=/usr/sbin/in.tftpd-c-pmurs / var/lib/tftpbootStandardInput=socket [Install] WantedBy=multi-user.targetAlso=tftp-server.socket start the TFTP server
Restart the systemd daemon:
Systemctl daemon-reload
Start the server:
Systemctl enable-now tftp-server
To change the permissions that the TFTP server allows to upload and download, use this command. Note that TFTP is an inherently insecure protocol, so it is not recommended that you do so on a network that is shared with others.
Chmod 777 / var/lib/tftpboot
Configure the firewall to enable TFTP to use:
Firewall-cmd-add-service=tftp-permfirewall-cmd-reload client configuration
Install the TFTP client
Yum install tftp-y
Run the tftp command to connect to the server. The following is an example of enabling the details option:
[client@thinclient:~] $tftp 192.168.1.164tftp > verboseVerbose mode on.tftp > get server.logsgetting from 192.168.1.164:server.logs to server.logs [netascii] Received 7 bytes in 0.0 seconds [inf bits/sec] tftp > quit [client@thinclient:~] $
Remember, because TFTP does not have the ability to list files on the server, you need to know the specific name of the file before you use the get command.
At this point, the study on "how to set up a TFTP server on Fedora" is over. I hope to be able to solve your doubts. The collocation of theory and practice can better help you learn, go and try it! If you want to continue to learn more related knowledge, please continue to follow the website, the editor will continue to work hard to bring you more practical articles!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.