RR Project 4B

CS290F Fall 2006 - UCSB Computer Science - Thorsten von Eicken

Jump to: navigation, search

Contents

Setup

Database

  • restaurant list - 100154 records -27.7 MB table dump
  • restaurant reviews - 1002 records
  • restaurant tags - 3003 records

Optimization

Load Balancing

  • Instead of the default lbmethod=byrequests we are using lbmethod=bytraffic instead
  • Load balancing by number of bytes throughput seems like a better way to load balance between the servers. My bytes served most likely indicates heavier load.

Basic Setup

  • 1 apache reverse proxy + memcached server
  • 1 mysql database server
  • many mongrel cluster (4 mongrel servers)
    • number of mongrel clusters varies between tests

Test Setup

  • test 1 - 1 mongrel cluster
  • test 2 - 2 mongrel clusters
  • test 3 - 5 mongrel clusters

Test Script

  • We are using 1 path this time, to simulate a more realistic usage through the entire site instead of just possible paths
/
/stylesheets/screenstyle.css
/restaurant/index
/account/login
/account/login method=POST contents='login=yyu&password=1234'
/restaurant
/restaurant/list
/restaurant_review/new/1
/restaurant_review/create method=POST
content='restaurant_review[user_id]=1&restaurant_review[overall]=2&restaurant_review[food]=2&restaurant_review[service]=2 \
&restaurant_review[ambiance]=2&restaurant_review[value]=2&restaurant_review[pro]=blahblah&restaurant_review[con]=moreblah \
&restaurant_review[comment]=nada'
/restaurant/list
/restaurant/list?page=2
/restaurant_tag/new/6
/restaurant_tag/create method=POST content='restaurant_tag[restaurant_id]=bitas_tag'
/restaurant/list
/restaurant/list?page=2
/restaurant/show/6
/restaurant/search2 method=POST contents='restaurant[search]=chinese'
/restaurant/index
/restaurant/list?page=2
/restaurant/list?page=3
/restaurant/list?page=4
/restaurant_tag/new/19
/restaurant_tag/create method=POST contents='restaurant_tag[restaurant_id]=bitas_tag'
/restaurant/list
/restaurant/search2 method=POST contents='restaurant[search]=mexican'
/restaurant/show/53199
/restaurant/search2 method=POST contents='restaurant[search]=goleta'
/restaurant/show/50
/restaurant/search2 method=POST contents='restaurant[search]=italian'
/restaurant/show/5
/restaurant_tag/new/7570
/restaurant_tag/create method=POST contents='restaurant_tag[restaurant_id]=bitas_tag'
/restaurant/search2 method=POST contents='restaurant[search]=burger'
/restaurant/show/50
/restaurant/show/43416
/account/logout
/restaurant

Graphs

Performance: replies/sec VS connections/sec
Enlarge
Performance: replies/sec VS connections/sec


Performance: response time (ms) VS connections/sec
Enlarge
Performance: response time (ms) VS connections/sec


Discussion

  • Due to time constraints, 60 sessions were our max session at this time.
  • Every session will take about 5 sec to complete. That's a minimum of 5 minutes per test


Graph 1 - Request/Sec

  • Request/Sec increased as number of app servers were added
  • The difference between 2 servers and 5 servers were very small may be due to the fact that we did crash 3 app server during the process. (See below)

Graph 2 - Response Time

  • Reponse time decreased as number of app servers were added


Crashing App Servers

  • We managed to crash some mongrel cluster app servers when were were doing 5 App servers (4 mongrel servers each)
  • I logged into the crashed app servers, the mongrel cluster app was no longer running.


Image:RR_cluster_error.png

Personal tools