FTP server (File Transfer Protocol Server) is a computer that provides file storage and access services on the Internet. They provide services in accordance with the FTP protocol. FTP is File Transfer Protocol. As the name suggests, it is a protocol specifically used to transfer files. Simply put, a server that supports the FTP protocol is an FTP server.
Generally speaking, the primary purpose of users networking is to share information, and file transfer is one of the very important contents of information sharing. It was not easy to transfer files on the Internet in the early days. We know that the Internet is a very complex computer environment. There are PCs, workstations, MACs, and mainframes. According to statistics, there are already more than 100 computers connected to the Internet. There are tens of millions of computers, and these computers may run different operating systems, including servers running Unix, PCs running Dos, Windows, and Macs running MacOS, etc. The problem of file exchange between various operating systems requires Create a unified file transfer protocol, which is called FTP. There are different FTP applications based on different operating systems, and all of these applications comply with the same protocol, so that users can transfer their files to others, or obtain files from other user environments. (Recommended learning:PHP video tutorial.)
Like most Internet services, FTP is also a client/server system. The user connects to the FTP server program on the remote host through a client program that supports the FTP protocol. The user issues commands to the server program through the client program, and the server program executes the commands issued by the user and returns the execution results to the client. For example, if the user issues a command asking the server to send a copy of a certain file to the user, the server will respond to the command and send the specified file to the user's machine. The client program receives this file on behalf of the user and stores it in the user's directory.
Software usage
In the use of FTP, users often encounter two concepts: "Download" and "Upload". "Downloading" files means copying files from the remote host to your own computer; "uploading" files means copying files from your own computer to the remote host. In Internet language, users can upload (download) files to (from) remote hosts through client programs.
When using FTP, you must log in first, and only after obtaining the corresponding permissions on the remote host can you upload or download files. In other words, in order to transfer files to a computer, you must have the appropriate authorization for that computer. In other words, files cannot be transferred unless you have a user ID and password. This situation goes against the openness of the Internet. There are tens of millions of FTP hosts on the Internet, and it is impossible to require every user to have an account on every host. Anonymous FTP was created to solve this problem.
Anonymous FTP is a mechanism through which users can connect to a remote host and download files from it without becoming a registered user. The system administrator has created a special user ID named anonymous, which can be used by anyone anywhere on the Internet.
The way to connect to an anonymous FTP host through an FTP program is similar to the way to connect to an ordinary FTP host, except that anonymous must be entered when asked to provide a user ID. The password of the user ID can be any string. It is customary to use your own e-mail address as the password so that system maintenance programs can record who is accessing these files.
It is worth noting that anonymous FTP is not available for all Internet hosts, it is only available for those hosts that provide this service.
When the remote host provides anonymous FTP services, certain directories will be designated to be open to the public and allow anonymous access. The remaining directories in the system are hidden. As a security measure, most anonymous FTP hosts allow users to download files from them, but do not allow users to upload files to them. In other words, users can copy all files on the anonymous FTP host to their own machines. But you cannot copy any files on your own machine to the anonymous FTP host. Even if some anonymous FTP hosts do allow users to upload files, users can only upload files to a specified upload directory. Later, the system administrator will check these files, and he will move these files to another public download directory for other users to download. In this way, users of the remote host are protected from someone uploading problematic files. files, such as files with viruses.
As an Internet user, you can copy files between any two Internet hosts through FTP. However, in fact, most people only have one Internet account, and FTP is mainly used to download public files, such as shared software, technical support files of various companies, etc.
There are thousands of anonymous FTP hosts on the Internet, and countless files are stored on these hosts for users to copy for free. In fact, almost all types of information, all types of computer programs can be found on the Internet. This is one of the important reasons why the Internet attracts us.
Anonymous FTP gives users the opportunity to access the world's largest information database. This information database is accumulated over time and is still growing, never closed, and involves almost all topics. And, it's all free.
Anonymous FTP is a common method for publishing software on the Internet. The Internet survives today because people use programs that provide standard services through standard protocols. Many programs like this are distributed through anonymous FTP, and anyone can access them.
There are a huge number of anonymous FTP hosts and more files on the Internet, so how can we know which directory on which anonymous FTP host a specific file is located? This is exactly what the Archie server does. Archie will automatically search the FTP host and construct a database containing all file directory information, so that you can directly find the location information of the required files.
The above is the detailed content of How to use ftp server. For more information, please follow other related articles on the PHP Chinese website!