Here we will list some common functions and explain the functions one by one with a specific example.
FTP is usually used to log on to FTP, browse FTP content, download FTP files, or upload FTP files.
1. The first step to use FTP is to log on.
Lftp logon command:
Lftp User: password @ site: Port example: lftp geewu: geewu@10.2.0.190
Lftp site: Port-u user, password example: lftp 10.2.0.190-u geewu, geewu
Default User Logon: lftp 10.20.190
After entering FTP
# Lftp>
2. Search for files
Enter ls in the command to list all files in the current directory.
Lftp 10.20.190:> ls
Drwxr-XR-x 1 FTP 0 Apr 27 17: 05 Office
Drwxr-XR-x 1 FTP 0 APR 06 2011 Oracle
....
3. Go to the Oracle directory
Enter cd in the command to enter the Oracle directory
Lftp 10.20.190:> cd Oracle
4. list all files in the Oracle directory
Lftp 10.2.0.254:/Oracle/Oracle11g> ls
-Rw-r -- 1 ftp 1285396902 Dec 07 2010 linux_11gR2_database_1of2.zip
-Rw-r -- 1 ftp 995359177 Dec 07 2010 linux_11gr2_databasesilicate f2.zip
5. Download two files in the Oracle directory
Lftp 10.2.0.254:/Oracle/Oracle11g> get linux_11gR2_database_1of2.zip
More functions:
Batch download: mget *. txt
Multi-thread download: pget-n 4 linux_11gR2_database_1of2.zip
Rename the downloaded local file:
Get rfile-o lfile
Capture rfile and rename it lfile
-C: Resume
-E. After the file is captured, the remote file is cut down.
-A is an ascii mode and the default value is binary mode.
Switch local download subgrade: switch to the oracle folder
LCD/home/geewu/oracle.
-O sets the base directory as the directory for storing files on the local end.
For more information, see:
Http://blogold.chinaunix.net/u2/71520/showart_1002987.html