Simple and practical FTP commands

Source: Internet
Author: User
Tags ftp commands ftp client

FTP is one of the earliest protocols used on the TCP/IP network and the Internet. It belongs to the application layer of the network protocol group.

The FTP client can send commands to the server to download files, upload files, and create or change directories on the server.


FTP is often used at work. In fact, it is mainly used to upload and download files. The following lists Common commands:

01. FTP 192.168.0.1# Enter the user name and password to log on to the FTP server

[[email protected] ~]$ ftp 192.168.0.1Connected to 127.0.0.1.220 (vsFTPd 2.2.2)530 Please login with USER and PASS.530 Please login with USER and PASS.KERBEROS_V4 rejected as an authentication typeName (127.0.0.1:root): ftpuse331 Please specify the password.Password:230 Login successful.Remote system type is UNIX.Using binary mode to transfer files.ftp>
02. ftp> mkdir Test# Create a test directory
257 "/d/vas1/ftpuse/test" created
03. ftp> dir# List files and directories, or use the LS-lart command
227 Entering Passive Mode (192.168.0.1,175,195).150 Here comes the directory listing.drwxr-xr-x    2 500      500          4096 Sep 19 07:22 test
04. ftp> Cd Test# Go To The test directory on the FTP server
250 Directory successfully changed.
05. ftp> LCD/home/test# Locate the local directory
Local directory now /home/test
06. ftp> Bin# Two transmission modes: binary ( BinaryOr Bin), ASCII(Default)
200 Switching to Binary mode.
07. ftp> put for. py# Uploading local files to the FTP server
local: for.py remote: for.py227 Entering Passive Mode (192.168.0.1,186,68).150 Ok to send data.226 Transfer complete.277 bytes sent in 0.0038 seconds (71 Kbytes/s)
08. ftp> Get cmbscmx.zip# Download the FTP server file to your local computer
local: cmmbscmx.zip remote: cmmbscmx.zip227 Entering Passive Mode (192.168.0.1,168,106).150 Opening BINARY mode data connection for cmmbscmx.zip (1046670 bytes).226 Transfer complete.1046670 bytes received in 2.8 seconds (3.7e+02 Kbytes/s)
09. ftp>! Dir# Viewing local files and directories

python  shell
10. ftp> LCD./Python# Go to the next-level directory

11. ftp> CD ..# Go to the upper-level directory

12. ftp>Rename for. py F. py# Renaming a file

13. ftp> DeleteFor. py# Deleting an object

14. ftp> rmdir Test# To delete a folder, make sure there are no files or folders in it.

15.Ftp> bye# Exit or use the quit command

221 Goodbye.
16. ftp> help# Help: View All commands
Commands may be abbreviated.  Commands are:!               cr              mdir            proxy           send$               delete          mget            sendport        siteaccount         debug           mkdir           put             sizeappend          dir             mls             pwd             statusascii           disconnect      mode            quit            structbell            form            modtime         quote           systembinary          get             mput            recv            suniquebye             glob            newer           reget           tenexcase            hash            nmap            rstatus         traceccc             help            nlist           rhelp           typecd              idle            ntrans          rename          usercdup            image           open            reset           umaskchmod           lcd             passive         restart         verboseclear           ls              private         rmdir           ?close           macdef          prompt          runiquecprotect        mdelete         protect         safe

17. ftp> help mkdir# If you use a specific command, add help

rmdir           remove directory on the remote machine


Simple and practical FTP commands

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.