Differences between revisions 17 and 18
Revision 17 as of 2013-05-23 14:52:11
Size: 4527
Comment:
Revision 18 as of 2013-05-23 17:48:49
Size: 4533
Comment:
Deletions are marked like this. Additions are marked like this.
Line 37: Line 37:
[[attachment:12-choose-security-group.png|{{attachment:12-choose-security.png|Choose Security Group|width=600}}]] [[attachment:12-choose-security-group.png|{{attachment:12-choose-security-group.png|Choose Security Group|width=600}}]]

Intro

Solr can be run on Amazon's EC2.

Instructions

/!\ :TODO: /!\ This page is a work in progress that will reflect how to run Solr 4.3 on AWS EC2 with screenshots when I am done. -MDB

  1. Create an Amazon Web Services account. Amazon offers a free usage tier if you're just trying it out for the first time.

  2. Follow the Getting Started with Amazon EC2 Linux Instances guide to become familiar with EC2 instances, security groups, instance keys, and EBS volumes.

  3. Create a security group for Solr servers. It should allow access to ports 22 and 8983 for the IP you're working from, with routing prefix /32 (e.g., 4.2.2.1/32). This will limit access to your current machine. If you want wider access to the instance available to collaborate with others, you can specify that, but make sure you only allow as much access as needed. A Solr instance should not be exposed to general Internet traffic. If you need help figuring out what your IP is, you can always use whatismyip.com. Please note that production security on AWS is a wide ranging topic and is beyond the scope of this tutorial.

  4. Create instance
    1. Click on Launch instance in the EC2 section of the AWS console.

Launch Instance

  • b. Choose "Classic Wizard".

Classic Wizard

  • c. For this demo, we're going to use the 64-bit version of Ubuntu 12.04.2.

Choose AMI

  • d. We're using an m1.large instance for this example. For production use, you're likely going to have to go through an exercise to find the right instance size that matches your content and usage patterns. An m1.large is definitely big enough for this demo, however.

Instance Type

  • e. You don't need to make any changes on the Advanced Options screen.

Advanced Options

  • f. We are going to need to make some changes to the storage configuration, however. Click edit.

Edit Storage

  • g. The root volume is fine for this exercises, but we're going to create a separate EBS volume to store our Solr install and data. By storing this on a seperate volume, we can easily recover from a failed instance or decide to switch to a larger or smaller one by spinning down the instance and attaching our seperate EBS volume to a new one.

EBS Volumes

  • h. We're going to add a new volume here. No need to tweak iops or other settings other than the size.

Add Volume

  1. OK, we have the disks we want. Click Continue.

Continue

  • j. Give your instance a name. The one here is just an example. The name will make it easy to find in the AWS Console, but doesn't affect much else.

Name Instance

  • k. We're going to need a keypair to log in to our instance and configure settings. If you have one set up in your account already, you can elect to use that, but here we're creating a new one for the instance. Make sure you download it and save it in a safe place. If you're using Mac OS X or Linux or Unix, a good place to keep it is in the .ssh folder in your home directory. Create it if it doesn't exist already.

Create Keypair

  • l. Choose the security group we created in step #3.

Choose Security Group

  • k. OK, looking good. Click Launch!

Launch

  1. Log in to instance
  2. Format + mount ebs vol
  3. Download solr to ebs vol
  4. Launch Jetty
  5. Index some stuff

SolrOnAmazonEC2 (last edited 2013-05-23 17:48:49 by MichaelDellaBitta)