github.com/10XDev/rclone@v1.52.3-0.20200626220027-16af9ab76b2a/docs/content/ftp.md (about)

     1  ---
     2  title: "FTP"
     3  description: "Rclone docs for FTP backend"
     4  ---
     5  
     6  {{< icon "fa fa-file" >}} FTP
     7  ------------------------------
     8  
     9  FTP is the File Transfer Protocol. FTP support is provided using the
    10  [github.com/jlaffaye/ftp](https://godoc.org/github.com/jlaffaye/ftp)
    11  package.
    12  
    13  Here is an example of making an FTP configuration.  First run
    14  
    15      rclone config
    16  
    17  This will guide you through an interactive setup process. An FTP remote only
    18  needs a host together with and a username and a password. With anonymous FTP
    19  server, you will need to use `anonymous` as username and your email address as
    20  the password.
    21  
    22  ```
    23  No remotes found - make a new one
    24  n) New remote
    25  r) Rename remote
    26  c) Copy remote
    27  s) Set configuration password
    28  q) Quit config
    29  n/r/c/s/q> n
    30  name> remote
    31  Type of storage to configure.
    32  Enter a string value. Press Enter for the default ("").
    33  Choose a number from below, or type in your own value
    34  [snip]
    35  XX / FTP Connection
    36     \ "ftp"
    37  [snip]
    38  Storage> ftp
    39  ** See help for ftp backend at: https://rclone.org/ftp/ **
    40  
    41  FTP host to connect to
    42  Enter a string value. Press Enter for the default ("").
    43  Choose a number from below, or type in your own value
    44   1 / Connect to ftp.example.com
    45     \ "ftp.example.com"
    46  host> ftp.example.com
    47  FTP username, leave blank for current username, ncw
    48  Enter a string value. Press Enter for the default ("").
    49  user> 
    50  FTP port, leave blank to use default (21)
    51  Enter a string value. Press Enter for the default ("").
    52  port> 
    53  FTP password
    54  y) Yes type in my own password
    55  g) Generate random password
    56  y/g> y
    57  Enter the password:
    58  password:
    59  Confirm the password:
    60  password:
    61  Use FTP over TLS (Implicit)
    62  Enter a boolean value (true or false). Press Enter for the default ("false").
    63  tls> 
    64  Remote config
    65  --------------------
    66  [remote]
    67  type = ftp
    68  host = ftp.example.com
    69  pass = *** ENCRYPTED ***
    70  --------------------
    71  y) Yes this is OK
    72  e) Edit this remote
    73  d) Delete this remote
    74  y/e/d> y
    75  ```
    76  
    77  This remote is called `remote` and can now be used like this
    78  
    79  See all directories in the home directory
    80  
    81      rclone lsd remote:
    82  
    83  Make a new directory
    84  
    85      rclone mkdir remote:path/to/directory
    86  
    87  List the contents of a directory
    88  
    89      rclone ls remote:path/to/directory
    90  
    91  Sync `/home/local/directory` to the remote directory, deleting any
    92  excess files in the directory.
    93  
    94      rclone sync /home/local/directory remote:directory
    95  
    96  ### Modified time ###
    97  
    98  FTP does not support modified times.  Any times you see on the server
    99  will be time of upload.
   100  
   101  ### Checksums ###
   102  
   103  FTP does not support any checksums.
   104  
   105  ### Usage without a config file ###
   106  
   107  An example how to use the ftp remote without a config file:
   108  
   109      rclone lsf :ftp: --ftp-host=speedtest.tele2.net --ftp-user=anonymous --ftp-pass=`rclone obscure dummy`
   110  
   111  #### Restricted filename characters
   112  
   113  In addition to the [default restricted characters set](/overview/#restricted-characters)
   114  the following characters are also replaced:
   115  
   116  File names can also not end with the following characters.
   117  These only get replaced if they are the last character in the name:
   118  
   119  | Character | Value | Replacement |
   120  | --------- |:-----:|:-----------:|
   121  | SP        | 0x20  | ␠           |
   122  
   123  Note that not all FTP servers can have all characters in file names, for example:
   124  
   125  | FTP Server| Forbidden characters |
   126  | --------- |:--------------------:|
   127  | proftpd   | `*`                  |
   128  | pureftpd  | `\ [ ]`              |
   129  
   130  ### Implicit TLS ###
   131  
   132  FTP supports implicit FTP over TLS servers (FTPS). This has to be enabled
   133  in the config for the remote. The default FTPS port is `990` so the
   134  port will likely have to be explicitly set in the config for the remote.
   135  
   136  {{< rem autogenerated options start" - DO NOT EDIT - instead edit fs.RegInfo in backend/ftp/ftp.go then run make backenddocs" >}}
   137  ### Standard Options
   138  
   139  Here are the standard options specific to ftp (FTP Connection).
   140  
   141  #### --ftp-host
   142  
   143  FTP host to connect to
   144  
   145  - Config:      host
   146  - Env Var:     RCLONE_FTP_HOST
   147  - Type:        string
   148  - Default:     ""
   149  - Examples:
   150      - "ftp.example.com"
   151          - Connect to ftp.example.com
   152  
   153  #### --ftp-user
   154  
   155  FTP username, leave blank for current username, $USER
   156  
   157  - Config:      user
   158  - Env Var:     RCLONE_FTP_USER
   159  - Type:        string
   160  - Default:     ""
   161  
   162  #### --ftp-port
   163  
   164  FTP port, leave blank to use default (21)
   165  
   166  - Config:      port
   167  - Env Var:     RCLONE_FTP_PORT
   168  - Type:        string
   169  - Default:     ""
   170  
   171  #### --ftp-pass
   172  
   173  FTP password
   174  
   175  **NB** Input to this must be obscured - see [rclone obscure](/commands/rclone_obscure/).
   176  
   177  - Config:      pass
   178  - Env Var:     RCLONE_FTP_PASS
   179  - Type:        string
   180  - Default:     ""
   181  
   182  #### --ftp-tls
   183  
   184  Use FTP over TLS (Implicit)
   185  
   186  - Config:      tls
   187  - Env Var:     RCLONE_FTP_TLS
   188  - Type:        bool
   189  - Default:     false
   190  
   191  ### Advanced Options
   192  
   193  Here are the advanced options specific to ftp (FTP Connection).
   194  
   195  #### --ftp-concurrency
   196  
   197  Maximum number of FTP simultaneous connections, 0 for unlimited
   198  
   199  - Config:      concurrency
   200  - Env Var:     RCLONE_FTP_CONCURRENCY
   201  - Type:        int
   202  - Default:     0
   203  
   204  #### --ftp-no-check-certificate
   205  
   206  Do not verify the TLS certificate of the server
   207  
   208  - Config:      no_check_certificate
   209  - Env Var:     RCLONE_FTP_NO_CHECK_CERTIFICATE
   210  - Type:        bool
   211  - Default:     false
   212  
   213  #### --ftp-disable-epsv
   214  
   215  Disable using EPSV even if server advertises support
   216  
   217  - Config:      disable_epsv
   218  - Env Var:     RCLONE_FTP_DISABLE_EPSV
   219  - Type:        bool
   220  - Default:     false
   221  
   222  #### --ftp-encoding
   223  
   224  This sets the encoding for the backend.
   225  
   226  See: the [encoding section in the overview](/overview/#encoding) for more info.
   227  
   228  - Config:      encoding
   229  - Env Var:     RCLONE_FTP_ENCODING
   230  - Type:        MultiEncoder
   231  - Default:     Slash,Del,Ctl,RightSpace,Dot
   232  
   233  {{< rem autogenerated options stop >}}
   234  
   235  ### Limitations ###
   236  
   237  Note that since FTP isn't HTTP based the following flags don't work
   238  with it: `--dump-headers`, `--dump-bodies`, `--dump-auth`
   239  
   240  Note that `--timeout` isn't supported (but `--contimeout` is).
   241  
   242  Note that `--bind` isn't supported.
   243  
   244  FTP could support server side move but doesn't yet.
   245  
   246  Note that the ftp backend does not support the `ftp_proxy` environment
   247  variable yet.
   248  
   249  Note that while implicit FTP over TLS is supported,
   250  explicit FTP over TLS is not.