A newer version of this documentation is available.

View Latest

Verifying the Couchbase Server Installation

    Testing the connection to Couchbase Server can be performed in a number of different ways.

    Basic Verification

    Connecting to the Couchbase Server Web Console with a Web browser provides basic confirmation that a node is available.

    On all platforms, you can access the Web Console by connecting to the embedded Web server on port 8091. For example, if your server can be identified on your network as serverA, you can access the Web Console by going to http://serverA:8091/ or http://<serverA's-IP-address>:8091/. (If you set up Couchbase Server on a port other than 8091, go to that specified port.) You should clear your browser’s cache before attempting to access to the Web Console.

    If you are logged into the node itself, you can go to http://localhost:8091. You can also use the couchbase-cli command to query node to confirm that it is available.

    The Web Console uses the same port as smart clients when communicating with Couchbase Server. If you can connect to the Web Console from a particular machine, then administration and database clients on the same machine can also connect to the core cluster port and perform operations. The Web Console will provide a warning if the Web browser loses connectivity to the node.

    Detailed Verification

    To verify that clients can connect to the node, you can use either cbworkloadgen or telnet.

    The cbworkloadgen command is a python program that performs basic operations (reads and writes) against the Couchbase Server cluster.

    Using telnet only checks the memcached compatibility ports and the memcached text-only protocol.

    Testing With cbworkloadgen

    The command cbworkloadgen generates random data, then performs reads and writes of this data in Couchbase Server. It is not intended to be a performance benchmarking tool.

    To test a Couchbase Server installation using cbworkloadgen, execute the following command, supplying the IP address of the running node:

    > cbworkloadgen -n [host]:8091
            Thread 0 - average set time : 0.0257480939229 seconds , min : 0.00325512886047 seconds , max : 0.0705931186676 seconds , operation timeouts 0

    The progress and activity of the tool can also be monitored within the Web Console.

    Further details about cbworkloadgen can be found on its CLI reference page.

    Testing With telnet

    The simplest method to determine whether Couchbase Server is running is to use telnet to connect to the server with the memcached text protocol.

    Telnet must be installed on your server to connect to Couchbase Server using this method. Most platforms come with telnet pre-installed, but it can be obtained as a separate package if necessary.

    You should not use the telnet method for communicating with Couchbase Server within your application. Instead, use one of the Couchbase Server SDKs.

    Connect to the server (via the legacy memcached protocol using Moxi):

    > telnet localhost1 11211
            Connected to localhost.localdomain (
            Escape character is '^]'.

    Make sure it is responding (stats is a great way to check basic health):

            STAT delete_misses 0
            STAT ep_io_num_write 0
            STAT rejected_conns 0
            STAT time 1286678223
            STAT curr_items_tot 0
            STAT threads 4
            STAT pid 23871

    Store a document:

    set test_key 0 0 1

    Retrieve the document:

    get test_key
            VALUE test_key 0 1


            Connection closed by foreign host.

    All of the memcached protocol’s commands will work through telnet.