Here are the instructions on how to communicate with Amazon's API to export a VM from Amazon EC2 to a VMware image that gets put into S3 storage. From that point, you can simply download the VMware image and import it into your VMware environment.
0. Open up a command prompt
1. Setup your java path (you can use JRE or JDK):
set JAVA_HOME="C:\Program Files\Java\jre6"
2. Verify your version with this command (you should see the java version number):
3. Add the bin directory that contains the java executable to your path before other versions of java
4. Verify you can see the java version by executing the following command:
5. Set the EC2_HOME path
6. Verify the ec2_home using
7. Update the path
8. Setup access key environment variables
9. Verify the tools setup -- if setup correctly, we should be able to view our available regions.
10. Execute the following command:
ec2-create-instance-export-task i-EC2INSTANCENAME -e VMware -f VMDK -c ova -b S3STORAGEBUCKET
Once you have executed the command above, you can use the following commands to track/manage the cloning process.
- Use ec2-describe-export-tasks to monitor the export progress
- Use ec2-cancel-export-task to cancel an export task prior to completion
Notes: You could easily take steps 1-8 to setup an automated script to connect to amazon's services. If you would like more information on these steps, here was a great article I ran across explaining everything in detail.