bucket-compact
Compacts the bucket data and map-reduce view index data.
Syntax
The basic syntax is:
couchbase-cli bucket-compact -c [host]:8091 -u [admin] -p [password] [options]
Description
This command compacts the database and index data.
Options
The following are the command options:
Option | Description |
---|---|
--bucket=BUCKETNAME | Named bucket to act on. |
--data-only | Compact bucket data only. |
--view-only | Compact view data only. |
Examples
To compact a bucket for both data and view:
couchbase-cli bucket-compact -c 192.168.0.1:8091 -u Administrator -p password \
--bucket=test_bucket
To compact a bucket for data only:
couchbase-cli bucket-compact -c 192.168.0.1:8091 -u Administrator -p password \
--bucket=test_bucket \
--data-only
To compact a bucket for view only:
couchbase-cli bucket-compact -c 192.168.0.1:8091 -u Administrator -p password \
--bucket=test_bucket \
--view-only