migrate-ebs-image - Copy an EBS-backed Amazon Image from one region to another
% migrate-ebs-image --from us-east-1 --to ap-southeast-1 ami-123456
This script copies an EBS-backed Unix/Linux/windows AMI located in the EC2 region indicated by --from to the region indicated by --to. All associated volume snapshots, including LVM and RAID volumes, are migrated as well. If --from is omitted, then the source region is derived from the endpoint URL contained in the EC2_URL environment variable. The --to option is required. This script works with any EBS backed image, including Linux PVM, Linux HVM (cluster) and Windows images. It will not work with any instance- store backed image. To migrate such instances, please see one of the recipes listed online, for example: http://www.dowdandassociates.com/content/howto-move-ec2-instance-store-ami-one-region-another
Options can be abbreviated. For example, you can use -l for --list-regions and -b for --block-device-mapping: --from Region in which the AMI is currently located (e.g. "us-east-1") --to Region to which the AMI is to be copied (e.g. "us-west-1") REQUIRED --access_key EC2 access key --secret_key EC2 secret key --block_device_mapping Add additional block devices to the image. --endpoint EC2 URL (defaults to http://ec2.amazonaws.com/) --kernel Force assignment of kernel in destination image. --ramdisk Force assignment of ramdisk in destination image. --quiet Quench status messages --list_regions List the EC2 regions The --block-device-mapping (-b) option is used to add ephemeral storage to the destination image. Amazon's API doesn't describe ephemeral volumes that are associated with images, and so this information is not copied from the source to the destination image, requiring you to add it back manually. The value of the argument is a block device mapping string in the same format as described for the command line program ec2-register: migrate-ebs-image -f us-east-1 -t ap-southeast-1 \ -b /dev/sdy=ephemeral0 \ ami-123456 Ordinarily the script attempts to guess the correct matching kernel and ramdisk for the destination image based on approximate string matching. You can override these values by manually specifying the kernel and/or ramdisk ID in the destination region. Note that no checking is performed that the values you provide are correct.
The following environment variables are used if the corresponding options are not present: EC2_ACCESS_KEY your access key EC2_SECRET_KEY your secret key EC2_URL the desired region endpoint
This script is part of the Perl VM::EC2 package. To install from the command line: % perl -MCPAN -e 'install VM::EC2' % migrate-ebs-image --from us-east-1 --to ap-southeast-1 ami-123456
This script launches two "m1.small" instances, one each in the source and destination regions. It also creates transient volumes in both regions to hold the root volume and all other EBS snapshots associated with the image. Running it will incur charges for instance run time and data storage. In addition, this script will transfer data from one region to another across the internet, incurring internet data out fees on the source side, and internet data in fees on the destination side. Volumes that contain a filesystem, such as ext4 or ntfs, are copied from source to destination using rsync. Volumes that are part of a RAID or LVM volume are copied at the block level using gzip and dd via the secure shell. In general, rsync will be much faster and parsimonious of network bandwidth than block copying!
VM::EC2, VM::EC2::Staging::Manager
Lincoln Stein, lincoln.stein@gmail.com Copyright (c) 2012 Ontario Institute for Cancer Research This package and its accompanying libraries is free software; you can redistribute it and/or modify it under the terms of the GPL (either version 1, or at your option, any later version) or the Artistic License 2.0. Refer to LICENSE for the full license text. In addition, please see DISCLAIMER.txt for disclaimers of warranty.
Personal Opportunity - Free software gives you access to billions of dollars of software at no cost. Use this software for your business, personal use or to develop a profitable skill. Access to source code provides access to a level of capabilities/information that companies protect though copyrights. Open source is a core component of the Internet and it is available to you. Leverage the billions of dollars in resources and capabilities to build a career, establish a business or change the world. The potential is endless for those who understand the opportunity.
Business Opportunity - Goldman Sachs, IBM and countless large corporations are leveraging open source to reduce costs, develop products and increase their bottom lines. Learn what these companies know about open source and how open source can give you the advantage.
Free Software provides computer programs and capabilities at no cost but more importantly, it provides the freedom to run, edit, contribute to, and share the software. The importance of free software is a matter of access, not price. Software at no cost is a benefit but ownership rights to the software and source code is far more significant.
Free Office Software - The Libre Office suite provides top desktop productivity tools for free. This includes, a word processor, spreadsheet, presentation engine, drawing and flowcharting, database and math applications. Libre Office is available for Linux or Windows.
The Free Books Library is a collection of thousands of the most popular public domain books in an online readable format. The collection includes great classical literature and more recent works where the U.S. copyright has expired. These books are yours to read and use without restrictions.
Source Code - Want to change a program or know how it works? Open Source provides the source code for its programs so that anyone can use, modify or learn how to write those programs themselves. Visit the GNU source code repositories to download the source.
Study at Harvard, Stanford or MIT - Open edX provides free online courses from Harvard, MIT, Columbia, UC Berkeley and other top Universities. Hundreds of courses for almost all major subjects and course levels. Open edx also offers some paid courses and selected certifications.
Linux Manual Pages - A man or manual page is a form of software documentation found on Linux/Unix operating systems. Topics covered include computer programs (including library and system calls), formal standards and conventions, and even abstract concepts.