# Configuring the CloudBees Analytics server

Configuring the CloudBees Analytics server
==========================================

After the installation is complete, the following items are created during the first server startup:

*   The CloudBees Software Delivery Automation license to grant access to CloudBees CD/RO data and the API that is required to pull and view CloudBees Analytics data.
    
    To view licenses, from the CloudBees CD/RO main menu, select **Administration**  **Configurations**  **CD Licenses**.
    
*   The CloudBees Software Delivery Automation persona menu items, configured for the CloudBees Analytics context.
    
    To view personas, in the left pane, go to **Administration**  **Personas**.
    
*   An `admin` user that has the CloudBees Software Delivery Automation persona and license associated with it.
    
    For traditional platforms, the default password for the admin user is `changeme`. For Kubernetes installations, a random initial password is created.
    

[](#_ensuring_that_the_cloudbees_analytics_server_is_active)Ensuring that the CloudBees Analytics server is active
------------------------------------------------------------------------------------------------------------------

To ensure that your dashboards start to populate with data, you must make sure that the CloudBees Analytics server is installed.

1.  From the CloudBees navigation, ensure **Analytics** is active.
    
    ![CloudBees Analytics installed](_images/cloudbees-navigation.dfee937.png)
    
    Figure 1. Verify the CloudBees Analytics installation
    

If it is not active, select **Learn more** for licensing information.

[](#_setting_up_connectivity_and_authentication)Setting up connectivity and authentication
------------------------------------------------------------------------------------------

This process is required for traditional CloudBees CD/RO installations and Kubernetes installations using the `cloudbees/cloudbees-flow` chart to manually connect to the `cloudbees/cloudbees-core` chart. Connectivity and authentication is automatically set up for CloudBees CD/RO Kubernetes installations using the `cloudbees/cloudbees-sda` chart, which bundles CloudBees CI and a version of CloudBees CD/RO sufficient to run CloudBees Analytics.

Once you have installed the CloudBees Analytics server you need to set up connectivity and authentication. The data that populates the dashboards is transmitted from CloudBees CI to the CloudBees CD/RO server, and then on to the CloudBees Analytics server.

After you configure CloudBees Analytics, only the data that is created or updated in CloudBees CD/RO is synced with the CloudBees Analytics server. This restriction does not apply to existing data that CloudBees CD/RO does not create or update. For example, data collected using plugins from external systems such as Jira or HP ALM.

To configure the CloudBees Analytics server:

1.  From the CloudBees CD/RO main menu, select **Administration**  **Configurations**  **Analytics server**.
    
2.  Use the following settings to set up connectivity and authentication.
    
     
    
    Checkbox or field
    
    Description
    
    Enable CloudBees Analytics
    
    Specifies whether to enable CloudBees Analytics. This is enabled by default.
    
    URL for Logstash service on the CloudBees Analytics server
    
    URL where Logstash receives data from the CloudBees CD/RO server. This is required if CloudBees Analytics is enabled.
    
    URL for OpenSearch service on the CloudBees Analytics server
    
    URL where the CloudBees CD/RO server retrieves data from OpenSearch. This is required if CloudBees Analytics is enabled.
    
    Authentication Credentials
    
    User name and password for authenticating with the CloudBees Analytics server. The default user name is `reportuser`. Use the password that you defined during the [CloudBees Software Delivery Automation installation](/docs/cloudbees-sda/latest/installing/). If you did not define a password, the default password is `changeme`.
    
    Test Connection
    
    (Optional) Specifies whether to test the connection to the CloudBees Analytics server before you save the configuration. This is disabled by default.
    
3.  Select **Save**.
    

[](#_registering_the_cloudbees_ci_url)Registering the CloudBees CI URL
----------------------------------------------------------------------

This section only applies to CloudBees CI users adding CloudBees Analytics.

To register the CloudBees CI URL:

1.  From the CloudBees CD/RO main menu, select **Administration**  **Configurations**  **CI configurations**.
    
2.  Under **CloudBees CI operations center configurations**, select **New +**.
    
3.  On the **New CI configuration** screen, **Create New CI Configuration**.
    
    *   Enter a name and a description.
        
    *   Under **Configuration type**, select **CloudBees CI operations center**.
        
    *   In **Server URL**, type the URL of the CloudBees CI server. Be sure this is the complete URL of the operations center. You should be able to visit the URL and view the operations center dashboard. A connectivity check is not performed.
        
    
4.  Select **OK**.
    

Once the operations center configuration is created (automatically or manually), data received from connected controllers is processed in CloudBees Analytics after a one-time verification of the connected controller. This requires the CloudBees CD/RO server to make a connection to the operations center, as well as to the connected controller, to verify its identity. In case CloudBees CD/RO cannot communicate with either instance—​the operations center or a connected controller—​for any reason, such as network topology or self-signed certificate verification, this verification fails. The solution in this case is [Creating a CloudBees CI configuration manually](#_creating_a_cloudbees_ci_configuration_manually).

### [](#_creating_a_cloudbees_ci_configuration_manually)Creating a CloudBees CI configuration manually

To manually create CloudBees CI configurations for the controllers and to register their public keys, use the following command.

*   For traditional installations:
    
         ectool createCIConfiguration <controller-name-to-use-as-ci-config-name> \
                --ciConfigurationType CI_CONTROLLER --serverUrl <controller-url> \
                --publicKey $(curl -Iks <controller-url>instance-identity/ | \
                fgrep X-Instance-Identity | cut -d' ' -f2)
    
*   For modern installations (Kubernetes cluster environments):
    
        kubectl exec deploy/flow-server -- \
                ectool createCIConfiguration <controller-name-to-use-as-ci-config-name> \
                       --ciConfigurationType CI_CONTROLLER \
                       --serverUrl <controller-url> \
                       --publicKey $(curl -Iks <controller-url>instance-identity/ | \
                       fgrep X-Instance-Identity | cut -d' ' -f2)
    

For more information about using `ectool`, refer to [Use the CloudBees CD/RO ectool API](/docs/cloudbees-cd-api-ectool/latest/).

[](#_setting_up_the_connection_to_cloudbees_software_delivery_automation_in_cloudbees_ci)Setting up the connection to CloudBees Software Delivery Automation in CloudBees CI
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------

This procedure is required only in the following situations:

*   CloudBees CI on traditional platforms is installed.
    
*   You installed CloudBees CI on modern cloud platforms, but omitted `ci.OperationsCenter.Hostname`.
    

To enable CloudBees CI to send analytics events, set up the connection between CloudBees Software Delivery Automation and CloudBees CI:

1.  From the CloudBees navigation, select **CI**.
    
2.  Select **Manage Jenkins**  **Configure System**, and then scroll down to **Connection to CloudBees Software Delivery Automation**.
    
    ![Connect to CloudBees Software Delivery Automation](../../../cloudbees-common-sda/latest/_images/ci-connect-cd-software-del-auto.89d29da.png)
    
    Figure 2. Connection to CloudBees Software Delivery Automation
    
3.  Enter the **URL of the CloudBees Software Delivery Automation server**. For example, `https://your.hostname/`.
    
4.  Select **Allow analytics events to be sent**.
    
5.  Enter **URL of the CloudBees Software Delivery Automation server**.
    
    If you receive the `Failing response from https://automation server address/ci-events: 403` error, then you must use CloudBees CD/RO to configure this connection. Refer to:
    
    *   [Configuring CloudBees CI controller](/docs/cloudbees-cd/latest/pipelines/ci-integration#_configuring_cloudbees_ci_controllers) to modify the connection via the UI.
        
    *   [createCIConfiguration](https://docs.cloudbees.com/apidocs/ec-perl/latest/c/createCIConfiguration) to use `ec-tool`.
        
    
    You may also encounter the 403 error if you did not add the operations center public key into the CloudBees CI configuration in CloudBees CD/RO. You can get the operations center public key at `OPERATIONS_CENTER_URL/instance-identity` and then copy and paste the public key into the CloudBees CI configuration in CloudBees CD/RO.
    
    After completing the connection configuration in CloudBees CD/RO, return to CloudBees CI and disable and re-enable the **Allow analytics events to be sent** option.
    
6.  Select **Save**.