Ubuntutftp service installation and configuration

Source: Internet
Author: User

Ubuntutftp service installation and configuration
1. Install related software packages: Ubuntu tftp (server), tftp (client), and xinetd

sudo apt-get install tftpd tftp xinetd

2. Create a configuration file
Create a configuration file tftp under/etc/xinetd. d/
sudo vim tftp
Enter the following content in the file:
service tftp{ socket_type = dgram protocol = udp wait = yes user = root server = /usr/sbin/in.tftpd server_args = -s /tftpboot disable = no per_source = 11 cps = 100 2 flags = IPv4}
Save and exit

3. Create the Ubuntu tftp service file directory (where files are uploaded and downloaded) and change its permissions.
sudo mkdir /tftpbootsudo chmod 777 /tftpboot -R

4. Restart the service
sudo /etc/init.d/xinetd restart
Now that the Ubuntu tftp service has been installed, you can test it. (Assume there is a test file test.txt in the current directory)
$tftp 127.0.0.1                      tftp> put test.txtSent 1018 bytes in 0.0 secondstftp> get test.txtReceived 1018 bytes in 0.1 secondstftp> quit
If a tftp Error on server: Access violation Error occurs, generate a file with the same name as the file to be uploaded in the/tftpboot directory and change the permission to 777.
touch test.txtchmod 777 test.txt

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.