Skip to content

Central Collector Installation

Sylvere Richard edited this page Jun 23, 2024 · 107 revisions

Table of contents

Requirements

  • Java 11+ for running the central collector v0.14.2 itself (agents can still be running under Java 8+)
  • Java 17+ for running the central collector v0.14.3 itself (agents can still be running under Java 8+)
  • Cassandra 3.1 or later

Central collector installation

You can install the central collector as either a standalone executable jar file, as a war file deployed in your favorite servlet container, or as a docker container.

Option 1: Running as a standalone executable jar

  1. Download and unzip glowroot-central-0.14.2-dist.zip.

  2. Configure the Cassandra connection in the glowroot-central.properties file.

  3. The first time the central collector connects to Cassandra it will create the keyspace and schema. The keyspace will be created with replication = { 'class' : 'SimpleStrategy', 'replication_factor' : 1 }. If you are running a Cassandra cluster and wish to change this, either create the keyspace before starting the central collector for the first time, or alter the replication strategy after the central collector creates the keyspace.

  4. If you want to set a username and password before starting up, run java -jar glowroot-central.jar setup-admin-user <username> <password> from inside the glowroot-central directory.

  5. From inside the glowroot-central directory, run java -jar glowroot-central.jar.

    The central UI will be available at http://localhost:4000. This port is configurable under Glowroot UI > Configuration > Web.

    The central collector will listen for HTTP/2 connections from agents on port 8181 by default (this port is configurable in the glowroot-central.properties file).

Option 2: Running in your favorite servlet container (Jakarta EE 9+)

  1. Download glowroot-central-0.14.2-dist.war and drop it into your servlet container. The servlet container must be at least Jakarta Servlet 5+ compliant.

  2. Create a directory, e.g. path/to/glowroot-central.

  3. Copy the glowroot-central.properties file from inside the war file at META-INF/glowroot-central.properties to the directory you created above.

  4. Configure the Cassandra connection in the glowroot-central.properties file.

  5. Add the JVM arg -Dglowroot.central.dir=path/to/glowroot-central to your servlet container startup.

  6. The first time glowroot-central connects to Cassandra it will create the keyspace and schema. The keyspace will be created with replication = { 'class' : 'SimpleStrategy', 'replication_factor' : 1 }. If you are running a Cassandra cluster and wish to change this, either create the keyspace before starting the central collector for the first time, or alter the replication strategy after the central collector creates the keyspace.

  7. Start your servlet container.

    The central UI will be available via your servlet container.

    The central collector will listen for HTTP/2 connections from agents on port 8181 by default (this port is configurable in the glowroot-central.properties file).

Option 3: Running in a docker container

  1. Run Cassandra, e.g.

    docker run --name mycassandra -d cassandra
    
  2. Run the central collector, e.g.

    docker run --name myglowroot \
               --link mycassandra:cassandra \
               --publish 0.0.0.0:4000:4000 \
               --publish 0.0.0.0:8181:8181 \
               glowroot/glowroot-central:0.14.2
    

UI over HTTPS?

  1. Set ui.https=true in the glowroot-central.properties file.

  2. Place your certificate and private key in the glowroot-central directory, with filenames ui-cert.pem and ui-key.pem, where ui-cert.pem is a PEM encoded X.509 certificate chain, and ui-key.pem is a PEM encoded PKCS#8 private key without a passphrase.

    Note: A private key and self signed certificate can be generated at the command line meeting these requirements using OpenSSL 1.0.0 or later: openssl req -new -x509 -nodes -days 365 -out ui-cert.pem -keyout ui-key.pem.

    Note: For tips on converting an existing private key and X.509 certificate chain to the required format, see Private key and X.509 certificate chain tips.

    Note: If you want to use the same certificate and private key files for both the UI and agent communication, name them cert.pem and key.pem.