Skip to content

Installing on CentOS or RHEL (yum)

Ajay Kumar Mahto edited this page Aug 1, 2017 · 2 revisions

Here is how to install the dependencies. *

sudo yum install -y gcc wget git perl perl-CPAN 

# Grab everything that's available from EPEL 7
# see packages here: https://dl.fedoraproject.org/pub/epel/7/x86_64/repoview/letter_p.group.html
sudo yum install --enablerepo=epel -y perl-Date-Manip perl-DateTime perl-DateTime-TimeZone perl-DateTime-Format-ISO8601
sudo yum install --enablerepo=epel -y perl-File-Slurp perl-Net-SSLeay perl-IO-Socket-SSL perl-Time-HiRes perl-Params-Validate ca-certificates  perl-Net-Amazon-EC2 

# Net::Amazon::EC2 is the only one not available on EPEL 7, so we grab it from CPAN
# needs: Net::Amazon::EC2 -> XML::Simple -> XML::Parser -> XML::SAX::Expat -> expat-devel
sudo yum install -y expat-devel
sudo cpan App::cpanminus  # a better package manager for CPAN
sudo /usr/local/bin/cpanm Net::Amazon::EC2

Finally try ec2-expire-snapshots out (shouldn't complain about missing libraries):

cd ~
git clone https://github.com/alestic/ec2-expire-snapshots.git ec2-expire-snapshots
ec2-expire-snapshots/ec2-expire-snapshots --noaction

*Note

Searching for missing dependencies can be done by their name:

yum list *perl*Manip*

or by searching for the missing file(s):

yum provides "*/ISO8601.pm" 
Clone this wiki locally