Skip to content

Virtualized Cluster

Meni Vaitsi edited this page Jul 21, 2014 · 34 revisions

Deploying AppScale on Virtualized Clusters

AppScale can deploy on virtualized clusters to provide you with an alternative to running over clouds. Follow the directions below to deploy AppScale on four nodes in a virtualized cluster.

Step 1: Start your virtual machines

Begin by launching as many virtual machines as you'd like to use for your AppScale deployment. Be sure to note their IP addresses (which you can get by running "ifconfig"). Also be sure that you know what the root password to each VM is (which you can set by running "passwd").

Step 2: Install AppScale if necessary

If you're using a pre-built AppScale VM, skip this step - you've already got AppScale installed! Otherwise, log into each of your virtual machines (Ubuntu Precise 64-bit) and run:

sudo su
cd /root
wget -O - http://bootstrap.appscale.com | sh

to install AppScale from source. Grab a cup of coffee while this runs, as it can take between 20-45 minutes (depending on the speed of your VMs and network).

Step 3: Deploy AppScale over the VMs

The AppScale Tools are pre-installed on all AppScale virtual machines in "/root/appscale-tools". Begin by logging into one of the machines you started up (which we'll refer to as the "master" VM), and create an AppScale configuration file:

appscale init cluster

You only need to create this configuration file a single time. Modify this file and put in the four IPs for your four VMs:

ips_layout:
 controller : 192.168.33.10
 servers:
 - 192.168.33.11
 - 192.168.33.12
 - 192.168.33.13

If you're running over only one VM, you can leave out the "servers" altogether:

ips_layout:
 controller : 192.168.33.10

Start AppScale

Start AppScale by running:

appscale up

And you should see output resembling the following:

Starting AppScale 2.0.0 over a virtualized cluster.
Log in to your head node: ssh -i /Users/you/.appscale/appscale.key [email protected]
Head node successfully initialized at 192.168.33.10. It is now starting up cassandra.
Copying over deployment credentials
Starting AppController at 192.168.33.10
Please wait for the AppController to finish pre-processing tasks.

Please wait for AppScale to prepare your machines for use.
AppController just started
UserAppServer is at 192.168.33.10
Enter your desired admin e-mail address: [email protected]
Enter new password:
Confirm password:
Creating new user account [email protected]
Creating new user account [email protected]
Your XMPP username is [email protected]
Granting admin privileges to [email protected]
AppScale successfully started!
View status information about your AppScale deployment at http://192.168.33.10:1808/status

If you wish, you can navigate to this URL above to see the status of your AppScale deployment.

Deploy an app

You can deploy Google App Engine applications by running:

appscale deploy ~/path-to-your-app

And you should see output resembling the following:

This AppScale instance is linked to an e-mail address giving it administrator privileges.
...
Done starting up AppScale, now in heartbeat mode

Uploading guestbook...
We have reserved the name guestbook for your application.
Creating remote directory to copy app into
Copying over app
Updating AppController
Please wait for your app to start up.

Your app can be reached at the following URL: http://192.168.33.10:8080

Navigate on your host machine's browser to this address to interact with your app.

Step 4: Shutting down AppScale and terminating your instance

Shut down your apps and AppScale deployment by running:

appscale down

To remove your data and apps:

appscale clean

Getting help

If you run into any problems, please send an email to us via the AppScale Community group or join us on #appscale on freenode.

Clone this wiki locally