You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »


CheatSheet for setting up CloudStack Dev environment on Windows

Step 1) Install latest eclipse on windows.

Step 2) Download tomcat 6.0.29

http://archive.apache.org/dist/tomcat/tomcat-6/v6.0.29/bin/apache-tomcat-6.0.29.exe

Step 3) Install cygwin. This will give you a unix like bash shell for your windows.
http://cygwin.com/setup.exe

              -> choose all packages except those for KDE, Games, and the like, when installing cygwin. You will need git at a minimum. It takes a while (~30 mins) for this install to go through depending on n/w bandwidth of the mirror you chose from the list.

              -> ensure that you choose mkisofs and git.

Step 4) Install the downloaded tomcat. While installing, change the path to C:\ and don’t put in any spaces.. you will need to set tomcat_home to that directory in a file inside cloudstack-oss (actually I didn’t need to do this, looks like adding the path to Tomcat\bin\ in PATH, and defining CATALINA_HOME as an env variable in Windows (google it up) was enough.

              -> Leave the port at 8080 and the username/password empty.

              -> JRE will be auto detected. Mine was: C:\Program Files\Java\jre6

Step 5) In a cygwin window, do a git clone of the cloudstack-oss source code into some directory.

              -> create a cloudstack-oss directory, cd into it and fire:

              -> git clone ssh://<username>@git.cloud.com/var/lib/git/cloudstack-oss

Step 6) Edit the file cloudstack-oss/build/override/build-cloud.properties to include a tomcat_home variable:

              -> tomcat_home=C:\Tomcat 6.0

Step 7) Install "mkisofs" in windows if for any reason cygwin’s mkisofs isn’t picked up.

              -> http://svnpenn.blogspot.com/2011/06/mkisofs-for-windows_24.html

Copy over the above exe some place in C:\, and set the PATH env variable for Windows 7 to point to this directory.

Step 8) Install mysql for windows. You cannot install mysql within cygwin anyway, and you wouldn't want to either.

             -> carry out the same steps as for mkisofs. Or, when installing, just check the box that asks whether you want to include mysql bin directory in the PATH.

             -> http://dev.mysql.com/downloads/mysql/5.1.html#winx64

Step 9) If you don't have JDK installed, install it. Note where you're installing it, that would be JAVA_HOME. You will need this for later. Get JDK 1.7 from: http://www.oracle.com/technetwork/java/javase/downloads/jdk-7u2-download-1377129.html

I installed mine under :

C:\Program Files\Java\jdk1.7.0_02\

Step 10) Install ant for Windows. Follow the instructions on this link if you're using Win 7 :

            -> http://madhukaudantha.blogspot.com/2010/06/installing-ant-for-windows-7.html

Step 11) You will need to set a parameter DBROOTPW= in the build/override/replace.properties file. Here is how my file looks –

vijayendra1@sjcwvijayendra1 /cygdrive/c/Users/vijayendra1.CITRITE/My Documents/cloudstack/cloudstack-oss
$ cat build/override/replace.properties
DBUSER=cloud
DBPW=cloud
DBROOTPW=
MSLOG=vmops.log
APISERVERLOG=api.log
DBHOST=localhost
AGENTLOGDIR=logs
AGENTLOG=logs/agent.log
MSMNTDIR=/mnt
COMPONENTS-SPEC=components-premium.xml

vijayendra1@sjcwvijayendra1

Step 12) Issue the following command to build the mgmt server and start it up:

            ant clean-all build-all deploy-server deploydb

            ant debug

Step 13) Open the mgmt server console using http://localhost:8080 and configure it as required.

Step 14) When you make changes to the code, and want to restart the mgmt. server, you should not recreate the mysql database, because that would wipe out the setup. So you make your code changes, and then do –

            ant clean-all build-all deploy-server

            and debug



  • No labels