Skip to main content

Amazon Backup Vault

Pack Assets

Templates

The Centreon Monitoring Connector Amazon Backup Vault brings a host template:

  • Cloud-Aws-Backup-Vault-custom

It brings the following Service Template:

Service AliasService TemplateService DescriptionDefault
Backup-Vault-Jobs-StatusCloud-Aws-Backup-Vault-Jobs-Status-ApiCheck AWS Backup Vault jobs statusX

Discovery rules

The pack provides a discovery rule to automatically discover Backup vault resources:

image

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

Collected metrics & status

Metric NameDescription
backup.jobs.completed.countNumber of Backup vault jobs completed for the specified timeframe. Default : last 24h.
backup.jobs.failed.countNumber of Backup vault jobs failed for the specified timeframe. Default : last 24h.
backup.jobs.expired.countNumber of Backup vault jobs expired for the specified timeframe. Default : last 24h.
copy.jobs.completed.countNumber of Copy vault jobs completed for the specified timeframe. Default : last 24h.
copy.jobs.failed.countNumber of Copy vault jobs failed for the specified timeframe. Default : last 24h.
recovery.jobs.expired.countNumber of Recovery vault jobs completed for the specified timeframe. Default : last 24h.

Prerequisites

AWS Configuration

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

AWS PrivilegeDescription
backup:ListBackupVaultsGet Backup Vault Names.
cloudwatch:getMetricStatisticsGet metrics from the AWS/EC2 namespace on Cloudwatch.

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

Setup

  1. Install the Centreon package on every Centreon poller expected to monitor AWS Backup Vault resources:
yum install centreon-plugin-Cloud-Aws-Backup-Api
  1. On the Centreon Web interface, install the Amazon Backup Vault Centreon Monitoring Connector on the Configuration > Monitoring Connector Manager page.

Configuration

Host

  • Log into Centreon and add a new Host through Configuration > Hosts.
  • Fill the Name, Alias & IP Address/DNS fields according to your AWS Backup Vault server settings.
  • Select the Cloud-Aws-Backup-Vault-custom template to apply to the Host.
  • Once the template is applied, fill in the corresponding macros. Some macros are mandatory.
MandatoryMacroDescription
XAWSSECRETKEYAWS Secret key of your IAM role. Password checkbox must be checked.
XAWSACESSKEYAWS Access key of your IAM role. Password checkbox must be checked.
XAWSREGIONRegion where the instance is running.
XAWSCUSTOMMODECustom mode to get metrics, 'awscli' is the default, you can also use 'paws' perl library.
XVAULTBACKUPNAMEBackup Vault name containing jobs.
PROXYURLConfigure proxy URL.
EXTRAOPTIONSAny extra option you may want to add to every command_line (eg. a --verbose flag).
DUMMYSTATUSHost state. Default is OK, do not modify it until you know what you are doing.
DUMMYOUTPUTHost check output. Default is 'This is a dummy check'. Customize it with your own if needed.

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 CLI using the centreon-engine user account (su - centreon-engine) and test the Plugin by running the following command with the name of your backup vault:

/usr/lib/centreon/plugins//centreon_aws_backup_api.pl \
--plugin=cloud::aws::backup::plugin \
--mode=jobstatus \
--custommode='awscli' \
--aws-secret-key='' \
--aws-access-key='' \
--region='' \
--backup-vault-name='MY-VAULT' \
--filter-metric='.*' \
--proxyurl='' \
--timeframe='86400' \
--period='3600' \
--zeroed\

The expected command output is shown below:

OK: 'MY-VAULT' Statistic 'Sum' Metrics Number of backup jobs expired: 0.00 , Number of copy jobs completed: 0.00 , Number of backup jobs failed: 0.00 , Number of backup jobs completed: 4.00 , Number of recovery jobs expired: 0.00 , Number of copy jobs failed: 0.00  | 'MY-VAULT~sum#backup.jobs.expired.count'=0.00;;;0; 'MY-VAULT~sum#copy.jobs.completed.count'=0.00;;;0; 'MY-VAULT~sum#backup.jobs.failed.count'=0.00;;;0; 'MY-VAULT~sum#backup.jobs.completed.count'=4.00;;;0; 'MY-VAULT~sum#recovery.jobs.expired.count'=0.00;;;0; 'MY-VAULT~sum#copy.jobs.failed.count'=0.00;;;0;

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

/usr/lib/centreon/plugins//centreon_aws_backup_api.pl \
--plugin=cloud::aws::backup::plugin \
--mode=jobstatus \
--help

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

/usr/lib/centreon/plugins//centreon_aws_backup_api.pl \
--plugin=cloud::aws::backup::plugin \
--list-mode

Troubleshooting

Please find the troubleshooting documentation for Centreon Plugins typical issues.