87
4.
Use the
lcd
command to display the local working directory of the FTP client. You can upload the
file or save the downloaded file under this directory.
5.
Upload or download the file.
Follow these steps to operate the files on an FTP server:
To do…
Use the command…
Remarks
Display detailed information about
a directory or file on the remote FTP
server
dir
[
remotefile
[
localfile
] ]
Optional
The
ls
command displays the name
of a directory or file only, while the
dir
command displays detailed
information such as the file size
and creation time.
Query a directory or file on the
remote FTP server
ls
[
remotefile
[
localfile
] ]
Optional
The
ls
command displays the name
of a directory or file only, while the
dir
command displays detailed
information such as the file size
and creation time.
Delete the specified file on the
remote FTP server permanently
delete
remotefile
Optional
Set the file transfer mode to ASCII
ascii
Optional
ASCII by default.
Set the file transfer mode to binary
binary
Optional
ASCII by default.
Set the data transmission mode to
passive
passive
Optional
Passive by default.
Display the local working directory
of the FTP client
lcd
Optional
Upload a file to the FTP server
put
localfile
[
remotefile
]
Optional
Download a file from the FTP server
get
remotefile
[
localfile
]
Optional
Changing the username after FTP login
After you log in to an FTP server, you can switch to a login username that has different user privileges than
the current username without reestablishing the FTP connection. You must correctly enter the new
username and password. A wrong username or password can cause the FTP connection to be
disconnected.
Follow the step below to change the username after FTP login:
To do…
Use the command…
Remarks
Change the username after FTP
login
user
username
[
password
]
Optional