Commit Graph
3383 Commits
Author SHA1 Message Date
Harshavardhana a83ffe321c Implement select command (#2538) 2018-09-30 23:18:33 -07:00
Johan Guldmyr a215fbb718 Update docs with --api flag examples (#2555) 2018-09-26 18:30:11 +05:30
Anis Elleuch 87f7e65c4c Disallow copying/mirroring a folder into itself (#2553)
As unix cp command complains when you copy a directory into itself,
(such as `cp -r ~/Desktop/ ~/Desktop/sub/`), mc will follow the
same behavior with this commit.

The main reason is that copy or mirror command can be unpredictable
with the style of copy.

Example:

```
$ mc ls -r myminio/testbucket/
[2018-09-25 19:28:17 CET]     8B dir/object
[2018-09-25 19:28:40 CET]     8B object

$ mc -q cp -r myminio/testbucket/ myminio/testbucket/dir/
`myminio/testbucket/dir/object` -> `myminio/testbucket/dir/dir/object`
`myminio/testbucket/object` -> `myminio/testbucket/dir/object`

```

We can notice that `myminio/testbucket/dir/object` is both source and target
in the copy operation. The last copy operation that will occur will rule the
result of the total copy operation and `myminio/testbucket/dir/dir/object`
will have a different content in each copy operation.

Due to the unpredictability mentionned above, we will disallow copying or
mirroring a folder into itself.
RELEASE.2018-09-26T00-42-43Z
2018-09-25 17:34:40 -07:00
Praveen raj Mani ab31cf97da Remove extraneous bucket on target while mirroring (#2550)
Fixes  #2527
2018-09-25 10:20:14 -07:00
Praveen raj Mani b2d2e09105 mc heal and mc mirror should respond with proper exit code (#2543)
respond with os.exit(0) incase of errors

Fixes #2534 #2474
RELEASE.2018-09-22T00-47-16Z
2018-09-20 15:23:40 -07:00
kannappanr c9f33698fc Display the config in correct format when json flag is used (#2544)
Fixes #2530
2018-09-19 11:48:21 -07:00
Harshavardhana 044a95b6cf update notify library native macOS compilation (#2540)
Fixes #2535
2018-09-13 18:02:27 -07:00
kannappanr c352cadd4b Display restart failures in admin service restart command (#2533)
Fixes #2532
RELEASE.2018-09-10T23-39-12Z
2018-09-10 16:23:17 -07:00
Harshavardhana 40971c0b93 Vendorize updated crypto/blake2b to compile with go1.11 (#2531)
Fixes #2524
2018-09-10 16:21:09 -07:00
Harshavardhana 0d0638b398 vendorize latest minio-go and madmin (#2529) RELEASE.2018-09-06T23-26-56Z 2018-09-06 16:01:18 -07:00
Harshavardhana 12627c35e4 Fix parallel upload performance issues (#2521)
Tested by transferring 29GiB data, around 246569 files
over 100Gig network.

- master branch
```
time mc mirror /root myminio/testbucket/
real	2m10s
```

- after changes
```
time mc mirror /root myminio/testbucket/
real	1m2s
```

By default runtime.NumCPU() workers are started.
2018-08-30 22:31:08 +05:30
poornas 1d5870b2a2 Fix url parsing of MC_HOSTS_ env variable (#2523) 2018-08-30 22:22:53 +05:30
Nitish Tiwari ae88af8b1b Use go1.10.4 for AppVeyor (#2525) 2018-08-30 08:38:03 -07:00
Harshavardhana bc756e3dbd Fix cp crash when resuming from session (#2520)
We should make sure to handle errors properly
when reading from the session and also parsing.

Current master ignores all these situations
which leads to crash, this PR handles this to avoid
nil pointer crashes.
2018-08-27 12:03:40 -07:00
Aarushi Arya bc679788ac mirror watch: Exit on error while copying. (#2511)
mirror: exit, if copy error occurs while watching.

Fixes #2505
2018-08-23 15:58:14 -07:00
Harshavardhana a1110bc022 Add docs for config get/set commands (#2518) 2018-08-20 22:53:31 +05:30
Harshavardhana 073ed250fe Update madmin API with latest server changes (#2516) RELEASE.2018-08-18T02-13-04Z 2018-08-17 18:55:05 -07:00
Harshavardhana 3b78c115f6 Remove workaround for http response tracer (#2514) 2018-08-17 17:15:03 -07:00
Harshavardhana f8aafcc774 Vendor pkg/madmin changes in GetConfig/SetConfig (#2513) 2018-08-15 03:06:43 -07:00
Durgadas Kamath 22b8ab43bd ISSUE-2507 : Add s390x support for minio-client (#2508) 2018-08-09 14:53:38 -07:00
Anis Elleuch 5eab7c2698 Updating minio-go library (#2506) 2018-08-07 16:57:32 -07:00
Harshavardhana 26f5102eae Remove/deprecate admin lock commands (#2503) 2018-08-06 12:59:13 -07:00
Ashish Kumar Sinha 9998e077df Remove error statement in mc mirror (#2500)
mc mirror complains about extra file in destination,
but this is not an error so removed the error message.

Fixes: #2470
RELEASE.2018-08-02T17-39-44Z
2018-08-02 22:45:54 +05:30
Nitish Tiwari 480bc8aa2a Use randString() to generate random string for S3 sign probe (#2498)
newRandomID() func may return string with uppercase letters. Such
strings will make invalid bucket name as S3 doesn't allow
uppercase lettes in bucket names.

randString() always returns strings with lowercase letters or
numbers.

Fixes #2496
2018-07-31 20:53:39 +05:30
Ryan Boehning a8c97b467d Replace legacy httplex import with current x/net/httpguts (#2494)
The import path of the httplex package has changed.
RELEASE.2018-07-31T02-28-53Z
2018-07-29 00:45:12 -07:00
Harshavardhana 7f01db2cda create bucket automatically when prefix is created (#2488) 2018-07-27 15:29:53 -07:00
Anis Elleuch d83e73b85b Pick a random bucket name when probing for signature version (#2491)
Probing buckets is a mechanism used to automatically detect supported
S3 signature version. However, it seems that probe-bucket-sign is already
used by someone, the thing that makes probing fails with 403 error. This
PR changes the code to pick a random bucket name when probing.
2018-07-24 20:19:26 -07:00
smouli 7e49e2d519 fix for mc find --ignore option (#2489) 2018-07-22 15:03:09 -07:00
ebozduman 5a962a7cf5 Vendorizing changes required for PR#6067 (#2481) 2018-07-16 08:27:22 -07:00
Harshavardhana 70dcf20d74 Pass down encrypt-key handling across command validators (#2483)
Currently even if the command supports encrypted objects,
the syntax verification would fail on them in certain
cases. Since syntax validation of source/targets doesn't
use the parsed encrypt key pairs.  This PR fixes this
behavior.
RELEASE.2018-07-13T00-53-22Z
2018-07-12 11:13:51 -07:00
Harshavardhana c57a2dc4c2 update minio-go dependency to support single statement policies (#2480) 2018-07-06 11:09:59 -07:00
Harshavardhana 4ab7f30f99 Handle directories properly in cp and mirror (#2478)
Fixes #2477
RELEASE.2018-06-30T00-13-31Z
2018-06-29 16:56:02 -07:00
Harshavardhana 29f2dbca6b Fix 'mc mb' to guide the user when bucket is not passed (#2476)
Additionally this PR also allows for creating
prefixes on S3 compatible object storage backends
in the following form

```
mc mb s3/harshavardhana/object/prefix/
```
2018-06-29 14:56:07 -07:00
Harshavardhana 4070902cda Allow creating directories from S3 to filesystem (#2471)
Fixes #2460
RELEASE.2018-06-22T23-32-12Z
2018-06-20 17:47:26 -07:00
kannappanr 556bbc2de5 Vendorize minio-go inside mc (#2473)
Fixes 2465
2018-06-20 15:25:47 -07:00
ebozduman 7e879edabc Removes unsupported flags and fixes the examples in the doc (#2469)
Removes old flags and fixes the examples in the doc
2018-06-19 12:28:36 -07:00
Rafael Peria de Sene f48ac0de19 Add support for ppc64le (#2468)
Signed-off-by: Rafael Peria de Sene <rpsene@br.ibm.com>
2018-06-19 11:23:28 -07:00
kannappanr 1a5aab3ff4 Makefile: Create bin directory if it doesn't exist (#2466) 2018-06-18 07:42:13 -07:00
Harshavardhana 8cf797da5f Update madmin API changes (#2462) RELEASE.2018-06-09T02-18-09Z 2018-06-08 18:00:52 -07:00
Arjun Mishra 023b38fe3f Document adding host configuration through environment variable (#2458) 2018-06-08 12:07:14 -07:00
Harshavardhana afcfe758f3 Fix joinPath function to handle directories properly (#2459) RELEASE.2018-06-07T19-24-28Z 2018-06-06 11:29:05 +05:30
Anis Elleuch c0b89a7aec Add support of empty directories in ls/rm/find commands (#2452) 2018-06-04 17:20:07 -07:00
Nitish Tiwari 4f1f864f64 Fix link to Minio admin complete guide (#2457) 2018-06-01 13:50:14 +05:30
Harshavardhana 2d4346bfe1 Add 'mc admin' complete guide (#2456)
Fixes #2428
2018-06-01 09:16:01 +05:30
Anis Elleuch d566905d7a Properly shutdown parallel copy in cp command (#2448) 2018-05-31 12:38:22 -07:00
Anis Elleuch 743d72ea1a fix: Disable localization to enforce bytewise sorting in functional tests (#2453) 2018-05-30 09:40:42 +05:30
Anis Elleuch 10059459f3 tests: Fix test_find comparaison test (#2455)
`mc find alias/bucket` without trailing slash is actually printing 'alias/bucket' as
first element in the output, the thing which is not taken into consideration in test_find
test. This commit will ask `mc find` to list 'alias/bucket/' instead to have a similar
output as gnu `ls` cmd.
2018-05-29 18:12:27 -07:00
Harshavardhana 376b4ce2f8 Remove deprecated snap mc package (#2454) 2018-05-29 14:51:06 -07:00
Harshavardhana 961c4b5dae Add total used support for mc admin info (#2449) RELEASE.2018-05-25T20-20-15Z 2018-05-23 17:44:50 -07:00
aarushiarya 1711f0bb46 fix for documentation issue (#2446) 2018-05-16 11:06:42 -07:00