CloudBees Analytics server unattended installation

6 minute readAutomation

You can run the CloudBees Analytics server installer in unattended (silent) mode with no user interface on either Windows or Linux. This section includes information for adding a system to a CloudBees Analytics cluster during installation.

For details about the overall steps for installing CloudBees Analytics on a group of servers to create a CloudBees Analytics server cluster, see Installing the CloudBees Analytics Server in Cluster Mode .

Installtion with other CloudBees CD/RO components

For a production environment, CloudBees recommends that you install the CloudBees Analytics server on a system other than systems running other CloudBees CD/RO components (such as the CloudBees CD/RO server, web server, repository server, or agent). If you must install it on the same system (such as for testing or other non-production or trial-basis situations) see CloudBees Analytics server with other components for details.

Silent installation arguments

The following argument table is an excerpt from the installer help text. You can view the full installer help by entering CloudBeesFlowDevOpsInsightServer-x64-<version> --help.

ArgumentDescription

--dataDirectory <arguments>

Directory used to store binaries

Default value on Linux: /opt/cloudbees/sda.

Default value on Windows: %ProgramFiles%\CloudBees\Software Delivery Automation (usually: C:\Program Files\CloudBees\Software Delivery Automation )

--disableSSL

Do not configure the Elasticsearch service to use SSL connections and authentication

Using this option is not recommended in production environments.

The CloudBees Analytics server uses the Elasticsearch search engine and the Logstash data-collection and log-parsing engine to gather data from the CloudBees CD/RO server for use in the Deployments, Releases, and Release Command Center dashboards.

--elasticsearchDataDirectory < directory >

Path to the directory for data stored by Elasticsearch

  • New installations—The CloudBees Analytics server data directory will be used by default.

  • Upgrades—The existing directory will continue to be used by default.

--elasticsearchIndexNumberOfShards <arguments>

Number of primary shards that an index should have. Default value: 2

--elasticsearchInternalPort <arguments>

Port number used for internal communication between nodes within the Elasticsearch cluster. Default value: 9300

--elasticsearchMemoryMB <arguments>

Heap size in MB for the Elasticsearch service. Default value: 2048

--elasticsearchPort <arguments>

Port number to be used by the Elasticsearch service. Default value: 9200

 — elasticsearchRegenerateCertificates

During the update, regenerate the certificates that are used by the Elasticsearch service

--elasticsearchUserPassword <arguments>

Password to use for regular access to the CloudBees Analytics server services. The installer automatically creates a user with the user name reportuser to connect to Elasticsearch. This parameter lets you specify a password for this user. CloudBees recommends that you change the default password

If you do specify a password, the installer will generate a default password changeme.

--help

Display the information in this table

--hostName <arguments>

Host name or IP address to be used by the remote CloudBees CD/RO server to communicate with the CloudBees Analytics server. The default value is the current host name of the machine.

--installDirectory <arguments>

Directory used to store binaries

Default value on Linux: /opt/cloudbees/sda

Default value on Windows: %ProgramFiles%\CloudBees\Software Delivery Automation (usually: C:\Program Files\CloudBees\Software Delivery Automation )

--logstashInitMemoryMB <arguments>

Initial java heap size in MB for the Logstash service. Default value: 256

The CloudBees Analytics server uses the Elasticsearch search engine and the Logstash data-collection and log-parsing engine to gather data from the CloudBees CD/RO server for use in the Deployments, Releases, and Release Command Center dashboards.

--logstashInternalPort <arguments>

Port number used by the Logstash monitoring APIs that provide runtime metrics about Logstash. Default value: 9600

--logstashMaxMemoryMB <arguments>

Maximum Java heap size in MB for the Logstash service. Default value: 1024

--logstashPort <arguments>

Internal port number to be used by the Logstash service. Default value: 9500

--mode <arguments>

Set the installer mode

Available values on Linux: console, silent ` or `standard

Available values on Windows: silent ` or `standard

--nonRoot

(Linux installations) Install as a non-root user or a user without sudo privileges. You cannot use this argument when logged in as the root user.

--remoteServer <arguments>

` <host>[:<port>]` of the remote CloudBees CD/RO server

--remoteServerPassword <arguments>

Password to use when logging in to the remote CloudBees CD/RO server

--remoteServerUser <arguments>

User name to use when logging in to the remote CloudBees CD/RO server

--temp <arguments>

Set the temporary directory used by this program

--unixServerGroup <arguments>

(Linux only) Group name that the CloudBees Analytics server services run as

This is required for silent installation on Linux.

--unixServerUser <arguments>

(Linux only) User name that the CloudBees Analytics server services run as

This is required for silent installation on Linux.

--version

Display installer version information

--windowsServerDomain <arguments>

(Windows only) Domain of the account the CloudBees Analytics server services will run as on Windows

Do not use this parameter if a local account used.

--windowsServerLocalSystem

(Windows only) Run the CloudBees Analytics server services as the local system account

--windowsServerPassword <arguments>

(Windows only) Password of the account that the CloudBees Analytics server services will run as

This is required for silent installation on Windows if the --windowsServerLocalSystem option is not specified.

--windowsServerUser <arguments>

User name of the account the CloudBees Analytics server services will run as on Windows

This is required for silent installation on Windows if the --windowsServerLocalSystem option is not specified.

Additional silent installation arguments

The following argument table is an excerpt from the installer help text. You can view the full installer help by entering CloudBeesFlowDevOpsInsightServer-x64-<version> --help.

ArgumentDescription

--elasticsearchClusterDiscoveryHosts <list>

Comma-delimited list of other nodes in the Elasticsearch cluster that are likely to be live and reachable. The default is 127.0.0.1,[::1].

--elasticsearchClusterName <name>

The name of the Elasticsearch cluster. The default is elasticsearch.

--elasticsearchInitialMasterNodes <number>

Comma-delimited list of the master-eligible node names whose votes should be counted in the very first election to form an Elasticsearch cluster.

--elasticsearchNodeAdditional

This node is not the first node to be installed in the Elasticsearch cluster.

--elasticsearchNodeData <boolean>

This node holds data and performs data -related operations such as CRUD, search, and aggregations. The default is true.

-elasticsearchNodeIngest <boolean>

This node is able to apply an ingest pipeline to a document in order to transform and enrich the document before indexing. The default is true.

--elasticsearchNodeMaster <boolean>

This node is eligible to be elected as the master node, which controls the Elasticsearch cluster. The default is true.

--elasticsearchNodeName <name>

The name of this node in the Elasticsearch cluster. The default is the actual hostname.

--elasticsearchPublishHost <host>

The single interface that the Elasticsearch node advertises to other nodes in the cluster, so that those nodes can connect to it. The default is the value set by the --hostName argument.

--elasticsearchCACertificateFile <file>

The PKCS#12 file containing a CA-signed certificate for the CloudBees Analytics Server, any intermediate CA certificates and a private key.

You can omit this option for a new installation in non-clustered mode or for the first node in clustered mode. In this case, the installer will generate a new self-signed certificate and will use it to sign other TLS certificates.

Installing the CloudBees Analytics server

Enter one of the following commands from a command line.

  • Linux: sudo ./CloudBeesFlowDevOpsInsightServer-x64-<version> --mode silent <arguments>

  • Windows: CloudBeesFlowDevOpsInsightServer-x64-<version>.exe --mode silent <arguments>

where:

  • <version> is your CloudBees Analytics server version number.

  • <arguments> represents any additional silent install arguments.

For a successful installation in this mode, you must specify the following:

  • Linux: Use the --unixServerUser and --unixServerGroup options to specify the user name and group that the CloudBees Analytics server service runs as.

  • Windows: Use the --windowsServerUser, --windowsServerPassword, and --WindowsServerDomain options to specify the user name, password, and domain (if the account is not local) of the account the CloudBees Analytics server service runs as or the --windowsServerLocalSystem option to use the local system account.

Configuring autostart

For non-root/non- sudo Linux installations, you must configure autostart for the CloudBees Analytics services. For instructions, see Configuring Services Autostart for Non-Root/Non-sudo Linux Installations .

Configuring the CloudBees Analytics server

If you chose to skip the option to configure the remote CloudBees CD/RO server during the installation or upgrade of the CloudBees Analytics server, you must do so afterward to ensure connectivity and authentication between the CloudBees Analytics server and the CloudBees CD/RO server. To do this, navigate to Administration ConfigurationsAnalytics server. For details, see Configuring the CloudBees Analytics server.

Checking the CloudBees Analytics server configuration

You can confirm the correct CloudBees Analytics server settings by entering the following ectool command on the CloudBees CD/RO server command line:

ectool getDevOpsInsightServerConfiguration

Following is sample output:

<response requestId="1" nodeId="192.168.5.138">
    <devOpsInsightServerConfiguration>
      <devOpsInsightServerConfigurationId>12642169-71c4-11e7-8a08-0050568f29b0</devOpsInsightServerConfigurationId>
      <createTime>2017-07-26T05:34:19.404Z</createTime>
      <elasticSearchUrl>https://192.168.5.54:9200</elasticSearchUrl>
      <enabled>1</enabled>
      <lastModifiedBy>admin</lastModifiedBy>
      <logStashUrl>https://192.168.5.54:9500</logStashUrl>
      <modifyTime>2017-07-26T05:40:13.458Z</modifyTime>
      <owner>admin</owner>
      <userName>reportuser</userName>
    </devOpsInsightServerConfiguration>
  </response>

For details about the getDevOpsInsightServerConfiguration options, enter

ectool getDevOpsInsightServerConfiguration --help

Testing connectivity

After you enable connectivity and authentication between the CloudBees Analytics server and the CloudBees CD/RO server, you can perform a test by using one of the following methods:

  • Check the Test Connection checkbox on the Administration ConfigurationsAnalytics server select OK.

  • Enter the following ectool command on the CloudBees CD/RO server command line:

    ectool setDevOpsInsightServerConfiguration --testConnection 1

    For details about the setDevOpsInsightServerConfiguration options, enter

    ectool setDevOpsInsightServerConfiguration --help

    For example, the following response appears if the user name or password is incorrect:

    ectool error [InvalidCredentials]: HTTP/1.1 401 Unauthorized: Access to
      'https://192.168.5.54:9500' is denied due to invalid credentials.

    Also, for example, the following response appears if you specify an invalid elasticSearchUrl or logstashUrl :

    ectool error [InvalidUrl]: The url 'https://192.168.5.54:9500' is invalid

    The following example shows the response when a valid elasticSearchUrl is used:

    ectool setDevOpsInsightServerConfiguration
      --elasticSearchUrl https://192.168.5.54:9200 --testConnection 1