The wftp client application provides fast file copy and block level synchronization between the local machine and a remote machine running the wfstd service.  I t provides much the same functionality as the wcp command, but its syntax is similar to the popular ftp application.  Like ftp, wftp is an interactive command line utility that allows you to walk the local and remote file systems, create new directories, delete or rename files, and copy files between the two machines. For those who do not like command line programs, wgui provides the features of wftp in a more convenient graphical user interface.  For those needed to script, or automate their file transfers, wcp would be the better choice.

SYNTAX: wftp [OPTIONS] [[UserName@]Address]

UserName optionally specifies the account to use for accessing files on the remote computer.   If you do not specify UserName, your current account ID will be used.   Address must specify either the host name or IP address of the remote computer.  In order for the connection to complete,

  1. The remote machine must be running the wfstd daemon process.
  2. The port used by the wfstd process cannot be blocked by a firewall.
  3. If the wfstd process has been configured with a port other than 4900, then you must specify this non-standard port on the wftp command line using the --server-port=PORT option.
  4. You must have a valid WANFast key pair configured on the local machine.  This key pair must either be in the default location for your current account, or must be specified on the command line using the -i KeyPath option.
  5. The security critical WANFast files on the local machine must have the proper security attributes set.  If you get an error message telling you that you have insecure file permissions, run the wfstPerms command to set them correctly.
  6. The target account (UserName) on the remote machine must have a valid authorized_keys file containing your WANFast public key.
  7. The security critical WANFast files on the remote machine must have the proper security attributes set.

wftp supports the same command line OPTIONS as wcp.  See wcp Client Command Syntax and Configuration Options for the complete list, or File Copy, Backup, and Synchronization for detailed examples.  You can specify options on the command line when first invoking wftp, or by using the interactive commands set or open.  For example, you can switch from file copy mode to block level synchronization mode by entering the command:

set -s
or
set --sync

wftp Interactive Commands

After starting wftp, you will be presented with its command line prompt:  wftp>.  From this prompt you can enter any of the wftp interactive commands, which are described in the sections below.  Alternate command names are listed in parenthesis.  

Many of the wftp commands allow you to supply one or more paths for the operation.  wftp assumes that any path you specify will be relative to the current working directory unless it is an absolute path -- i.e., it starts with "/" on Linux or a drive specification, such as C:/, on Windows.  In most cases wftp supports globbing in a path specification, i.e., use of the wildcard character, "*", to match one or more paths.  For example, if you enter the path "File*" with a trailing wildcard, it will match all of "File1", "File2", and "FileOfADifferentColor", etc, if they are present.  Support for globbing will be denoted in the command summaries below by adding a "*" to the effected PATH in the command syntax.    

cd (chdir) PATH*
lcd (lchdir) PATH*

The cd command changes the current working directory on the remote machine as specified by PATH.  The lcd command provides the same function on the local machine.  Globbing is supported for matching long path names.  But if more than one path is matched, the results are indeterminate.

pwd
lpwd

The pwd command displays the current working directory on the remote machine.  The lpwd command provides the same function on the local machine.

ls (dir) [PATH* ...]
lls (ldir) [PATH* ...]

The ls command lists the contents of the specified directories on the remote machine.  The lls command provides the same function on the local machine.  If no PATH is specified, wftp lists the contents of the current working directory.    

mkdir PATH
lmkdir PATH

The mkdir command creates a new subdirectory on the remote machine.  lmkdir provides the same function on the local machine.

rm (delete) [-r] PATH* [PATH* ...]
lrm (ldelete) [-r] PATH* [PATH* ...]

The rm command deletes the specified files and/or directories on the remote machine.  lrm provides the same function on the local machine.  If a path is a directory, it will only be deleted if empty unless the -r option is specified, in which case the directory and all its children will be deleted.

mv (rename) PATH1* [PATH* ...] PATH2
lmv (lrename) PATH1* [PATH* ...] PATH2

The mv command moves one or more files or directories to the path specified by PATH2 on the remote machine.  lmv provides the same function on the local machine.  If PATH2 is a directory, the source PATH will be moved into that directory.  If more than one source path is specified, PATH2 must be a directory, 

cp (copy) PATH1* PATH2
lcp (lcopy) PATH1* PATH2

The cp command copies one or more files to the path specified by PATH2 on the remote machine.  lcp provides the same function on the local machine.  If PATH2 is a directory, the source file will be copied into that directory.  If more than one source file is specified, PATH2 must be a directory,  The cp command does not copy directories at this time.

cmd COMMAND_LINE
lcmd COMMAND_LINE

The cmd command takes the remainder of the line as a command line and runs it on the remote machine, displaying the output of the command.  lcmd provides the same function on the local machine.  The command is run with its present working directory set to the user's home directory.  If this is not what you want, be sure to explicitly set the directory in your command, e.g.,

lcmd cd /tmp; echo xxxxxx > TestFile

chmod MODE PATH* [PATH* ...]
lchmod MODE PATH* [PATH* ...]

[Linux only] The chmod command changes the mode of the specified paths to MODE.  lchmod provides the same function on the local machine.  MODE must be specified in octal format, e.g., 755 = rwxr-xr-x.

chown OWNER PATH* [PATH* ....]
lchown OWNER PATH* [PATH* ....]

[Linux only] The chown command changes the owner of the specified paths to OWNER.  lchown provides the same function on the local machine.  You will need to run wftp with root privilege in order to change a file's owner.

chgrp GROUP PATH* [PATH* ...]
lchgrp GROUP PATH* [PATH* ...]

[Linux only] The chgrp command changes the group of the specified paths to GROUP.  lchgrp provides the same function on the local machine.  You will need to run wftp with root privilege in order to change a file's group.

get (recv) PATH* [PATH* ...]

The get command copies (or syncs) the specified paths from the remote machine to the current working directory of the local machine.  The exact behavior of the command -- copy vs. sync, overwrite existing files, recurse into subdirectories, preserve file attributes, etc -- is determined by the options that have been specified in the configuration file, command line, or interactively using the set or open command.

put (send) PATH* [PATH* ...]

The put command copies (or syncs) the specified paths from the local machine to the current working directory of the remote machine.  The exact behavior of the command -- copy vs. sync, overwrite existing files, recurse into subdirectories, preserve file attributes, etc -- is determined by the options that have been specified in the configuration file, command line, or interactively using the set or open command.

set [OPTION ...]

The set command sets or displays configuration options.  If no OPTION is specified, set will display the currently configured options.  If one or more OPTIONS are specified, these will be added to the current configuration.  OPTIONS should be specified using the same format as used on the command line, e.g., 

set --max-bandwidth=100

open (connect) [OPTION ...] [USER@]HOST

The open command connects to a remote WANFast server.  You can specify any of the options that are valid on the command line.

close (disconnect)

The close command disconnects from the remote WANFast server.

quit (exit)

The quit command terminates your wftp session.