Knowledge Base

Enter search queries below or use the tag links to the right to browse the knowledge base by category (Show All Tags).


Robo-FTP script equivalents to Windows / Unix command line FTP commands

Starting with Robo-FTP version 3.8.3 hints are displayed when you type command line FTP client commands.

The Unix command line FTP client (and the Windows version which is essentially a clone) were so widely used that it is not unusual for server administrators to provide instructions to clients based on commands for these clients.

This can lead to confusion for Robo-FTP users who are trying to decipher these instructions and determine which Robo-FTP script commands to use to achieve the same results.

It is important to understand that commands you type into the Windows or Unix command line client are not raw FTP commands. For example, when you type PUT myfile.txt, the command line client translates this into the following raw FTP command and sends it to the server: STOR myfile.txt.

Robo-FTP has its own set of commands which it translates into raw FTP behind the scenes. For example, to send the same raw FTP command STOR myfile.txt to the server with Robo-FTP, you would use the following script command: SENDFILE "myfile.txt".

The following table shows some common raw FTP commands and their equivalents in the command line client and Robo-FTP.

Raw FTPCommand Line ClientRobo-FTP
STORPUTSENDFILE
RETRGETRCVFILE
CWDCDFTPCD
MKDMKDIRFTPMAKEDIR
RMDRMDIRFTPDELDIR


Combining FTP commands

Not all commands have a direct one-to-one relationship. For example, there is no raw FTP command to upload multiple files.

To download all files matching a certain wildcard pattern with the command line client, you would issue this command: MGET *.txt.

The command line client processes that command by first retrieving a directory listing (using the raw FTP command NLIST). It then automatically loops over the list of files and uses RETR to download the files one at a time.

Robo-FTP can achieve the same results using RCVFILE "*.txt".

A second example of combining raw FTP commands is renaming files on-the-fly before uploading.

The command line client supports this syntax: PUT myfile.txt renamed_file.txt. When you enter this command, the client sends the raw FTP command STOR renamed_file.txt, but uploads the contents of myfile.txt -- achieving the appearance of renaming the file on-the-fly.

Robo-FTP can achieve the same results using SENDFILE "myfile.txt" /as "renamed_file.txt".

Non-Standard Servers

Robo-FTP and the command-line client will not necessarily send the same sequence of raw commands to the server. The differences, if any, will not impact behavior when connected to a standard server.

Some non-standard servers add functionality by "overloading" raw commands to provide extra instructions to the server. For example, a non-standard server may require additional file meta data to be disguised as folder structures in a "cd" command. We cannot guarantee that Robo-FTP will work with non-standard servers.

See also:

I'm trying to send a "site" command like this: FTPCMD "QUOTE SITE REC=FB LR=80 BLK=0" but it fails. What's wrong?

How do I rename a file on an FTP site using "raw" FTP commands?

How to download a data set from an IBM server

Unable to transfer files to GXS using FTPS

Article last updated: 2022-01-05

Tags: Command Line, Raw FTP Commands, Overload