These instructions apply to a manual installation of an agent on Red Hat Linux running under AWS.
- Connect to the AWS Red Hat instance that you want to instrument.
- Install required packages by entering:
sudo yum install perl-Switch perl-DateTime perl-Sys-Syslog perl-LWP-Protocol-https -y
- Download the Cloudwatch monitoring scripts with curl http://aws-cloudwatch.s3.amazonaws.com/downloads/CloudWatchMonitoringScripts-1.2.1.zip -O
- Install the unzip package by entering:
sudo yum install unzip -y
- Unzip CloudWatchMonitoringScripts-1.2.1.zip
- Remove CloudWatchMonitoringScripts-1.2.1.zip
- Change to the directory aws-scripts-mon
- Copy awscreds.template to awscreds.conf
- Edit awscreds.conf and enter your AWS Access Key and your AWS Secret Key, e.g.:
AWSAccessKeyID=<AWS Access Key>
orAWSSecretKey=<Secret Key>
- Install sudo yum -y install perl-Digest-SHA.x86_64
- Check it works by running the command:
./mon-put instance-data.pl --mem-util --aws-credential-file=./awscreds.conf
Note, you must ensure you have the perl-Digest-SHA model installed, to check for which you can use the following command:sudo yum install perl-Digest-SHA
If successful, metrics will be reported to CloudWatch. Reference Id: XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX - Schedule the regular data upload every five minutes by adding the following line to crontab:
*/5 * * * * ~/aws-scripts-mon/mon-put-instance-data.pl --mem-used-incl-cache-buff --mem-util --disk-space-util --disk-path=/ --from-cron
Comments
0 comments
Please sign in to leave a comment.