gnocchi #119
Description
Gnocchi is an open-source, multi-tenant timeseries, metrics and resources database. It provides an HTTP REST interface to create and manipulate the data. It is designed to store metrics at a very large scale while providing access to metrics and resources information and history.
- Tags:
- openstack ›
Overview
Gnocchi is an open-source, multi-tenant timeseries, metrics, and resources database. It provides an HTTP REST interface to create and manipulate the data. It is designed to store metrics at a very large scale while providing access to metrics and resources information and history.
Usage
Configuration
See file config.yaml
for the full list of configuration options, along with
their descriptions and default values. See the Juju
documentation for details on configuring applications.
Ceph BlueStore compression
This charm supports BlueStore inline compression
for its associated Ceph storage pool(s). The feature is enabled by assigning a
compression mode via the bluestore-compression-mode
configuration option. The
default behaviour is to disable compression.
The efficiency of compression depends heavily on what type of data is stored in the pool and the charm provides a set of configuration options to fine tune the compression behaviour.
Note: BlueStore compression is supported starting with Ceph Mimic.
Deployment
Gnocchi is typically deployed as part of an OpenStack cloud, providing storage for Ceilometer, the telemetry collection service. To deploy Gnocchi to an existing OpenStack cloud (which already includes Ceilometer):
juju deploy gnocchi
juju deploy memcached
juju add-relation gnocchi:shared-db percona-cluster:shared-db
juju add-relation gnocchi:coordinator-memcached memcached:cache
juju add-relation gnocchi:identity-service keystone:identity-service
juju add-relation gnocchi:storage-ceph ceph-mon:client
juju add-relation gnocchi:metric-service ceilometer:metric-service
The Gnocchi API should now be used to service information queries. As such, once re-configuration caused by the above relations has settled, the Ceilometer API will be disabled.
Gnocchi then needs to be initialised with the current Ceilometer data:
juju run-action --wait ceilometer/leader ceilometer-upgrade
S3 storage backend support
The gnocchi charm by default uses Ceph as a storage backend (the default value
of option storage-backend
is 'ceph') but it also has support for S3 storage.
Note: S3 storage support is available starting with OpenStack Stein.
To configure Gnocchi to use S3 the following configuration options must be set accordingly:
storage-backend
s3-region-name
s3-endpoint-url
s3-access-key-id
s3-secret-access-key
For an encrypted S3 endpoint that is not managed by charmed Vault, the config
option trusted-ssl-ca-cert
needs to be configured.
See file config.yaml
for more details on the above options.
Policy overrides
Policy overrides is an advanced feature that allows an operator to override the default policy of an OpenStack service. The policies that the service supports, the defaults it implements in its code, and the defaults that a charm may include should all be clearly understood before proceeding.
Caution: It is possible to break the system (for tenants and other services) if policies are incorrectly applied to the service.
Policy statements are placed in a YAML file. This file (or files) is then (ZIP) compressed into a single file and used as an application resource. The override is then enabled via a Boolean charm option.
Here are the essential commands (filenames are arbitrary):
zip overrides.zip override-file.yaml
juju attach-resource gnocchi policyd-override=overrides.zip
juju config gnocchi use-policyd-override=true
See appendix Policy Overrides in the OpenStack Charms Deployment Guide for a thorough treatment of this feature.
Bugs
Please report bugs on Launchpad.
For general charm questions refer to the OpenStack Charm Guide.
Configuration
- action-managed-upgrade
- (boolean) If True enables openstack upgrades for this charm via juju actions. You will still need to set openstack-origin to the new repository but instead of an upgrade running automatically across all units, it will wait for you to execute the openstack-upgrade action for this charm on each unit. If False it will revert to existing behavior of upgrading all units on config change.
- bluestore-compression-algorithm
- (string) Compressor to use (if any) for pools requested by this charm. . NOTE: The ceph-osd charm sets a global default for this value (defaults to 'lz4' unless configured by the end user) which will be used unless specified for individual pools.
- bluestore-compression-max-blob-size
- (int) Chunks larger than this are broken into smaller blobs sizing bluestore compression max blob size before being compressed on pools requested by this charm.
- bluestore-compression-max-blob-size-hdd
- (int) Value of bluestore compression max blob size for rotational media on pools requested by this charm.
- bluestore-compression-max-blob-size-ssd
- (int) Value of bluestore compression max blob size for solid state media on pools requested by this charm.
- bluestore-compression-min-blob-size
- (int) Chunks smaller than this are never compressed on pools requested by this charm.
- bluestore-compression-min-blob-size-hdd
- (int) Value of bluestore compression min blob size for rotational media on pools requested by this charm.
- bluestore-compression-min-blob-size-ssd
- (int) Value of bluestore compression min blob size for solid state media on pools requested by this charm.
- bluestore-compression-mode
- (string) Policy for using compression on pools requested by this charm. . 'none' means never use compression. 'passive' means use compression when clients hint that data is compressible. 'aggressive' means use compression unless clients hint that data is not compressible. 'force' means use compression under all circumstances even if the clients hint that the data is not compressible.
- bluestore-compression-required-ratio
- (float) The ratio of the size of the data chunk after compression relative to the original size must be at least this small in order to store the compressed version on pools requested by this charm.
- debug
- (boolean) Enable debug logging
- dns-ha
- (boolean) Use DNS HA with MAAS 2.0. Note if this is set do not set vip settings below.
- haproxy-client-timeout
- (int) Client timeout configuration in ms for haproxy, used in HA configurations. If not provided, default value of 90000ms is used.
- haproxy-connect-timeout
- (int) Connect timeout configuration in ms for haproxy, used in HA configurations. If not provided, default value of 9000ms is used.
- haproxy-queue-timeout
- (int) Queue timeout configuration in ms for haproxy, used in HA configurations. If not provided, default value of 9000ms is used.
- haproxy-server-timeout
- (int) Server timeout configuration in ms for haproxy, used in HA configurations. If not provided, default value of 90000ms is used.
- openstack-origin
- (string) Repository from which to install OpenStack. May be one of the following: distro (default) ppa:somecustom/ppa (PPA name must include OpenStack Release) deb url sources entry|key id or a supported Ubuntu Cloud Archive pocket. Supported Ubuntu Cloud Archive pockets include: cloud:trusty-liberty cloud:trusty-juno cloud:trusty-kilo cloud:trusty-liberty cloud:trusty-mitaka Note that updating this setting to a source that is known to provide a later version of OpenStack will trigger a software upgrade.
- distro
- os-admin-hostname
- (string) The hostname or address of the admin endpoints created in the keystone identity provider. . This value will be used for admin endpoints. For example, an os-admin-hostname set to 'api-admin.example.com' with ssl enabled will create the following endpoint for neutron-api: . https://api-admin.example.com:9696/
- os-admin-network
- (string) The IP address and netmask of the OpenStack Admin network (e.g., 192.168.0.0/24) . This network will be used for admin endpoints.
- os-internal-hostname
- (string) The hostname or address of the internal endpoints created in the keystone identity provider. . This value will be used for internal endpoints. For example, an os-internal-hostname set to 'api-internal.example.com' with ssl enabled will create the following endpoint for neutron-api: . https://api-internal.example.com:9696/
- os-internal-network
- (string) The IP address and netmask of the OpenStack Internal network (e.g., 192.168.0.0/24) . This network will be used for internal endpoints.
- os-public-hostname
- (string) The hostname or address of the public endpoints created in the keystone identity provider. . This value will be used for public endpoints. For example, an os-public-hostname set to 'api-public.example.com' with ssl enabled will create the following endpoint for neutron-api: . https://api-public.example.com:9696/
- os-public-network
- (string) The IP address and netmask of the OpenStack Public network (e.g., 192.168.0.0/24) . This network will be used for public endpoints.
- region
- (string) OpenStack Region
- RegionOne
- s3-access-key-id
- (string) When using a S3 storage backend, user must provide the S3 access key ID.
- s3-bucket-prefix
- (string) When using a S3 storage backend, user must provide the prefix to namespace metric bucket.
- gnocchi
- s3-check-consistency-timeout
- (int) Maximum time to wait checking data consistency when writing to S3. Set to 0 to disable data consistency validation. (floating point value). Minimum value: 0
- 60
- s3-endpoint-url
- (string) When using a S3 storage backend, user must provide the endpoint URL.
- s3-max-pool-connections
- (int) The maximum number of connections to keep in a connection pool. (integer value). Minimum value: 1
- 50
- s3-region-name
- (string) When using a S3 storage backend, user must provide the S3 region name.
- s3-secret-access-key
- (string) When using a S3 storage backend, user must provide the S3 secret access key.
- ssl_ca
- (string) TLS CA to use to communicate with other components in a deployment. . __NOTE__: This configuration option will take precedence over any certificates received over the ``certificates`` relation.
- ssl_cert
- (string) TLS certificate to install and use for any listening services. . __NOTE__: This configuration option will take precedence over any certificates received over the ``certificates`` relation.
- ssl_key
- (string) TLS key to use with certificate specified as ``ssl_cert``. . __NOTE__: This configuration option will take precedence over any certificates received over the ``certificates`` relation.
- storage-backend
- (string) Storage backend to use for Gnocchi. Valid options are ceph or s3.
- ceph
- trusted-external-ca-cert
- (string) Base 64 encoded SSL CA certificate to use for an encrypted S3 endpoint. To be used when the S3 certificates are not managed by charmed Vault.
- use-internal-endpoints
- (boolean) Openstack mostly defaults to using public endpoints for internal communication between services. If set to True this option will configure services to use internal endpoints where possible.
- use-policyd-override
- (boolean) If True then use the resource file named 'policyd-override' to install override YAML files in the service's policy.d directory. The resource file should be a ZIP file containing at least one yaml file with a .yaml or .yml extension. If False then remove the overrides.
- use-syslog
- (boolean) Setting this to True will allow supporting services to log to syslog.
- verbose
- (boolean) Enable verbose logging
- vip
- (string) Virtual IP(s) to use to front API services in HA configuration. If multiple networks are being used, a VIP should be provided for each network, separated by spaces.
- vip_cidr
- (int) Default CIDR netmask to use for HA vip when it cannot be automatically determined.
- 24
- vip_iface
- (string) Default network interface to use for HA vip when it cannot be automatically determined.
- eth0
- worker-multiplier
- (float) The CPU core multiplier to use when configuring worker processes. By default, the number of workers for each daemon is set to twice the number of CPU cores a service unit has. When deployed in a LXD container, this default value will be capped to 4 workers unless this configuration option is set.