Projects/Cloudstone/Chef Configurations
From RAD Lab
Cloudstone deploys and starts the necessary services using Chef, a systems integration framework written in Ruby.
Each Cloudstone service (e.g. MySQL, Rails, Nginx, Faban) has a recipe that is run by passing chef-solo a configuration file written in JSON. This page is organized such that the headings are the name of the configuration file.
| Type | See JSON. |
| Key | Only exists if parent is of type Object. |
Literal | String, Number, Boolean, Null |
| Required | The default value will not work 99% of the time. |
| Defaulted | This setting does not need to be set. It can, however, be overridden. |
Contents |
[edit]
faban-agent
- Array recipes
-
"cloudstone::faban-agent"
-
- Object faban
- String jdbc
null- Options:
null,"mysql","postgresql" - Necessary on the primary (i.e. writing) database instance.
- Options:
- String jdbc
[edit]
faban
- Array recipes
- String
"cloudstone::faban"
- String
- Object faban
- Object hosts
- String webserver
"[Internal IP of Web Server]" - String driver
"[Internal IP of Driver]" - String database
"[Internal IP of DB]" - String cache
"" - String storage
""
- String webserver
- Boolean debug
false- If
true, Faban will suspend and wait for a debugger to attach to port 8000.
- If
- Object database
- String adapter
"mysql"- Options:
"mysql","postgresql"(Use"postgresql"for PGPool-II and"mysql"for MySQL Replication.)
- Options:
- Number port
3306- Suggested:
3306for MySQL,5432for PostgreSQL, and9999for PGPool-II
- Suggested:
- String adapter
- Object code
- String faban
"s3://radlab-cloudstone/faban-kit-062309.tar.gz" - String workload
"s3://radlab-cloudstone/workload-olio-071309.tar.gz" - String images_suffix
"-images"
- String faban
- Object directories
- String faban
"/root/faban" - String workload
"/root/workload"
- String faban
- String benchmark
"OlioDriver.jar" - Object database
- String name
"olio" - String username
"olio" - String password
"olio"
- String name
- String java_home
"/usr/lib/jvm/java-6-openjdk"
- Object hosts
[edit]
haproxy
- Array recipes
- String
"cloudstone::haproxy"
- String
- Object haproxy
- String service_name
"cloudstone_haproxy" - Object servers
- Object localhost
- Number start
3000 - Number count
2 - This needs to point to the Rails instances (usually starting on port
3000).
- Number start
- Object localhost
- Object metric_service
- Number start
null - Number count
null - If metric_service is set, the Director recipe is deployed.
- Number start
- Number max_connections
4096 - Object stats
- Number port
9999 - Boolean enabled
true
- Number port
- Object tcp
- String name
"rails_tcp" - Number port
4000 - Object logs
- Number port
7787 - String host
"127.0.0.1"
- Number port
- String name
- Object http
- String name
"rails" - Number port
3999 - Object logs
- Number port
7788 - String host
"127.0.0.1"
- Number port
- String name
- String service_name
[edit]
memcached
- Array recipes
- String
"cloudstone::memcached"
- String
- Object memcached
- Number size
1024 - Number port
1211
- Number size
[edit]
mysql-initial
- Array recipes
- String
"cloudstone::mysql-initial"
- String
- Object mysql
- Number server_id
2- This needs to be unique across all MySQL instances.
- Object hosts
- String master
null - String initial
"localhost" - Array slaves
- This array must contain the internal IP addresses of the slave instances.
- String master
- Number server_id
Look at the Chef configuration for MySQL to see the defaulted settings.
[edit]
mysql-master
- Array recipes
- String
"cloudstone::mysql-master"
- String
- Object mysql
- Number server_id
1- This needs to be unique across all MySQL instances.
- Object hosts
- String master
"localhost" - String initial
null - Array slaves
- This array must contain the internal IP addresses of the slave instances.
- String master
- Number server_id
Look at the Chef configuration for MySQL to see the defaulted settings.
[edit]
mysql-slave
- Array recipes
- String
"cloudstone::mysql-slave"
- String
- Object mysql
- Number server_id
3- This needs to be unique across all MySQL instances.
- Object hosts
- String master
null - String initial
null - Array slaves
- String
"localhost"
- String
- String master
- Number server_id
Look at the Chef configuration for MySQL to see the defaulted settings.
[edit]
mysql
- Array recipes
- String
"cloudstone::mysql"
- String
- Object mysql
- Number server_id
1- This needs to be unique across all MySQL instances.
- String directory
"/mnt/mysql" - String archive_path
"/tmp/mysql_data.tar.gz" - String service_name
"cloudstone_mysql" - String username
"olio" - String password
"olio" - Number port
3306 - Boolean optimized
true- When enabled, the memory buffer is 3804M (instead of 384M), requiring a 64-bit machine.
- Object slave
- String username
"olio_slave" - String password
"olio_slave"
- String username
- Number server_id
[edit]
nginx
- Array recipes
- String
"cloudstone::nginx"
- String
- Object nginx
- Object servers
- Object localhost
- Number start
3000 - Number count
2 - This should point to either:
- Rails instances (usually starting on port
3000). - HAProxy instance (usually starting on port
4000with count1).
- Rails instances (usually starting on port
- Number start
- Object localhost
- String code
"http://svn.apache.org/repos/asf/incubator/olio/tags/0.1-final/webapp/rails/trunk/" - Object directories
- String app
"/mnt/cloudstone-web" - String local
"/mnt/cloudstone-web/public" - String media
"/mnt/cloudstone-web/public/uploaded_files"
- String app
- String service_name
"cloudstone_webserver"
- Object servers
[edit]
pgpool
- Array recipes
- String
"cloudstone::pgpool"
- String
- Object pgpool
- Object databases
- Number localhost
5432
- Number localhost
- Number max_connections
256 - Number port
9999 - String code
"s3://radlab-cloudstone/pgpool-II-2.2.2.tar.gz" - Object directories
- String pgpool
"/mnt/pgpool" - String socket
"/var/run/pgpool"
- String pgpool
- String username
"olio" - String password
"olio" - String service_name
"cloudstone_pgpool"
- Object databases
[edit]
postgresql
- Array recipes
- String
"cloudstone::postgresql"
- String
- Object postgresql
- Number max_connections
256 - Number port
5432 - String directory
"/mnt/postgresql" - String username
"olio" - String password
"olio" - String service_name
"cloudstone_postgresql"
- Number max_connections
[edit]
rails
- Array recipes
- String
"cloudstone::rails"
- String
- Object rails
- Object memcached
- Number port
1211 - String host
"localhost"
- Number port
- Object ports
- Number start
3000 - Number count
2- This should be roughly twice the number of cores on the instance.
- Number start
- Object geocoder
- String host
"localhost"- This should point to the Faban instance (i.e. piggybacked).
- Number port
9980
- String host
- Object database
- String adapter
"mysql"- Options:
"mysql","mysql_replication","postgresql"(Use"postgresql"for PGPool-II.)
- Options:
- String host
"localhost" - Number port
3306- Suggested:
3306for MySQL,5432for PostgreSQL, and9999for PGPool-II
- Suggested:
- String adapter
- String code
"http://svn.apache.org/repos/asf/incubator/olio/tags/0.1-final/webapp/rails/trunk/" - String directory
"/mnt/cloudstone" - String service_prefix
"cloudstone_thin_" - Object database
- String name
"olio" - String username
"olio" - String password
"olio"
- String name
- String log_level
"error"- Use
"debug"to show debug logs in production mode.
- Use
- Object memcached
