Command environment: Windows platforms

Set up the Windows® environment to run WebSphere® Message Broker commands.

On Windows platforms, the components run as services, therefore they do not inherit the environment that is set for the command prompt from which you start them. The components run the mqsiprofile command when they start, which completes the environment initialization.

The mqsiprofile command is located in the directory install_dir\bin.

You must not change the location of the mqsiprofile command, or make user modifications to the command, because it might be replaced if you install service, or an update, to the product.

Start of changeIf you need to run your own settings, add one or more command files called your_file_name.cmd to the directory work_path\common\profiles, where work_path identifies the broker's working directory. End of change

The default working directory is %ALLUSERSPROFILE%\Application Data\IBM\MQSI where %ALLUSERSPROFILE% is the environment variable that defines the system working directory. The default directory is C:\Documents and Settings\All Users\Application Data\IBM\MQSI; the actual value might be different on your computer.

If you are unsure of the broker's work path, enter the following command in a command console:
echo %MQSI_WORKPATH%

When mqsiprofile runs, it automatically calls any additional user-written scripts in this directory.

Two typical reasons for adding scripts are Running with Java 5 and Running database setup scripts.

When you have configured any additional setup, you can use one of the following methods to initialize the runtime environment for components and commands:

  1. If you have only one installation of the runtime product, open a command console by clicking Start > IBM > WebSphere Message Brokers 6.0 > Command Console. The mqsiprofile command initializes the environment and invokes any additional scripts in the common\profiles directory.
  2. If you have one or more installations of the runtime product, open a command prompt window. Locate and run the mqsiprofile.cmd script in the directory in which you installed the appropriate product. The mqsiprofile command initializes the environment and invokes any additional scripts in the common\profiles directory.

Check whether the following conditions apply to your environment:

Running with Java 5

WebSphere Message Broker supplies two versions of Java™, version 1.4.2 and version 5 (also known as version 1.5). Both versions are installed, and all components are configured to run with the default version 1.4.2. Complete the steps below to configure all components on this system to use Java 5 (you cannot make this change for individual components).

  1. To check what level of Java you are currently working with, enter the following command:
    java -fullversion
  2. To upgrade to Java 5, copy the command file mqsijava15.cmd from the directory install_dir\bin to the directory work_path\common\profiles.
  3. Close the current window and open a new window before you run mqsiprofile. If one or more runtime components (broker, Configuration Manager, User Name Server) are active, stop and restart each component to pick up the change.

Running database setup scripts

A broker requires access to a database to maintain operational and state data, and might also require access to user databases from deployed message flows.

When you install a database product on Windows, the relevant settings are typically made to the system environment. However, some database managers provide a profile to perform this setup, or provide details of actions that you must take in their documentation. Always check the database product documentation for environment setup details; the information provided here is for general guidance only.

If a profile is provided for the database that you are using, complete the following steps:

  1. If you can update the profile to provide permanent values for the details that are required (for example, the database server name or the installation directory):
    1. Complete the changes to the database profile.
    2. Copy the profile file to the directory work_path\common\profiles.
  2. If you cannot update the profile permanently, but need to make changes each time, you must run it independently of the mqsiprofile command before you start the component.

When your environment has been set up, see Configuring broker and user databases for information about setting up your databases for use with the broker.

Notices | Trademarks | Downloads | Library | Support | Feedback

Copyright IBM Corporation 1999, 2009Copyright IBM Corporation 1999, 2009.
Last updated : 2009-01-07 15:22:40

an26220_