2. 注册完毕后,回到Amazon Web Services页面,点击左边Browse Web Services中的Amazon Elastic Compute Cloud (Beta),然后在EC2页面中,点击右边的Sign Up For This Web Service。这时系统会显示一个收费列表(如下)及要求你输入你的支付方式。
$0.10 per instance-hour consumed (or part of an hour consumed)
Data Transfer
$0.10 per GB - all data transfer in
$0.18 per GB - first 10 TB / month data transfer out
$0.16 per GB - next 40 TB / month data transfer out
$0.13 per GB - data transfer out / month over 50 TB
用户注册后,准备使用它了,这里有几项前提条件:
"Resource Center"->”Amazon Elastic Compute Cloud (Beta) “->"Developer Tools".
"Your Web Services Account"->" AWS Access Identifiers"
-> 在X.509 Certificate 里的"Create New", 保存他们到c:\EC2,命名为"privatekey.pem" and "509certificate.pem"
set EC2_HOME=c:\EC2
set PATH=%PATH%;%EC2_HOME%\bin
set EC2_PRIVATE_KEY=c:\ec2\PrivateKey.pem
set EC2_CERT=c:\ec2\509certificate.pem
set JAVA_HOME=C:\Program Files\Java\jre1.6.0_02
"%JAVA_HOME%\bin\java" –version
java version "1.6.0_02"
Java(TM) SE Runtime Environment (build 1.6.0_02-b06)
Java HotSpot(TM) Client VM (build 1.6.0_02-b06, mixed mode, sharing)
IMAGE ami-20b65349 ec2-public-p_w_picpaths/fedora-core4-base.manifest.xml
amazon available public
IMAGE ami-22b6534b ec2-public-p_w_picpaths/fedora-core4-mysql.manifest.xml
amazon available public
IMAGE ami-23b6534a ec2-public-p_w_picpaths/fedora-core4-apache.manifest.xml
amazon available public
IMAGE ami-25b6534c ec2-public-p_w_picpaths/fedora-core4-apache-mysql.manifest.xml
amazon available public
IMAGE ami-26b6534f ec2-public-p_w_picpaths/developer-p_w_picpath.manifest.xml amazon
available public
IMAGE ami-2bb65342 ec2-public-p_w_picpaths/getting-started.manifest.xml amazon
available public
IMAGE ami-bd9d78d4 ec2-public-p_w_picpaths/demo-paid-AMI.manifest.xml amazon
available public A79EC0DB
MIIEoQIBAAKCAQBuLFg5ujHrtm1jnutSuoO8Xe56LlT+HM8v/xk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wkX/ypeOXnIUcw0Ih/YtGBVAC
DQbsz7LcY1HqXiHKYNWNvXgwwO+oiChjxvEkSdsTTIfnK4VSCvU9BxDbQHjdiNDJbL6oar92UN7V
rBYvChJZF7LvUH4YmVpHAoGAbZ2X7XvoeEO+uZ58/BGKOIGHByHBDiXtzMhdJr15HTYjxK7OgTZm
gK+8zp4L9IbvLGDMJO8vft32XPEWuvI8twCzFH+CsWLQADZMZKSsBasOZ/h1FwhdMgCMcY+Qlzd4
JZKjTSu3i7vhvx6RzdSedXEMNTZWN4qlIx3kR5aHcukCgYA9T+Zrvm1F0seQPbLknn7EqhXIjBaT
P8TTvW/6bdPi23ExzxZn7KOdrfclYRph1LHMpAONv/x2xALIf91UB+v5ohy1oDoasL0gij1houRe
2ERKKdwz0ZL9SWq6VTdhr/5G994CK72fy5WhyERbDjUIdHaK3M849JJuf8cSrvSb4g==
-----END RSA PRIVATE KEY-----
3. 运行是实例。这个过程需要几分钟的时间
RESERVATION r-3e27c657 621657444030 default
INSTANCE i-c3f31eaa ami-25b6534c pending kiki-keypair 0
RESERVATION r-3e27c657 621657444030 default
INSTANCE i-c3f31eaa ami-25b6534c ec2-72-44-51-222.z-1.compute-1.amazonaws.com domU-12-31-36-00-30-74.z-1.compute-1.internal running kiki-keypair 0
PERMISSION default ALLOWS tcp 22 22 FROM CIDR 0.0.0.0/0
C:\EC2\bin>ec2-authorize default -p 80
PERMISSION default ALLOWS tcp 80 80 FROM CIDR 0.0.0.0/0
C:\EC2\bin>ec2-authorize default -p 21
PERMISSION default ALLOWS tcp 80 21 FROM CIDR 0.0.0.0/0
passwd root
/sbin/service vsftpd start
rpm -Uvh ec2-ami-tools.noarch.rpm
注意:在有些实例中,你需要安装Ruby。
注意:account ID可以从Amazon网上的Account Activity地方得到。它显示在页面的左上方,格式象9999-9999-9999。不过要移除中间的连接符只留下12位数字。
INSTANCE i-10a64379 running shutting-down
bash-3.2#shutdown –h now
相关连接
http://docs.amazonwebservices.com/AWSEC2/2007-03-01/GettingStartedGuide/
http://developer.amazonwebservices.com/connect/servlet/KbServlet/download/583-102-1043/ec2-tutorial-transcript-from-castingwords.html