Manually Configuring Remote Database with WCS Toolkit

Posted by Unknown on
The default configuration of WCS toolkit in version 7 comes with embedded Apache Derby database, in the older versions of WCS this used to be embedded cloudscape database, to configure your database with a remote database you would run the setdbtype command with the appropriate parameters.

setdbtype.bat oracle C:\oracle\10ghome wcs7 system system1 <username> <password> <DB IP> <DBPORT>

In this blog, I will provide some manual steps through which we can achieve the same configuration as performed by OOTB setdbtype command, although the steps were captured on toolkit, this should almost be the same on server environment as well, with the exception to path for certain configuration files.

Let us assume that you would have used following command if you had used setdbtype.
setdbtype.bat oracle C:\oracle\10ghome wcs7 system system1 wcs7 wcs7 <DB IP> <DBPORT>

Let us try the same through manual configuration.

The first thing we need to do is generate the encrypted password for Oracle "system" and WCS user database accounts.
This can be done by using "wcs_encrypt.bat" command, which is located in <WC_INSTALLDIR>\WCDE_ENT70\bin> folder

Copy the generated encrypted password from the command, example.
C:\IBM\WCDE_ENT70\bin>wcs_encrypt.bat system1
C:\IBM\WCDE_ENT70\bin>wcs_encrypt.bat wcs7

1. Edit the following file, <TOOLKIT_HOME>\WCDE_ENT70\workspace\WC\xml\config\wc-server.xml (in older versions, i.s < WCS 7, this file is located in <TOOLKIT_HOME>\confg\xml\config.xml), this is the instance XML file which we will edit for database configuration.
NOTE:  As a general note always take backup of any WCS configuration file before making any changes.

Look for the section "<Database>" in this XML.

a. Replace DBAName attribute with "system", the default value will be "APP"
b. Replace  DB Password with the encrypted password which you generated using WCS "wcs_encrypt.bat" command for database "system" account, E.g.

c. Replace DBHost with the ipaddress or hostname of your remote database

d. Replace DBMSName as "oracle", assuming your are configuring to a remote Oracle database. E.g

e. Replace DBServerPort with the remote database Listener Port E.g.

f. Replace DBUserID with your database username E.g

g. Replace DBUserPwd with the encrypted password for remote WCS database.

h. Update Remote DB as RemoteDB="true"

i. Update service name with your remote DB service name E.g. ServiceName="wcs7"

j. Update the name attribute with the remote database name, E.g name="wcs7"

The final configuration will appear as shown below,
The highlighted texts were updated.

      <DB CreateDB="true"
        active="true" name="wcs7"/>

2. Look for the XML element "<WebSphere"
The highlighted texts were updated.

      DatasourceName="WebSphere Commerce Oracle DataSource demo"

3. Look for the XML element "DevTools"
The highlighted texts were updated


4. The last step is to update the JDBC datasource for WCS Test environment which is used by the toolkit.

a. Make sure the Toolkit Test server is up and running.
b. Navigate to the WAS admin console , https://localhost:9043/ibm/console/
c. Logon to WAS admin console and navigate to Enterprise Application > WC  and look for "Application Scoped Resources" (hyperlink)

d. Look for a Datasource named "WebSphere Commerce Oracle datasource demo" and click on the link.

e. Update the Datasource helper and Database URL as per your remote database environment, E.g as shown in the screenshot below.

f. We need to additionally update the JAAS and Custom Properties as shown in the screenshot below.
first click on custom properties link and update the databaseName and portNumber properties.
Next click on the JAAS link and update the username and password for WCS user.

Update Custom Properties
Update JAAS Configuration

Save your configuration and restart the server.

Now restart your server and test your application with the remote database.

you can easily revert back the configuration to point to embedded database by executing following command "setdbtype.bat cloudscape", This command will point your toolkit back to the embedded database.

Although you will not perform these steps on a regular basis, but some of the points in this blog will help you to understand the internals of database configuration in WCS.


  1. There is no save option for step e.

  2. how to do step e and f its not editable

  3. ARINET DBA Services is a Chicago, we support to quality and niceness in the services. Options are available for remote dba experts, remote dba services, oracle remote and Oracle Consultants.

  4. It was very nice blog to learn about SAP BASIS. Thanks for sharing.SAP basis

  5. I really appreciate information shared above. It’s of great help. If someone want to learn Online (Virtual) instructor lead live training in TECHNOLOGY , kindly contact us
    MaxMunus Offer World Class Virtual Instructor led training on TECHNOLOGY. We have industry expert trainer. We provide Training Material and Software Support. MaxMunus has successfully conducted 100000+ trainings in India, USA, UK, Australlia, Switzerland, Qatar, Saudi Arabia, Bangladesh, Bahrain and UAE etc.
    For Demo Contact us.
    Saurabh Srivastava
    Skype id: saurabhmaxmunus
    Ph:+91 8553576305 / 080 - 41103383