2015-09-18 23:48:01 +02:00
|
|
|
/*
|
config/main: Re-write config files - add to new config v3
- New config format.
```
{
"version": "3",
"address": ":9000",
"backend": {
"type": "fs",
"disk": "/path"
},
"credential": {
"accessKey": "WLGDGYAQYIGI833EV05A",
"secretKey": "BYvgJM101sHngl2uzjXS/OBF/aMxAN06JrJ3qJlF"
},
"region": "us-east-1",
"logger": {
"file": {
"enable": false,
"fileName": "",
"level": "error"
},
"syslog": {
"enable": false,
"address": "",
"level": "debug"
},
"console": {
"enable": true,
"level": "fatal"
}
}
}
```
New command lines in lieu of supporting XL.
Minio initialize filesystem backend.
~~~
$ minio init fs <path>
~~~
Minio initialize XL backend.
~~~
$ minio init xl <url1>...<url16>
~~~
For 'fs' backend it starts the server.
~~~
$ minio server
~~~
For 'xl' backend it waits for servers to join.
~~~
$ minio server
... [PROGRESS BAR] of servers connecting
~~~
Now on other servers execute 'join' and they connect.
~~~
....
minio join <url1> -- from <url2> && minio server
minio join <url1> -- from <url3> && minio server
...
...
minio join <url1> -- from <url16> && minio server
~~~
2016-02-13 00:27:10 +01:00
|
|
|
* Minio Cloud Storage, (C) 2015, 2016 Minio, Inc.
|
2015-09-18 23:48:01 +02:00
|
|
|
*
|
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
|
|
* you may not use this file except in compliance with the License.
|
|
|
|
* You may obtain a copy of the License at
|
|
|
|
*
|
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
*
|
|
|
|
* Unless required by applicable law or agreed to in writing, software
|
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
* See the License for the specific language governing permissions and
|
|
|
|
* limitations under the License.
|
|
|
|
*/
|
|
|
|
|
2016-08-19 01:23:42 +02:00
|
|
|
package cmd
|
2015-09-18 23:48:01 +02:00
|
|
|
|
2018-05-09 04:04:36 +02:00
|
|
|
import (
|
|
|
|
"errors"
|
|
|
|
)
|
2015-09-18 23:48:01 +02:00
|
|
|
|
2015-10-18 04:17:33 +02:00
|
|
|
// errInvalidArgument means that input argument is invalid.
|
|
|
|
var errInvalidArgument = errors.New("Invalid arguments specified")
|
2016-03-13 01:08:15 +01:00
|
|
|
|
2018-06-07 03:10:51 +02:00
|
|
|
// errMethodNotAllowed means that method is not allowed.
|
|
|
|
var errMethodNotAllowed = errors.New("Method not allowed")
|
|
|
|
|
2016-03-13 01:08:15 +01:00
|
|
|
// errSignatureMismatch means signature did not match.
|
|
|
|
var errSignatureMismatch = errors.New("Signature does not match")
|
2016-03-31 15:57:29 +02:00
|
|
|
|
2016-07-28 21:02:22 +02:00
|
|
|
// used when we deal with data larger than expected
|
2016-10-10 08:03:10 +02:00
|
|
|
var errSizeUnexpected = errors.New("Data size larger than expected")
|
2016-10-22 18:05:01 +02:00
|
|
|
|
2017-02-02 19:45:00 +01:00
|
|
|
// used when we deal with data with unknown size
|
|
|
|
var errSizeUnspecified = errors.New("Data size is unspecified")
|
|
|
|
|
2016-10-22 18:05:01 +02:00
|
|
|
// When upload object size is greater than 5G in a single PUT/POST operation.
|
|
|
|
var errDataTooLarge = errors.New("Object size larger than allowed limit")
|
2016-10-25 08:47:03 +02:00
|
|
|
|
|
|
|
// When upload object size is less than what was expected.
|
|
|
|
var errDataTooSmall = errors.New("Object size smaller than expected")
|
2016-11-15 22:39:02 +01:00
|
|
|
|
|
|
|
// errServerNotInitialized - server not initialized.
|
2016-11-16 03:14:23 +01:00
|
|
|
var errServerNotInitialized = errors.New("Server not initialized, please try again")
|
2016-11-15 22:39:02 +01:00
|
|
|
|
2018-02-07 00:07:17 +01:00
|
|
|
// errRPCAPIVersionUnsupported - unsupported rpc API version.
|
|
|
|
var errRPCAPIVersionUnsupported = errors.New("Unsupported rpc API version")
|
2016-11-15 22:39:02 +01:00
|
|
|
|
|
|
|
// errServerTimeMismatch - server times are too far apart.
|
2016-11-16 03:14:23 +01:00
|
|
|
var errServerTimeMismatch = errors.New("Server times are too far apart")
|
2017-03-03 12:01:42 +01:00
|
|
|
|
2018-09-06 17:03:18 +02:00
|
|
|
// errOperationTimedOut
|
|
|
|
var errOperationTimedOut = errors.New("Operation timed out")
|
|
|
|
|
2017-09-01 21:16:54 +02:00
|
|
|
// errInvalidBucketName - bucket name is reserved for Minio, usually
|
|
|
|
// returned for 'minio', '.minio.sys', buckets with capital letters.
|
|
|
|
var errInvalidBucketName = errors.New("The specified bucket is not valid")
|
2017-03-04 01:32:04 +01:00
|
|
|
|
|
|
|
// errInvalidRange - returned when given range value is not valid.
|
|
|
|
var errInvalidRange = errors.New("Invalid range")
|
|
|
|
|
|
|
|
// errInvalidRangeSource - returned when given range value exceeds
|
|
|
|
// the source object size.
|
|
|
|
var errInvalidRangeSource = errors.New("Range specified exceeds source object size")
|
2018-04-04 06:58:48 +02:00
|
|
|
|
|
|
|
// error returned by disks which are to be initialized are waiting for the
|
|
|
|
// first server to initialize them in distributed set to initialize them.
|
|
|
|
var errNotFirstDisk = errors.New("Not first disk")
|
2018-04-13 00:43:38 +02:00
|
|
|
|
|
|
|
// error returned by first disk waiting to initialize other servers.
|
|
|
|
var errFirstDiskWait = errors.New("Waiting on other disks")
|
2018-05-01 19:36:37 +02:00
|
|
|
|
|
|
|
// error returned when a bucket already exists
|
|
|
|
var errBucketAlreadyExists = errors.New("Your previous request to create the named bucket succeeded and you already own it")
|
2018-09-28 05:36:17 +02:00
|
|
|
|
|
|
|
// error returned for a negative actual size.
|
|
|
|
var errInvalidDecompressedSize = errors.New("Invalid Decompressed Size")
|
2018-10-16 21:48:19 +02:00
|
|
|
|
|
|
|
// error returned in IAM subsystem when user doesn't exist.
|
|
|
|
var errNoSuchUser = errors.New("Specified user does not exist")
|
|
|
|
|
|
|
|
// error returned in IAM subsystem when policy doesn't exist.
|
|
|
|
var errNoSuchPolicy = errors.New("Specified canned policy does not exist")
|
2018-10-18 01:23:09 +02:00
|
|
|
|
|
|
|
// error returned when access is denied.
|
|
|
|
var errAccessDenied = errors.New("Do not have enough permissions to access this resource")
|