Updating and configuring definitions files properties

OpsCenter updater properties configure the updates for definition files that enable support for different releases of DataStax Enterprise.

Updating and configuring definition files overview

opscenterd.conf

The location of the opscenterd.conf file depends on the type of installation:
  • Package installations: /etc/opscenter/opscenterd.conf
  • Tarball installations: install_location/conf/opscenterd.conf

The definitions properties are for configuring the OpsCenter updater, which automatically downloads and updates the definition files that enable support for different releases of DataStax Enterprise. If an update is found, a remote file named definition_files.tgz is downloaded and applied to the appropriate definition directory.

The OpsCenter machine must have an internet connection to automatically update the definitions files, or to do so manually with an API call; otherwise, you must manually download and update the definitions file.
Note: After manually downloading or changing properties in the definitions file, restart OpsCenter for the changes to take effect.

Definition files configuration properties

Configure the definition file properties in the opscenterd.conf file. Enable or disable the automatic update. Set the frequency with which to check for definition file updates. Override the default download filename, directory, or port.

[definitions] use_ssl
Specifies whether SSL should be used to get definition file updates. This option requires OpenSSL on the OpsCenter host. The default value is True.
[definitions] definitions_dir
The file system location where definition files are stored. The default location is /var/lib/opscenter/definitions for package installations and install_location/definitions for tarball installations.
[definitions] auto_update
Specifies whether OpsCenter should automatically attempt to periodically update the definition files. The default value is True.
[definitions] download_host
The host that definition file update requests will be made to. The default host is opscenter.datastax.com.
[definitions] download_port
The port used to request definition file updates on download_host. The default port is 443.
[definitions] download_filename
The name of the tar file on the download_host that contains definition file updates. The default name is definitions_files.tgz.
[definitions] hash_filename
The name of the hash file on the download_host used to determine if the definition file requires an update. The default file is version.md5.
[definitions] sleep
The duration in seconds between checks to update the definition files. The default time is 3600 seconds (1 hour).

Modifying the update interval

The definition files are automatically updated every hour by default. Modify the default interval by setting the sleep option in the [definitions] section of opscenterd.conf. The sleep interval should be specified in seconds. For example, set the update interval to 7200 seconds (every 2 hours):

[definitions]
  sleep = 7200

Disabling automatic updates of definitions files

Disable the automatic update process by setting auto_update to False in the [definitions] section of opscenterd.conf:

[definitions]
  auto_update = False

Manually updating definition files with an API call

If you prefer to update manually using the API, make an API call directly to OpsCenter to check and download any updates. The call can be made regardless of whether automatic updates are enabled.

curl -X POST http://my.opscenter.host:8888/rc/definition/update

The call returns true if an update was applied; and returns false if no update was found.

For more information about OpsCenter API calls, including updating definitions for LCM, see getting definitions.

Manually updating definition files for offline OpsCenter instances

If the OpsCenter machine does not have an internet connection, you can manually update the definitions.

  1. Download the definitions tarball:
    https://opscenter.datastax.com/definitions/6.1.0/definition_files.tgz
    Note: The URL depends on the currently installed version of OpsCenter. Replace 6.1.0 as shown in the above URL with your currently installed version of OpsCenter.
  2. If applicable, remove any existing files in the definitions directory (definitions_dir):
    [definitions] definitions_dir
    The file system location where definition files are stored. The default location is /var/lib/opscenter/definitions for package installations and install_location/definitions for tarball installations.
  3. Unpack the definitions files tarball into the definitions directory.
  4. Restart opscenterd.