Skip to main content

Amazon CloudFront

Pack Assets​


The Centreon Monitoring Connector Amazon CloudFront brings a host template:

  • Cloud-Aws-CloudFront-custom

It brings the following service templates:

Service AliasService TemplateService DescriptionDefault
Cloudfront-ErrorsCloud-Aws-Cloudfront-Errors-ApiCheck pages access errorsX
Cloudfront-RequestsCloud-Aws-Cloudfront-Requests-ApiCheck requests numberX
Cloudfront-ThroughputCloud-Aws-Cloudfront-Throughput-ApiCheck upload and download throughputsX

Discovery rules​

The pack provides a discovery rule to automatically discover CloudFront resources:


More information about the Host Discovery module is available in the Centreon documentation: Host Discovery

Collected metrics & status​

Metric NameUnit


AWS Configuration​

Configure a service account (access/secret key combo) for which the following privileges have to be granted:

AWS PrivilegeDescription
cloudwatch:getMetricStatisticsGet metrics from the AWS/EC2 namespace on Cloudwatch.
cloudfront:ListDistributionsGrants permission to list the distributions associated with your AWS account.

Plugin dependencies​

To interact with Amazon APIs, you can use either use the awscli binary provided by Amazon or paws, a Perl AWS SDK (recommended). You must install it on every poller expected to monitor AWS resources.

For now, it is not possible to use paws if you are using a proxy to reach AWS Cloudwatch APIs.

yum install perl-Paws


Monitoring Pack​

If the platform uses an online license, you can skip the package installation instruction below as it is not required to have the pack displayed within the Configuration > Monitoring Connector Manager menu. If the platform uses an offline license, install the package on the central server with the command corresponding to the operating system's package manager:

dnf install centreon-pack-cloud-aws-cloudfront

Whatever the license type (online or offline), install the Amazon CloudFront Pack through the Configuration > Monitoring Connector Manager menu.


Since Centreon 22.04, you can benefit from the 'Automatic plugin installation' feature. When this feature is enabled, you can skip the installation part below.

You still have to manually install the plugin on the poller(s) when:

  • Automatic plugin installation is turned off
  • You want to run a discovery job from a poller that doesn't monitor any resource of this kind yet

More information in the Installing the plugin section.

Use the commands below according to your operating system's package manager:

dnf install centreon-plugin-Cloud-Aws-Cloudfront-Api



  • Log into Centreon and add a new host through Configuration > Hosts.
  • Fill the Name, Alias & IP Address/DNS fields according to your CloudFront server settings.
  • Apply the Cloud-Aws-CloudFront-custom template to the host.
  • Once the template is applied, fill in the corresponding macros. Some macros are mandatory.
AWSCUSTOMMODE(Default: 'paws')
EXTRAOPTIONSAny extra option you may want to add to every command line (eg. a --verbose flag)

How to check in the CLI that the configuration is OK and what are the main options for?​

Once the plugin is installed, log into your Centreon poller's CLI using the centreon-engine user account (su - centreon-engine) and test the plugin by running the following command:

/usr/lib/centreon/plugins// \
--plugin=cloud::aws::cloudfront::plugin \
--mode=throughput \
--custommode='paws' \
--aws-secret-key='' \
--aws-access-key='' \
--aws-role-arn='' \
--region='' \
--id='' \
--proxyurl='' \
--filter-metric='' \
--statistic='sum' \
--timeframe='600' \
--period='60' \
--warning-bytes-uploaded='' \
--critical-bytes-uploaded='' \
--warning-bytes-downloaded='' \
--critical-bytes-downloaded='' \
--per-sec \
--verbose \

The expected command output is shown below:

OK: Bytes Downloaded Bytes Uploaded | 'cloudfront.bytes.downloaded.bytes'=9000;;;; 'cloudfront.bytes.uploaded.bytes'=9000B;;;; 

All available options for a given mode can be displayed by adding the --help parameter to the command:

/usr/lib/centreon/plugins// \
--plugin=cloud::aws::cloudfront::plugin \
--mode=throughput \

All available modes can be displayed by adding the --list-mode parameter to the command:

/usr/lib/centreon/plugins// \
--plugin=cloud::aws::cloudfront::plugin \


Please find the troubleshooting documentation for Centreon Plugins typical issues.