Skip to main content

Posts

Showing posts from October, 2014

Tool to get EC2 Instance Metadata

Download the tool from http://s3.amazonaws.com/ec2metadata/ec2-metadata $ wget http://s3.amazonaws.com/ec2metadata/ec2-metadata Check file permissions and make sure that it is executable $ls -l ec2-metadata If not, change the file premissions and make it executable $ chmod u+x ec2-metadata $ ec2-metadata --help $ec2-metadata -a -To get the ami-id of the instance, run $ec2-metadata -p -To get the public hostname, run $ec2-metadata -o -To get the local ipv4, run

What is yum

Wiki definition The Yellowdog Updater, Modified (yum) is an open-source command-line package-management utility for Linux operating systems using the RPM Package Manager.[2] Though yum has a command-line interface, several other tools provide graphical user interfaces to yum functionality. Yum allows automatic updates, package and dependency management, on RPM-based distributions.[3] Like the Advanced Packaging Tool (APT) from Debian, yum works with software repositories (collections of packages), which can be accessed locally[4] or over a network connection. Under the hood, yum depends on RPM, which is a packaging standard for digital distribution of software, which automatically uses hashes and digisigs to verify the authorship and integrity of said software; unlike some app stores, which serve a similar function, neither yum nor RPM provide built-in support for proprietary restrictions on copying of packages by endusers. Yum is implemented as libraries in the Python prog

EBS volume backup and Snapshot Tagging automation script

aws ec2 create-snapshot --volume-id vol-xxxxxxx --description "nameofsnap-`date +%d%m%y-%HHRs-%MMin-%SSec`" > /tmp/volback.out x=`cat /tmp/volback.out|tail -2|awk '{print $2}'` aws ec2 create-tags --resources `echo "$x" | sed -e 's/^"//'  -e 's/"$//'` --tags Key=Owner,Value=Owner1 Key=Project,Value=Project1 Key=Application,Value=App1 Key=Environment,Value=PROD Key=Name,Value=AWS

AWS EBS Incremental snapshot backup facts

AWS actually manages the metadata of snapshot backups.  After writing data to an Amazon EBS volume, you can periodically create a snapshot of the volume to use as a baseline for new volumes or for data backup. If you make periodic snapshots of a volume, the snapshots are incremental so that only the blocks on the device that have changed after your last snapshot are saved in the new snapshot. Even though snapshots are saved incrementally, the snapshot deletion process is designed so that you need to retain only the most recent snapshot in order to restore the volume. Example: Create a file a.log on Monday and take a snapshot backup name - snap-monday Create a second file b.log on Tuesday and take a snapshot backup name - snap-tuesday Create the third file c.log on Wednesday and take a snapshot backup name - snap-wednesday You don't need to retain all the three snapshots to restore back from latest snapshot ( c.log ). You can restore entire thing from the last

Current EMR Architecture

    Current Architecture 1 A request is sent to Amazon EMR to start a cluster. 2 Amazon EMR creates an Hadoop cluster with a master instance group and core instance group. 3 The master node is added to the master instance group. 4 The slave nodes are added to the core instance group.