Building a Private Cloud with vCloud Director- Part-3-Configuring Database for vCloud Director

In our last 2 posts of this series we understood the components of vCloud suite and had a look on my Lab Infrastructure. Lets move ahead and start configuring vCloud director components one by one.

vCloud Director supports MSSQL and Oracle as backend database. I am using MSSQL database for my Lab and this post will be covering the steps needed to configure the database prior to vCloud Director Installation.

Setting up MSSQL database is very easy task. Vmware provides the SQL commands to configure the database on the vCloud Director Documentation page. You can access this page by clicking on vCloud Director Documentation page.

Pre-requisite: Make sure your system meet following 2 pre-requisites before using the database setup script:

1: MSSQL database installed and running

2: SQL Server Management Studio installed

The below script will be used in configuring the database. You have to make minor changes in the script to setup according to your infrastructure

Note: You may need to change the path of the directory where your SQL server files are located. Mine was located in C: drive so I modified the path to include path up to the DATA directory. Your database file will be saved by name vcloud.mdf in DATA directory.

(“C:Program FilesMicrosoft SQL ServerMSSQL10_50.VIM_SQLEXPMSSQLDATA”)

Also you have to use a password for your vcloud user. In above example i am using svcvcloud as password for my setup. You have to use your own password.

Steps for Executing the script

1) Copy the above script in a notepad and do the necessary modification and save it on your desktop by name filename.sql. For simplicity I saved mine as vcloud.sql

2) Launch SQL Server Management Studio and connect to your database

3) Once the connection is successful go to File> Open > File and browse to the path to your sql file saved in step 1.

vc-db1

I have saved my vcloud.sql file on my desktop

vc-db2

By default when you copy the script from the vCloud documentation page it includes the path to save vcloud.mdf file in C: drive. You have to make changes to reflect it to correct path as I explained earlier.

vc-db3

I changed the path according to my setup so my script looks like below. Make sure to change the database password from default “vcloudpass” to your password.

vc-db4

Once the changes are made you are good to go. Hit the Execute button located just above from where your script starts. If the query is executed successfully it will show you the result in left hand side bottom corner.

vc-db5

Verify the presence of “vcloud” database under section “Databases” and vcloud user under section “Security” by expanding your database instance

vc-db6

You can also verify that vcloud user have been correctly mapped to the vcloud database and has been granted db_owner role by clicking on vcloud database and selecting properties and go to user mapping tab in the new window that pop up.

vc-db7

Now database setup have been setup correctly. In my next post of this series I will cover vCloud director installation on Redhat server.

Leave a Reply