Summary
Rudimentary monitoring of core server data is done using a combination of a set of Perl scripts from AWS and CloudWatch. In addition to these EC2 instance key metric checks, full end-to-end testing of Shibboleth is accomplished using webisoget which is available from http://staff.washington.edu/fox/webisoget/webisoget-2.4.tar.gz.
The steps necessary to install and configure these tools is described below.
Prerequisite Perl Script Tasks
On AWS Linux
yum -y install perl-Switch perl-Sys-Syslog perl-LWP-Protocol-https
On RHEL
yum -y install ftp
Code Block |
---|
cd /root ftp ftp.perl.org <log in as anonymous> cd pub/CPAN/authors/id/G/GA/GAAS get libwww-perl-5.837.tar.gz cd libwww-perl perl Makefile.PL make make install |
Perl Script Installation
For both AWS Linux and RHEL
cd /root
get http://ec2-downloads.s3.amazonaws.com/cloudwatch-samples/CloudWatchMonitoringScripts-v1.1.0.zip
unzip CloudWatchMonitoringScripts-v1.1.0.zip
cd aws-scripts-mon
cp awscreds.template awscreds
Edit and insert proper credentials
Then, as root, 'crontab -e' and add the following to root's crontab:
Code Block |
---|
# Send key instance statistics to cloudwatch every 5 minutes # */5 * * * * /root/aws-scripts-mon/mon-put-instance-data.pl --aws-credential-file=/root/aws-scripts-mon/awscreds --disk-path=/ --disk-space-util --mem-util --swap-util --from-cron |