Exchange Files with SCP Server using Linux/BSD SCP command

TurboFTP Server can act as an SCP Server to provide SCP (Secure copy) service over the SSH2 layer. Because of the same underlying secure layer, SCP offers the same level of security as SFTP over SSH2. In terms of file transfer, SCP is technically faster because it requires no repetitive confirmation of data blocks like in SFTP. Also, SCP is ideal to be used in the script for batch file transfer, where it is more straightforward than SFTP.

Turbo FTP Server can run as an SCP Server for Windows while supporting the exact syntax of Linux/Unix SCP command with some subtle differences.

For example:

# Copy the file "myfile.txt" from a remote host to the local host
$ SCP /some/local/directory

# Copy the file "myfile.txt" from the local host to a remote host
$ SCP myfile.txt

# Copy the directory "dir1" from the local host to a remote host's directory "dir"
$ SCP -r dir1

Subtle differences of SCP syntax for TurboFTP SCP Server vs Linux/BSD:

  • If the¬†destination is a remote directory (e.g. 'newdir' in the following examples), it should have an ending slash to eliminate ambiguity.
    # not recommended
    SCP -P 7222 *.jpg
    # correct
    SCP -P 7222 *.jpg
    # wrong, will return "illegal D msg 'D0755 0 testdir'" if 'newupdir' doesn't exist
    $ SCP -P 7222 -r testdir/
    # The following works, with local directory 'testdir' having an ending slash or not. # 'testdir' will be created at remote under 'newupdir'. However, 'newupdir' won't be created if it doesn't exist. # correct
    $ SCP -P 7222 -r testdir/
    $ SCP -P 7222 -r testdir
  • TurboFTP Server doesn't yet support regular expression wildcard.
We use cookies to maintain login sessions, analytics and to improve your experience on our website. By continuing to use our site, you accept our use of cookies, and Privacy Policy.