- Tftp install the client and server
sudo install tftp-APT-GET HPA tftpd-hpa xinetd
tftp-HPA is a client
tftpd-hpa server - Profiles
- sudo vim /etc/xinetd.d/tftp
. 1 -Service TFTP 2 { . 3 socket_type = dgram . 4 Protocol = UDP . 5 the wait = Yes . 6 User = SEN # server using the user name . 7 Server = / Home / aishanliang / tftp_share server resources # Pick Path . 8 the server_args = -s / TFTP - C . 9 disable = NO 10 per_source = . 11 . 11 CPS = 100 2 12 is flags = IPv4 13 }
- sudo vim /etc/default/tftpd-hpa
. 1 TFTP_USERNAME = " TFTP " 2 TFTP_DIRECTORY = " / Home / aishanliang / tftp_share " # Pick Path server resources . 3 TFTP_ADDRESS = " : 69 " . 4 TFTP_OPTIONS = " --secure " # Write study, as used herein, does not change the default
- Creating a server resource folder
sudo mkdir / home / sen / tftp_share
6. Use the chmod command set for the directory the most liberal permissions.
sudo chmod -R 777 tftp_share
sudo chown -R nobody tftp_share
7. Restart Service
sudo service tftpd-hpa restart
sudo /etc/init.d/xinetd restart
8. Test
- Detecting whether obtained through ping
- If the firewall is turned off
sudo ufw disable
- Detecting whether to start tftp
netstat -a | grep tftp
when the results show: udp 0 0 *: tftp: the tftp service is started
- In / home / sen / tftp_share create a test file and written information
touch test
echo “hello” > test
cat test
- ifconfig view the current virtual machine IP
The assumption is 192.168.13.59
in another file folder with a virtual machine download tftp tftp server resource file folder test
With the ls command to view the current folder, and then test to see if tftp configuration is successful.
- Tftp transmission from the board: After you install Ubuntu tftp, files can be downloaded using the tftp command development board.
- tftp -g -r < filename > < ip address >
Method Two:
For more information see the Ubuntu Ubuntu topic page http://www.linuxidc.com/topicnews.aspx?tid=2
This article permanently updated link address : http://www.linuxidc.com/Linux/2016-07/133255.htm