Cloud Computing Made Easy®
Linux-php-collab 3-Tier-For-Rackspace
From Cloud Computing Wiki - Kaavo
Contents |
Overview
Like other templates provided with IMOD, the 3-Tier PHP Collab Server template solution for Rackspace is provided as an example to help users develop their own custom System Definitions. Users are expected to develop their own system definitions or customize the provided solutions for their own needs. The information assumes that the user has basic understanding of deploying and starting systems in IMOD. Deploy the system from the template and configure it. Please watch the following two short videos, especially the deploying from template section of the multi-cloud ui wizard video for reference on how to deploy the system from the template, configure it, and launch it. Default username/password for phpCollab is admin/admin.
- For uploading files or your custom code to the server refer to the FAQ on how to upload/download file to and from servers in the cloud
What does it do?
Brings online a fully functional 3 tier PHP Collab collaboration application online with a single click. After the application is up and running go to http://ip-address-of-launched-server/phpCollab (/phpCollab is case sensitive). The templates have actions and events that can be configured to scale up and down the app-tier, backup MySQL database on the RackSpace Cloud Files, and to recover the database from the Cloud Files.
How to configure ?
All servers in web_tier, app_tier and db_tier are of CentOS 5.4 You can choose fedora also.
What deployment time Actions are included in the System Definition?
Bring online fully functional MySQL cluster with 3 servers, App Servers with PHP Collab application on 2 App servers, and 1 apache server with fully functional load-balancer. List of actions
- backup-phpcollab-database you need to input values using your Cloud Files account for this action <parameter name="API_KEY" type="literal" value=""/> <parameter name="USER" type="literal" value=""/>
- restore-phpcollab-database you need to input values using your Cloud Files account for this action <parameter name="API_KEY" type="literal" value=""/> <parameter name="USER" type="literal" value=""/>
- open-port-for-ndbd
- restart-iptables-for-ndbd
- open-port-for-loadbalancer
- open-port-for-apptier
- restart-iptables-for-apptier
- start-app-server
- restart-iptables-for-ndbd
- reload-load-balancer
- start-load-balancer
- install_apache
- configure-load-balancer
- create-phpcolab-conf
- grant-mysql-phpcolab
- configure-phpcolab
- create-phpcolab-db
- ndb-api-start
- manager-kick-start (MySQLcluster manager)
- open-port-for-manager
- create-ndbd-config
- install-mysql-ndbd
- create-manager-config
- install-mysql-manager
What run-time Events are defined in the System Definition?
- Note: You need to go configure the triggers for the events. Refer to the Quick Start Guide for how to configure triggers.
- app-tier-underused (for scaling down the app tier by removing phpCollab server from the app tier)
- app-tier-server-died (for auto recovering a server running phpCollab server)
- app-tier-overloaded (for scaling up the app tier by adding phpCollab server to the app tier)
- backup-database (for backing up the database on Cloud Files, uses backup-phpcollab-database action)
- restore-database (for restoring the database from the Cloud Files, uses restore-phpcollab-database action)
Limitations
- This templates deploy HA-MySQL cluster with two api nodes. However the PHP app doesn't allow configuring two urls for the DB to round robbin the requests and handle failure in case one api url is not working. So although the database have redundancy PHP app only interacts with one API node. JDBC driver for MySQL takes care of the round/robbin b/w multiple API nodes of MySQL cluster to ensure HA, so one work around could be to install the JDBC driver and write PHP wrapper for it. There are two data nodes and two api instances for MySQL to ensure cluster redundancy. To learn more about the MySQL fault tolerant setup refer to MySQL Cluster Fault Tolerance article. Note cluster setup for MySQL is more scalable and robust than the master salve setup, however, it is not fit for all use cases, please refer to MySQL documentation on when to use the MySQL Cluster.
- Current template creates servers from base OS images and installs all the required software. When the system is shutdown the servers are deleted, so it is important to back up your database and any critical data on the Rackspace Cloud Files before shutting down the system. We have provided actions and events in the template for copying database to Rackspace Cloud Files and recovering the database from the backup data on the cloud files. Please use IMOD scheduler to schedule the backups.
![[Wiki Home]](/skins/common/images/wiki.png)