Search:

Search all manuals
Search this manual
Manual
Couchbase Server Manual 1.8
Additional Resources
Community Wiki
Community Forums
Couchbase SDKs
Parent Section
7 Command-line Interface for Administration
Chapter Sections
Chapters

7.2. Using couchbase-cli

7.2.1. Listing Servers
7.2.2. Getting Node Information
7.2.3. Adding Nodes to a Cluster
7.2.4. Removing Nodes from Clusters
7.2.5. Rebalancing a Cluster
7.2.6. Initializing Nodes
7.2.7. Viewing Buckets
7.2.8. Creating New Buckets
7.2.9. Updating Bucket Properties
7.2.10. Deleting Buckets
Linux/opt/couchbase/bin/couchbase-cli
WindowsC:\Program Files\Couchbase\Server\bin\cli\couchbase-cli.exe
Mac OS X/Applications/Couchbase\ Server.app/Contents/Resources/couchbase-core/bin/couchbase-cli

This tool provides access to various management operations for Couchbase Server clusters, nodes and buckets. The basic usage format is:

couchbase-cli COMMAND CLUSTER [OPTIONS]

Where:

Table 7.2. Administration — couchbase Tool Commands

CommandDescription
server-listList all servers in a cluster
server-infoShow details on one server
server-addAdd one or more servers to the cluster
server-readdRe-add a server that was failed over to the cluster
rebalanceStart a cluster rebalancing
rebalance-stopStop current cluster rebalancing
rebalance-statusShow status of current cluster rebalancing
failoverFailover one or more servers
cluster-initSet the username, password and port of the cluster
node-initSet node specific parameters
bucket-listList all buckets in a cluster
bucket-createAdd a new bucket to the cluster
bucket-editModify an existing bucket
bucket-deleteDelete an existing bucket
bucket-flushFlush a given bucket
helpShow longer usage/help and examples

Table 7.3. Administration — Standard couchbase Tool Options

OptionCommandDescription
--user=USERNAME,-u USERNAME Administrator username for accessing the cluster
--password=PASSWORD,-p PASSWORD Administrator password for accessing the cluster
--output=KIND,-o KIND Output kind, either json for JSON format, or standard for the native format for the command.
--debug,-d Output debug information.
--server-add=HOST[:PORT]server-add,server-readd, rebalanceServer to be added
--server-add-username=USERNAMEserver-add,server-readd, rebalanceAdmin username for the server to be added
--server-add-password=PASSWORDserver-add,server-readd, rebalanceAdmin password for the server to be added
--server-remove=HOST[:PORT]rebalanceThe server to be removed
--server-failover=HOST[:PORT]failoverServer to failover
--cluster-init-username=USERcluster-initNew admin username
--cluster-init-password=PASSWORDcluster-initNew admin password
--cluster-init-port=PORTcluster-initNew cluster port
--cluster-init-ramsize=300cluster-initNew RAM quota
--bucket=BUCKETNAMEbucket*Bucket to act on
--bucket-type=TYPEbucket*Memcached or Couchbase
--bucket-port=PORTbucket*Supports ASCII protocol and is auth-less
--bucket-password=PASSWORDbucket*Standard port, exclusive with bucket-port
--bucket-ramsize=RAMSIZEMBbucket*RAM quota in MB
--bucket-replica=COUNTbucket*Replication count