Monday, February 11, 2013

WSO2 Stratos 1.6 - How to intall and Configure

Prerequisites

I. MySQL Server
    Download the setup from http://dev.mysql.com/downloads/mysql/ or
    in Ubuntu
sudo apt-get install mysql-server

2. Stratos assumes the password of MySQL is 'root'. So change mysql root password to root

mysqladmin -u root -p 'oldpassword' password root  


Step 1- Download the local WSO2 Stratos setup version 1.6 from http://wso2.com/cloud/stratos/. Extract the downloaded setup and go inside the folder. We will name this folder as

Step 2- To initialise the setup run ./initialize.sh In initialization, appropriate database tables and database users and required configurations will be created.

 ./initialize.sh 

Step 3- Add following entry to /etc/hosts file. So below links will points to localhost

127.0.0.1 stratos-local.wso2.com
127.0.0.1 management.appserver.stratos-local.wso2.com
127.0.0.1 appserver.stratos-local.wso2.com
127.0.0.1 management.esb.stratos-local.wso2.com
127.0.0.1 esb.stratos-local.wso2.com
127.0.0.1 management.data.stratos-local.wso2.com
127.0.0.1 data.stratos-local.wso2.com
127.0.0.1 monitor.stratos-local.wso2.com
127.0.0.1 management.process.stratos-local.wso2.com
127.0.0.1 process.stratos-local.wso2.com
127.0.0.1 governance.stratos-local.wso2.com
127.0.0.1 identity.stratos-local.wso2.com
127.0.0.1 storage.stratos-local.wso2.com
127.0.0.1 cep.stratos-local.wso2.com
127.0.0.1 task.stratos-local.wso2.com
127.0.0.1 messaging.stratos-local.wso2.com
127.0.0.1 management.rule.stratos-local.wso2.com
127.0.0.1 rule.stratos-local.wso2.com
127.0.0.1 cloudgateway.stratos-local.wso2.com

Step 4- To view the available services you are provided,

./stratos.sh 

To start a services
./stratos.sh start 'service list separated by spaces'

Example: To start ESB Management node and Appserver worker node 
 ./stratos.sh start 'esb_mgt as_worker' 


To start all services
./stratos.sh start all


Please note that you may need super user privileges to start or stop elb as it runs on standard http and https ports. And also please make sure none other services are running on port 443 or 80.(apache, etc)

To stop a services ./stratos.sh stop 'service list separated by spaces'

 Example: To stop ESB Management node and Appserver worker node
 ./stratos.sh stop 'esb_mgt as_worker'

 Note : manager service and elb service should be started first in order to start the Stratos

 ./stratos.sh start manager
sudo ./stratos start elb 

To atop all services
./stratos.sh stop all