add documentation for multibucket primary object store

This commit is contained in:
Robin Appelman
2016-11-04 14:19:57 +01:00
parent 5129ddd1bd
commit 689f5ad986

View File

@@ -3,7 +3,7 @@ Primary Storage
===========================
It's possible to use an object store as primary storage, this replaces the default
way of storing files in `nextcloud/data` (note that the data directory might still be used
way of storing files in :code:`nextcloud/data` (note that the data directory might still be used
for other reasons)
---------------------------
@@ -26,7 +26,7 @@ outside of Nextcloud.
Configuring
---------------------------
Primary object stores need to be configured in `config.php` by specifying the objectstore
Primary object stores need to be configured in :code:`config.php` by specifying the objectstore
backend and any backend specific configuration.
.. note:: Configuring a primary object store on an existing Nextcloud instance will
@@ -43,9 +43,9 @@ The configuration has the following structure.
),
),
--------
~~~~~~~~~~~~~
Openstack Swift
--------
~~~~~~~~~~~~~
The Swift backend mounts a container on an OpenStack Object Storage server into the virtual filesystem. The class to be used is \\OC\\Files\\ObjectStore\\Swift:
@@ -56,7 +56,8 @@ The Swift backend mounts a container on an OpenStack Object Storage server into
'arguments' => array(
'username' => 'username',
'password' => 'Secr3tPaSSWoRdt7',
'container' => 'nextcloud',
// the container to store the data in
'bucket' => 'nextcloud',
'autocreate' => true,
'region' => 'RegionOne',
// The Identity / Keystone endpoint
@@ -68,3 +69,30 @@ The Swift backend mounts a container on an OpenStack Object Storage server into
'urlType' => 'internal'
),
),
---------------------------
Multibucket Object Store
---------------------------
It's possible to configure Nextcloud to distribute it's data over multiple buckets for scalability purpose.
To setup multiple buckets, :code:`config.php` needs to be configured using :code:`'objectstore_multibucket'`
::
'objectstore_multibucket' => array(
'class' => 'Object\\Storage\\Backend\\Class',
'arguments' => array(
// optional, defaults to 64
'num_buckets' => 64,
// will be prefixed by an integer in the range from 0 to (num_nuckets-1)
'bucket' => 'nextcloud_',
...
),
),
Nextcloud will map every user to a range of buckets and save all files for that user in it's respective bucket.
.. note:: Changing the number of buckets for an existing Nextcloud instance is supported but the
mapping from users to buckets is persistent so only newly created users will be mapped to the
updated range of buckets.