Only as a study note for learning punctual atomic Linux embedded development
Generally, in the development of embedded Linux, virtual machines are used to provide an environment for compiling C language or systems. File transfer between the host and the virtual machine is a very common operation. When a Linux distribution with a graphical interface (such as Ubuntu) is installed in the virtual machine, we can directly transfer files between the host and the virtual machine by dragging or copying or pasting. However, if it is not developed with a virtual machine, but with a server, or the system in the virtual machine is not equipped with a graphical interface, it is not a simple matter for us to transfer files at this time. But don't worry, we can use FTP to solve this problem.
File Transfer Protocol (FTP) is a set of standard protocols used for file transfer on the network. FTP allows users to perform file operations (such as file addition, deletion, modification, search, transmission, etc.) A host communicates with each other. However, the user does not really log on to the computer he wants to access and becomes a full user. FTP programs can be used to access remote resources, enabling users to transfer files back and forth, directory management, and access to e-mail, etc., even though the two computers may be equipped with different operating system and file storage method.
--Baidu Encyclopedia
Install FTP in virtual machine Ubuntu
Open a terminal and enter sudo apt-get install vsftpd
install FTP server
After the installation is complete, enter sudo vim /etc/vsftpd.conf
Modify the , turn on the write enable,
After the modification is completed, save and exit, use to sudo /etc/init.d/vsftpd restart
restart the FTP server
Install FileZilla under Windows
FileZilla is a fast, reliable FTP client and server-side open source program with a feature-rich, intuitive interface.
FileZilla official download address: https://www.filezilla.cn/download
Choose a version to download
Install:
After the installation is complete, open the software, the main interface is as shown below
Click the file, open the site manager, create a new site,
Checking the IP address of the virtual machine
Enter the IP, username and password of the virtual machine to connect,
After connecting, the user directory of the virtual machine will appear in the right part of the software,
The above server-side Chinese directory name appears garbled, open the site manager again, modify the character set settings,
At this time, the Chinese display is normal
File transfer with FileZilla
Next, let's perform the transfer operation. You can right-click to select upload/download to transfer, or you can directly drag and drop to transfer.
The transfer was successful,
You can see the file just transferred in the corresponding directory of Ubuntu.