|Did this page help you? Yes No Tell us about it...|
Now that you're signed up for Amazon EC2, you're ready to launch an instance using the AWS Management Console.
The instance you're about to launch will be live (and not running in a sandbox). You will incur the standard Amazon EC2 usage fees for the instance until you terminate it in the last task in this tutorial. The total charges will be minimal (typically less than a dollar). For more information about Amazon EC2 usage rates, go to the Amazon EC2 product page. For more information about the Free Usage Tier, go to the AWS Free Usage Tier product page and Test-Driving AWS in the Free Usage Tier.
To launch an instance
Start the launch wizard:
From the AWS Management Console, click Sign in to the AWS Console and log in with the email address and password you used when signing up for Amazon EC2.
If you pause for a long period of time during this procedure, the AWS Management Console automatically logs you out. To stay logged in while you work through this tutorial, click Settings in the top right corner of the console window and clear the Sign out on inactivity check box.
From the Amazon EC2 Console Dashboard, click Launch Instance to start the Request Instances Wizard.
The first page of the wizard displays a list of basic AMIs on the Quick Start tab.
An Amazon Machine Image (AMI) contains all the information needed to create a new instance of a server. For example, an AMI might contain all the software to act as a web server (e.g., Linux, Apache, and your web site), or all the software to act as a Windows database server (e.g., Windows and SQL Server).
Choose an AMI: Select either the Basic 32-bit Amazon Linux AMI, or a Windows AMI from the list.
After you select an AMI, the wizard steps to the Instance Details page. This is where you control settings such as the number and size of instances to launch (in this tutorial you'll launch a single small instance).
The default settings on this page of the wizard and the next two pages are what you want, so just click Continue on each page.
The wizard displays the Create Key Pair page.
A key pair is a security credential similar to a password, which you use to securely connect to your instance after it's running. If you're new to Amazon EC2 and haven't created any key pairs yet, when the wizard displays the Create Key Pair page, the Create a new Key Pair button is selected by default. We assume you'll want a new key pair.
Create a key pair:
On the Create Key Pair page, enter a name for your key pair
(e.g., GSG_Keypair). This will be the name of the private key file associated with the
pair (with a
Click Create & Download your Key Pair.
You're prompted to save the private key from the key pair to your system.
Save the private key in a safe place on your system. Note the location because you'll need to use the key soon to connect to the instance.
The wizard displays the Configure Firewall page, where you create a security group.
Create a security group:
A security group defines firewall rules for your instances. These rules specify which incoming network traffic should be delivered to your instance (e.g., accept web traffic on port 80). All other traffic is ignored. You can modify rules for a group at any time. The new rules are automatically enforced for all running instances.
If you're new to Amazon EC2 and haven't set up any security groups yet, you need to understand how the wizard handles them. When the wizard displays the Configure Firewall page, the Create a new Security Group button is selected by default, and a security group has already been defined for you. The name and description for the group is quick-start-x. You can change the name and description if you want. The group already has basic firewall rules that enable you to connect to the type of instance you've chosen. The following image shows the rules for the quick-start group if you're launching the Basic 32-bit Amazon Linux AMI 1.0. The rule enables SSH access to the instance from anywhere.
The following image shows the rules for the quick-start group if you're launching the Getting Started on Microsoft Windows Server 2008 AMI. The rules enable Remote Desktop (RDP), MS SQL, and HTTP access to the instance from anywhere.
The quick-start security group enables all IP addresses to access your instance over the specified ports (e.g., SSH). This is acceptable for the short exercise in this tutorial, but it's unsafe for production environments. In production, you'll authorize only a specific IP address or range of addresses to access your instance.
If your AWS account isn't new and has security groups already, the Request Instances Wizard looks for a security group that has rules that might match the type of instance you're launching and preselects that group. You can select a different group or create a new group to launch the instance into.
If the wizard doesn't find an existing group to use, it displays a prepopulated quick-start security group like the ones shown in the preceding images.
Make any changes you want to the security group name or description, and click Continue.
The security group is created and assigned an ID (e.g., sg-b1784ec5). Your instance will be launched into this new security group. The wizard steps to the Review page where you can review the settings and launch the instance.
Review your settings and launch the instance:
A confirmation page is displayed to let you know your instance is launching.
Click Close to close the confirmation page, and then click Instances in the navigation pane to view your instance's status. It takes a short time for an instance to launch. The instance's status will be pending while it's launching.
After a short period, your instance's status switches to running. You can click Refresh to refresh the display.
Record the public DNS name for your instance because you'll need it for the next task. If you select the instance, its details (including the public DNS name) are displayed in the lower pane. You can also click Show/Hide in the top right corner of the page to select which columns to display.
When your instance's status is running, you can connect to it. Click one of the following buttons depending on the type of instance you launched.