github.com/artpar/rclone@v1.67.3/docs/content/mailru.md (about) 1 --- 2 title: "Mailru" 3 description: "Mail.ru Cloud" 4 versionIntroduced: "v1.50" 5 --- 6 7 # {{< icon "fas fa-at" >}} Mail.ru Cloud 8 9 [Mail.ru Cloud](https://cloud.mail.ru/) is a cloud storage provided by a Russian internet company [Mail.Ru Group](https://mail.ru). The official desktop client is [Disk-O:](https://disk-o.cloud/en), available on Windows and Mac OS. 10 11 ## Features highlights 12 13 - Paths may be as deep as required, e.g. `remote:directory/subdirectory` 14 - Files have a `last modified time` property, directories don't 15 - Deleted files are by default moved to the trash 16 - Files and directories can be shared via public links 17 - Partial uploads or streaming are not supported, file size must be known before upload 18 - Maximum file size is limited to 2G for a free account, unlimited for paid accounts 19 - Storage keeps hash for all files and performs transparent deduplication, 20 the hash algorithm is a modified SHA1 21 - If a particular file is already present in storage, one can quickly submit file hash 22 instead of long file upload (this optimization is supported by rclone) 23 24 ## Configuration 25 26 Here is an example of making a mailru configuration. 27 28 First create a Mail.ru Cloud account and choose a tariff. 29 30 You will need to log in and create an app password for rclone. Rclone 31 **will not work** with your normal username and password - it will 32 give an error like `oauth2: server response missing access_token`. 33 34 - Click on your user icon in the top right 35 - Go to Security / "Пароль и безопасность" 36 - Click password for apps / "Пароли для внешних приложений" 37 - Add the password - give it a name - eg "rclone" 38 - Copy the password and use this password below - your normal login password won't work. 39 40 Now run 41 42 rclone config 43 44 This will guide you through an interactive setup process: 45 46 ``` 47 No remotes found, make a new one? 48 n) New remote 49 s) Set configuration password 50 q) Quit config 51 n/s/q> n 52 name> remote 53 Type of storage to configure. 54 Type of storage to configure. 55 Enter a string value. Press Enter for the default (""). 56 Choose a number from below, or type in your own value 57 [snip] 58 XX / Mail.ru Cloud 59 \ "mailru" 60 [snip] 61 Storage> mailru 62 User name (usually email) 63 Enter a string value. Press Enter for the default (""). 64 user> username@mail.ru 65 Password 66 67 This must be an app password - rclone will not work with your normal 68 password. See the Configuration section in the docs for how to make an 69 app password. 70 y) Yes type in my own password 71 g) Generate random password 72 y/g> y 73 Enter the password: 74 password: 75 Confirm the password: 76 password: 77 Skip full upload if there is another file with same data hash. 78 This feature is called "speedup" or "put by hash". It is especially efficient 79 in case of generally available files like popular books, video or audio clips 80 [snip] 81 Enter a boolean value (true or false). Press Enter for the default ("true"). 82 Choose a number from below, or type in your own value 83 1 / Enable 84 \ "true" 85 2 / Disable 86 \ "false" 87 speedup_enable> 1 88 Edit advanced config? (y/n) 89 y) Yes 90 n) No 91 y/n> n 92 Remote config 93 -------------------- 94 [remote] 95 type = mailru 96 user = username@mail.ru 97 pass = *** ENCRYPTED *** 98 speedup_enable = true 99 -------------------- 100 y) Yes this is OK 101 e) Edit this remote 102 d) Delete this remote 103 y/e/d> y 104 ``` 105 106 Configuration of this backend does not require a local web browser. 107 You can use the configured backend as shown below: 108 109 See top level directories 110 111 rclone lsd remote: 112 113 Make a new directory 114 115 rclone mkdir remote:directory 116 117 List the contents of a directory 118 119 rclone ls remote:directory 120 121 Sync `/home/local/directory` to the remote path, deleting any 122 excess files in the path. 123 124 rclone sync --interactive /home/local/directory remote:directory 125 126 ### Modification times and hashes 127 128 Files support a modification time attribute with up to 1 second precision. 129 Directories do not have a modification time, which is shown as "Jan 1 1970". 130 131 File hashes are supported, with a custom Mail.ru algorithm based on SHA1. 132 If file size is less than or equal to the SHA1 block size (20 bytes), 133 its hash is simply its data right-padded with zero bytes. 134 Hashes of a larger file is computed as a SHA1 of the file data 135 bytes concatenated with a decimal representation of the data length. 136 137 ### Emptying Trash 138 139 Removing a file or directory actually moves it to the trash, which is not 140 visible to rclone but can be seen in a web browser. The trashed file 141 still occupies part of total quota. If you wish to empty your trash 142 and free some quota, you can use the `rclone cleanup remote:` command, 143 which will permanently delete all your trashed files. 144 This command does not take any path arguments. 145 146 ### Quota information 147 148 To view your current quota you can use the `rclone about remote:` 149 command which will display your usage limit (quota) and the current usage. 150 151 ### Restricted filename characters 152 153 In addition to the [default restricted characters set](/overview/#restricted-characters) 154 the following characters are also replaced: 155 156 | Character | Value | Replacement | 157 | --------- |:-----:|:-----------:| 158 | " | 0x22 | " | 159 | * | 0x2A | * | 160 | : | 0x3A | : | 161 | < | 0x3C | < | 162 | > | 0x3E | > | 163 | ? | 0x3F | ? | 164 | \ | 0x5C | \ | 165 | \| | 0x7C | | | 166 167 Invalid UTF-8 bytes will also be [replaced](/overview/#invalid-utf8), 168 as they can't be used in JSON strings. 169 170 {{< rem autogenerated options start" - DO NOT EDIT - instead edit fs.RegInfo in backend/mailru/mailru.go then run make backenddocs" >}} 171 ### Standard options 172 173 Here are the Standard options specific to mailru (Mail.ru Cloud). 174 175 #### --mailru-client-id 176 177 OAuth Client Id. 178 179 Leave blank normally. 180 181 Properties: 182 183 - Config: client_id 184 - Env Var: RCLONE_MAILRU_CLIENT_ID 185 - Type: string 186 - Required: false 187 188 #### --mailru-client-secret 189 190 OAuth Client Secret. 191 192 Leave blank normally. 193 194 Properties: 195 196 - Config: client_secret 197 - Env Var: RCLONE_MAILRU_CLIENT_SECRET 198 - Type: string 199 - Required: false 200 201 #### --mailru-user 202 203 User name (usually email). 204 205 Properties: 206 207 - Config: user 208 - Env Var: RCLONE_MAILRU_USER 209 - Type: string 210 - Required: true 211 212 #### --mailru-pass 213 214 Password. 215 216 This must be an app password - rclone will not work with your normal 217 password. See the Configuration section in the docs for how to make an 218 app password. 219 220 221 **NB** Input to this must be obscured - see [rclone obscure](/commands/rclone_obscure/). 222 223 Properties: 224 225 - Config: pass 226 - Env Var: RCLONE_MAILRU_PASS 227 - Type: string 228 - Required: true 229 230 #### --mailru-speedup-enable 231 232 Skip full upload if there is another file with same data hash. 233 234 This feature is called "speedup" or "put by hash". It is especially efficient 235 in case of generally available files like popular books, video or audio clips, 236 because files are searched by hash in all accounts of all mailru users. 237 It is meaningless and ineffective if source file is unique or encrypted. 238 Please note that rclone may need local memory and disk space to calculate 239 content hash in advance and decide whether full upload is required. 240 Also, if rclone does not know file size in advance (e.g. in case of 241 streaming or partial uploads), it will not even try this optimization. 242 243 Properties: 244 245 - Config: speedup_enable 246 - Env Var: RCLONE_MAILRU_SPEEDUP_ENABLE 247 - Type: bool 248 - Default: true 249 - Examples: 250 - "true" 251 - Enable 252 - "false" 253 - Disable 254 255 ### Advanced options 256 257 Here are the Advanced options specific to mailru (Mail.ru Cloud). 258 259 #### --mailru-token 260 261 OAuth Access Token as a JSON blob. 262 263 Properties: 264 265 - Config: token 266 - Env Var: RCLONE_MAILRU_TOKEN 267 - Type: string 268 - Required: false 269 270 #### --mailru-auth-url 271 272 Auth server URL. 273 274 Leave blank to use the provider defaults. 275 276 Properties: 277 278 - Config: auth_url 279 - Env Var: RCLONE_MAILRU_AUTH_URL 280 - Type: string 281 - Required: false 282 283 #### --mailru-token-url 284 285 Token server url. 286 287 Leave blank to use the provider defaults. 288 289 Properties: 290 291 - Config: token_url 292 - Env Var: RCLONE_MAILRU_TOKEN_URL 293 - Type: string 294 - Required: false 295 296 #### --mailru-speedup-file-patterns 297 298 Comma separated list of file name patterns eligible for speedup (put by hash). 299 300 Patterns are case insensitive and can contain '*' or '?' meta characters. 301 302 Properties: 303 304 - Config: speedup_file_patterns 305 - Env Var: RCLONE_MAILRU_SPEEDUP_FILE_PATTERNS 306 - Type: string 307 - Default: "*.mkv,*.avi,*.mp4,*.mp3,*.zip,*.gz,*.rar,*.pdf" 308 - Examples: 309 - "" 310 - Empty list completely disables speedup (put by hash). 311 - "*" 312 - All files will be attempted for speedup. 313 - "*.mkv,*.avi,*.mp4,*.mp3" 314 - Only common audio/video files will be tried for put by hash. 315 - "*.zip,*.gz,*.rar,*.pdf" 316 - Only common archives or PDF books will be tried for speedup. 317 318 #### --mailru-speedup-max-disk 319 320 This option allows you to disable speedup (put by hash) for large files. 321 322 Reason is that preliminary hashing can exhaust your RAM or disk space. 323 324 Properties: 325 326 - Config: speedup_max_disk 327 - Env Var: RCLONE_MAILRU_SPEEDUP_MAX_DISK 328 - Type: SizeSuffix 329 - Default: 3Gi 330 - Examples: 331 - "0" 332 - Completely disable speedup (put by hash). 333 - "1G" 334 - Files larger than 1Gb will be uploaded directly. 335 - "3G" 336 - Choose this option if you have less than 3Gb free on local disk. 337 338 #### --mailru-speedup-max-memory 339 340 Files larger than the size given below will always be hashed on disk. 341 342 Properties: 343 344 - Config: speedup_max_memory 345 - Env Var: RCLONE_MAILRU_SPEEDUP_MAX_MEMORY 346 - Type: SizeSuffix 347 - Default: 32Mi 348 - Examples: 349 - "0" 350 - Preliminary hashing will always be done in a temporary disk location. 351 - "32M" 352 - Do not dedicate more than 32Mb RAM for preliminary hashing. 353 - "256M" 354 - You have at most 256Mb RAM free for hash calculations. 355 356 #### --mailru-check-hash 357 358 What should copy do if file checksum is mismatched or invalid. 359 360 Properties: 361 362 - Config: check_hash 363 - Env Var: RCLONE_MAILRU_CHECK_HASH 364 - Type: bool 365 - Default: true 366 - Examples: 367 - "true" 368 - Fail with error. 369 - "false" 370 - Ignore and continue. 371 372 #### --mailru-user-agent 373 374 HTTP user agent used internally by client. 375 376 Defaults to "rclone/VERSION" or "--user-agent" provided on command line. 377 378 Properties: 379 380 - Config: user_agent 381 - Env Var: RCLONE_MAILRU_USER_AGENT 382 - Type: string 383 - Required: false 384 385 #### --mailru-quirks 386 387 Comma separated list of internal maintenance flags. 388 389 This option must not be used by an ordinary user. It is intended only to 390 facilitate remote troubleshooting of backend issues. Strict meaning of 391 flags is not documented and not guaranteed to persist between releases. 392 Quirks will be removed when the backend grows stable. 393 Supported quirks: atomicmkdir binlist unknowndirs 394 395 Properties: 396 397 - Config: quirks 398 - Env Var: RCLONE_MAILRU_QUIRKS 399 - Type: string 400 - Required: false 401 402 #### --mailru-encoding 403 404 The encoding for the backend. 405 406 See the [encoding section in the overview](/overview/#encoding) for more info. 407 408 Properties: 409 410 - Config: encoding 411 - Env Var: RCLONE_MAILRU_ENCODING 412 - Type: Encoding 413 - Default: Slash,LtGt,DoubleQuote,Colon,Question,Asterisk,Pipe,BackSlash,Del,Ctl,InvalidUtf8,Dot 414 415 #### --mailru-description 416 417 Description of the remote 418 419 Properties: 420 421 - Config: description 422 - Env Var: RCLONE_MAILRU_DESCRIPTION 423 - Type: string 424 - Required: false 425 426 {{< rem autogenerated options stop >}} 427 428 ## Limitations 429 430 File size limits depend on your account. A single file size is limited by 2G 431 for a free account and unlimited for paid tariffs. Please refer to the Mail.ru 432 site for the total uploaded size limits. 433 434 Note that Mailru is case insensitive so you can't have a file called 435 "Hello.doc" and one called "hello.doc".