AWS EC2 Linux backup

There is awesome Amazon Linux AMI, I think it is the most popular image that used for creating EC2 across all AWS regions. In fact you read / watch about it in every single tutorial / education course. I can just agree with all listed key features of it, but personally want to admit the following:

AWS EC2 Linux backup

  • Lightweight. Indeed, it's super small and contains just really basic. In free tier it is supplied by GP2 8GiB (General Purpose SSD with up to 3000 IOPS) and for daily tasks that should be fine;
  • Comes with built-in AWS CLI. This is what I really love! In few clicks with IAM role assigned ( (!!!) do NOT forget to do this launching your instance, otherwise you'll miss that huge piece of Amazon);
  • Stable and the most reliable. This might be just my opinion, but as it is driven by Amazon and community, it should be the most robust and mature.

The launch part should be super simple and in most cases people just follow the wizard (keep your pem key in the right place and chmod it to the lowest number you can). There are different use cases people have with this image (from hosting PBX to SQL / noSQL DBs or webservices with Apache / Nginx etc). It's all about data actually and data should be saved and recoverable.

Cloudberry Backup for Linux and it comes with nice command line interface (CLI), what is really important (IMHO, in most cases admins run it without UI).
Ok! The best way to get the software is to download it from CBL website and upload to one of bucket in your AWS S3 service (even through web interface, as it is just one file).

Amazon Linux is actually based on RHEL 5.x and 6 (partially). Go with Red Hat 6.x here.

Now, SSH to your Linux using the following:


ssh ec2-user@public_IP_of_linux_instance -i /path/to/your/pem-file

ec2-user - default user that should be used for remote SSH (you may want to reconfigure it once production), pem-file is the one you download when creating public key (don't loose it and make sure chmod 600 your.pem).

As you have AWS CLI built-in (check this nice video from re:Invent 2015) you actually can work with all AWS services. Let's try it out and output something:


aws s3 ls
2016-09-14 11:05:28 erudinsky-s3
2016-08-07 15:57:25 evgenyrudinsky
aws s3 ls s3://erudinsky-s3
2016-09-14 11:05:49   45135196 rh6_CloudBerryLab_CloudBerryBackup_v1.9.0.16_20160810193949.rpm

Perfect! We can see objects in our buckets! And this is not all! We can also create, update and remove!


aws s3 cp s3://erudinsky-s3/rh6_CloudBerryLab_CloudBerryBackup_v1.9.0.16_20160810193949.rpm /home/ec2-user/

We just copied rpm file (installed package of my CBL Backup for Linux) across to home directory of our default user! Let's install this package quickly! It is very important to set this --nodep flag, that will skip all required dependencies for graphic interface and add all CBL daemons accordingly.


rpm -i rh6_CloudBerryLab_CloudBerryBackup_v1.9.0.16_20160810193949.rpm
error: Failed dependencies:
    libGL.so.1()(64bit) is needed

We just tried wrong way. Let's add the flag! Install the software and activate license (BTW, there is totally FREE version available).


rpm -i rh6_CloudBerryLab_CloudBerryBackup_v1.9.0.16_20160810193949.rpm --nodeps
cbb activateLicense -e "yourname@yourdomain.com" -free -un yourname
cbb activateLicense -e "yourname@yourdomain.com" -free -oa "received random key"
CloudBerry Backup Command Line Interface started

We are done! Let's configure accont (any from the list of 20+ providers, but let's do this to S3 storage provide (Infrequent Accessed Data).


cbb addAccount -d erudinsky-s3 -st AmazonS3 -ac  -sk  -c erudinsky-s3 -ssl
cbb account -l
CloudBerry Backup Command Line Interface started
erudinsky-s3 : AmazonS3
cbb addBackupPlan -n "files" -a "erudinsky-s3" -f /home/ec2-user/files/" -c yes -notification on


In short, this is about:
#ec2
#linux
#cloudberrylab
#amazon

Start discussion:
Related articles:
81 mount aws s3 bucket to your el capitan preview
Learn how to mount S3 bucket to your Mac OS ... more
120 ec2 user data script example preview
Launching AWS EC2 can be supplied by something what is known as "user data" and it helps to have things ready before you access it. ... more
83 cloudberry lab for mac os x 1 8 is now live whoohoo preview
Cloudberry 1.8 for Mac OS X is now live! Impressive list of features and storage platforms support! S3 compatible, new UI and etc. ... more
over 1 year#cloudberrylab #mac
105 conveyoring files for backup cloudberry backup with pre post scripts preview
Working with customers is great experience and you always learn or invent something new. I've been working on the case with files portioning ... more
112 how to follow the 3 2 1 rule with cloudberry backup preview
In this article you'll learn how to protect your data against hardware and software failures according to the 3-2-1 rule. ... more
118 how to send sms using amazon sns and python preview
Send text messages (SMS) with few lines of Python code using Amazon SNS and boto3 SDK. ... more
79 mount aws s3 bucket to your debian preview
In this very short tutorial we are going to mount S3 bucket from AWS to the local folder of Debian. ... more
88 amazon solutions architect associate exam preview
August, 9th, 2016 - passed my Amazon CSAA. Few tips I'd love to share here. ... more
86 call recording asterisk preview
Asterisk IP PBX comes with embedded MixMonitor, that allows us to to record and place those recordings somewhere. ... more
61 amazon web services cloudfront with subdirectory preview
In this article we are going to set up CloudFront for static site. And there is nice tip how to nested content (i.e. subfolders) available. ... more
110 awsrus russian st petersburg user group for aws preview
AWSRus — Official AWS User Group Russia (St. Petersburg). ... more
113 grant fullaccess to all mailboxes in exchange 2010 preview
Since FullAccess is disabled even for Administrator's account in Exchange (including 2010) CloudBerry Backup for Exchange can't restore using Administrator's username and password pair for item level restore of any mailbox. Let's fix it. ... more
116 aws efs windows preview
AWS Elastic File System is scalable file system in the cloud, requires NFSv4.1 client and does not support Windows at the moment. However let's see what we can do.. ... more
119 smtp server for notifications preview
AWS SES supports SMTP settings for sending through it-self. This is really helpful if we want to configure personal outbound server. ... more
117 seo friendly aws static website with ssl preview
It's been written many times, however there is no consistency how to make static web site with SSL and SEO friendly urls (301 redirect). Pure AWS based services static website ahead, check details inside! ... more
121 aws ec2 user data script windows preview
How to pre-deploy App using user data script for Windows OS with powershell powered script in EC2? Example inside. ... more
114 how to download random pictures preview
In CloudBerry Lab we help people to move data offsite to the cloud either with backup or file management solution. Sometimes I need sample files, a lot of sample files. ... more
122 what is possible with aws free tier preview
I made light talk on one of our recent #AWSRus community gathering in Moscow and decided to discover this topic with further series of posts in my blog covering various AWS services. ... more
about 1 month#free tier #amazon
111 data backup and disaster recovery with aws preview
CloudAcademy webinar: how to use AWS services for Backup and DR challenges. I am presenter! ... more