DSE Metrics Collector configuration examples

Examples of using the dsetool insights_config command to enable, disable, and configure DSE Metrics Collector.

These configuration examples show how to:
  • View the current configuration
  • Enable and disable metrics collection
  • Adjust the interval of metrics collection
  • Adjust the interval to refresh configuration changes
  • Set the maximum size of the local data directory (2 GB limit)
  • Adjust the node system information reporting period

Examples

To view the current DSE Metrics Collector configuration

dsetool insights_config --show_config
The results of the default configuration:
{
  "mode" : "DISABLED",
  "config_refresh_interval_in_seconds" : 30,
  "metric_sampling_interval_in_seconds" : 30,
  "data_dir_max_size_in_mb" : 1024,
  "node_system_info_report_period" : "PT1H"
}

To enable metrics collection when collectd is configured to report to a real-time monitoring system

dsetool insights_config --mode ENABLED_NO_STORAGE

To enable metrics collection with local storage

dsetool insights_config --mode ENABLED_WITH_LOCAL_STORAGE

To configure 1500 MB for the DSE Metrics Collector local data directory

dsetool insights_config --data_dir_max_size_in_mb 1500
Note: The maximum size of the local data directory must not exceed 2 GB.

The default directory for local storage is /var/lib/cassandra/insights_data. To change the directory to store collected metrics, see Configuring the data and log directories for DSE Metrics Collector.

To change the node system reporting duration to 1 week

Use an ISO-8601 time duration string.

dsetool insights_config --node_system_info_report_period P1W

To disable metrics collection

dsetool insights_config --mode DISABLED

To configure the metric sampling interval for 60 seconds

dsetool insights_config --metric_sampling_interval_in_seconds 60

To configure 120 seconds for the configuration refresh interval

Push configuration changes to all nodes in the cluster every 2 minutes:

dsetool insights_config --config_refresh_interval_in_seconds 120
Tip: After you make configuration changes with dsetool insights_config, you must disable and then re-enable DSE Metrics Collector to read the configuration file again. Restarting DSE is not required.