Using fine extraction of FTP

Source: Internet
Author: User
Tags definition exit file size ftp ftp commands hash parent directory runique

FTP commands are one of the most frequently used commands for Internet users, and a large number of FTP internal commands are encountered, whether using FTP under a DOS or UNIX operating system. Familiar with and flexible application of FTP internal command, can greatly facilitate users, and received a multiplier effect.
The FTP command line format is: Ftp-v-d-i-n-g (host name), where

-V Displays all response information for the remote server;
-N Restricts automatic logon of FTP, that is, not used;
. n ETRC documents;
-D use debugging mode;
-G cancels the global filename.

The internal commands used by FTP are as follows (parentheses indicate an option):

1.! (cmd (args)): In the local machine to perform interactive shell,exit back to the FTP environment, such as:!ls*.zip.

2.$ macro-ame (args): Perform macro definition macro-name.

3.account (password): Provides the additional password required to access system resources after successful logon to the remote system.

4.append Local-file (remote-file): Appends the local file to the remote system host and uses the local filename if no remote system file name is specified.

5.ASCII: Use ASCII type transfer mode. Computer Basics

6.bell: The computer rings once after each command completes.

7.bin: Use binary file transfer mode.

8.bye: Exits the FTP session process.

9.case: When using Mget, the upper case of the remote host file name is converted to lowercase letters.

10.CD Remote-dir: Access to remote host directory.

11.cdup: Enter the parent directory of the remote host directory.

12.chmod mode File-name: Sets the access mode of the remote host file File-name to mode, such as: chmod 777 a.out.

13.close: Interrupts the FTP session with the remote server (corresponding to open).

14.CR: When the file is transferred using ASSCII, the carriage return line wrap is converted to a back line.

15.delete remote-file: Deletes the remote host file.

16.debug (debug-value): Set debug mode, display every command sent to the remote host, such as: Deb up 3, if set to 0, to cancel Debug. Computer

17.dir (Remote-dir) (Local-file): Displays the remote host directory and stores the results in local file local-file.

18.disconnection: Same as close.

19.form format: Sets the file transfer mode to format, default to file mode.

20.get Remote-file (local-file): Passes the remote host file Remote-file to the local-file of the local hard drive.

21.glob: Sets the file name extension for Mdelete,mget,mput, which does not extend the filename by default, and the-G parameter of the command line.

22.hash: 1024 bytes per transmission, displaying a hash symbol (#).

23.help (CMD): Displays the FTP internal command cmd's help information, for example: Helps get.

24.idle (seconds): Set the remote server's hibernate timer to (seconds) seconds

25.image: Set binary transmission mode (same binary).

26.lcd (dir): Switches the local working directory to dir.

27.ls (Remote-dir) (Local-file): Displays the remote directory Remote-dir and stores the local file Local-file.

28.macdef Macro-name: Defines a macro that, when it encounters an empty row under Macdef, ends the macro definition.

29.mdelete (remote-file): Deletes the remote host file.

30.mdir remote-files Local-file: Similar to dir, but can specify multiple remote files, such as: Mdir *.o.*.zipoutfile.

31.mget remote-files: Transfer multiple remote files.

32.mkdir dir-name: Build a directory in the remote host.

33.MLS remote-file local-file: Same nlist, but multiple file names can be specified.

34.mode (modename): Set file transfer mode to Modename, default to stream mode.

35.modtime file-name: Displays the last modification time of the remote host file.

36.mput local-file: Transfer multiple files to a remote host.

37.newer File-name: If the File-name modification time in the remote machine is closer than the time of the file with the same name as the local hard disk, the file is retransmission.

38.nlist (Remote-dir) (Local-file): Displays a list of files for the remote host directory and local-file to the local hard drive.

39.nmap (Inpattern outpattern): Set file name Mapping mechanism, so that when file transfer, some characters in the file are converted to each other, such as: Nmap $1.$2.$3 ($1,$2). ($2,$3), When the file a1.a2.a3 is transferred, the file name becomes A1,A2. This command is particularly useful for situations where a remote host is not a UNIX machine.

40.ntrans (Inchars (Outchars)): Sets the translation mechanism for file-name characters, such as NTRANS1R, the filename lll becomes RRR.

41.open Host (port): Establishes a connection to the specified FTP server that specifies the connection port.

42.passive: Enter passive transmission mode.

43.prompt: Set up interactive prompts for multiple file transfers.

44.proxy Ftp-cmd: In a secondary control connection, an FTP command is executed that allows two FTP servers to be connected to transfer files between two servers. The first FTP command must be open to establish a connection between two servers first.

45.put Local-file (remote-file): Transfer local file Local-file to a remote host.

46.pwd: Displays the current working directory of the remote host.

47.quit: With bye, exit FTP session.

48.quote arg1,arg2 ... : sends the parameter verbatim to the remote FTP server, such as: Quote Syst.

49.recv Remote-file (local-file): with Get.

50.reget Remote-file (local-file): Similar to get, but if local-file exists, it is resumed from the last transmission interrupt.

51.rhelp (cmd-name): Request Help for remote host.

52.rstatus (file-name): If no filename is specified, the status of the remote host is displayed, otherwise the file status is displayed.

53.rename (TO): Change the remote host file name.

54.reset: Clear answer queue.

55.restart marker: From the specified logo marker, restart get or put, such as: Restart 130.

56.rmdir dir-name: Deletes the remote host directory.

57.runique: Set file name uniqueness store, if file exists, then add suffix to the original file. 1,.2 and so on.

58.send Local-file (remote-file): same put.

59.sendport: Set the use of the port command.

60.site arg1,arg2 ... : sends the parameter as a site command to a remote FTP host verbatim.

61.size file-name: Displays the remote host file size, such as: Site Idle 7200.

62.status: Displays the current FTP status.

63.struct (Struct-name): Sets the file transfer structure to struct-name, using the stream structure by default.

64.sunique: Set the remote host file name store to unique (corresponds to Runique).

65.system: Displays the operating system type of the remote host. Basic knowledge of computer questions and answers

66.tenex: Sets the file transfer type to the desired type for the Tenex machine.

67.tick: Sets the byte counter at the time of transmission.

68.trace: Set package tracking. A course in Basic computer knowledge

69.type (type-name): Set file Transfer Type to Type-name, default to ASCII, such as: Type binary, set binary transmission mode.

70.umask (Newmask): Set the default umask for the remote server to Newmask, such as: Umask 3.

71.user user-name (password) (account): To the remote host to indicate their identity, require a password, you must enter a password, such as: User anonymous my@email.

72.verbose: The-v parameter with the command line, that is, to set up a detailed report, all responses to the FTP server will be displayed to the user, and the default is on.

73.? (cmd): With Help.

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.