The StreamBase Command Prompt is a feature of the Windows version of StreamBase.
Recent StreamBase releases provide a link in the Start menu for the StreamBase
n.m Command Prompt, where
the major and minor StreamBase release numbers. This link opens a Windows Command
Prompt session with its environment pre-set for running StreamBase command-line
utilities. On 64-bit StreamBase installations, the installer also provides a link
n.m 64-bit Command Prompt.
The following table summarizes the Windows environment settings set in the StreamBase Command Prompt in recent releases of StreamBase.
|STREAMBASE_HOME||Absolute path to the top-level StreamBase installation directory.|
For 32-bit StreamBase Command Prompts, prepends
For 64-bit StreamBase Command Prompts, prepends
If JAVA_HOME is not set, sets it to
Open a StreamBase Command Prompt with the following command sequence:
→ → →
You can also select the top level of a project folder in the Studio Package Explorer, right-click, and select Open StreamBase Command Prompt Here from the context menu. This opens a StreamBase Command Prompt whose current directory is the selected project's directory in the Studio workspace.
On supported 64-bit Windows platforms, you can install the StreamBase kit for 64-bit Windows, as described in Installing and Running StreamBase on 64-Bit Windows. In this case, the Start menu for your StreamBase release contains an entry for the StreamBase 64-bit Command Prompt, in addition to the regular StreamBase Command Prompt.
The StreamBase 64-bit Command Prompt is a Windows command prompt with
%STREAMBASE_HOME%\bin64 on the PATH in addition to
%STREAMBASE_HOME%\bin. When you run StreamBase Server from the
StreamBase 64-bit Command Prompt, you invoke the 64-bit version of the server.
On 64-bit Windows, if you are configuring your Windows environment with the sb-config command, or you are installing a Windows service with sbd --install-service, then be sure to use the appropriate version of the StreamBase Command Prompt. The 64-bit Command Prompt installs the 64-bit server and configures for the 64-bit environment. The standard StreamBase Command Prompt installs and configures for the 32-bit environment.
If you have only one version of StreamBase installed, you might prefer to have the StreamBase environment set globally, instead of set only in a StreamBase Command Prompt. In this configuration, you could use any Windows Command Prompt session to run StreamBase utilities, and would not be restricted to using the StreamBase Command Prompt. This configuration might be appropriate for a deployment system running a production StreamBase application.
If you have more than one StreamBase installation on the same Windows machine, do not use sb-config to modify your global environment, or use it with caution, as discussed below in More Than One StreamBase Installation.
Use the sb-config utility to add
StreamBase envrionment variables to your global environment, as described in the
reference page sb-config. Use
--setenv option to modify the currently logged-in
Windows user's environment. Use the
--setsysenv option to
modify the environment for all users.
If you have more than one StreamBase installation on the same Windows machine, the use of sb-config and the StreamBase Command Prompt change accordingly. There are two cases, described in the following sections.
Follow these rules if you have, on the same Windows machine, two or more recent StreamBase installations, such as one 6.4 and one 6.5 installation:
Use the StreamBase Command Prompt link in the Start menu of a particular 6.x installation to run StreamBase utilities from that installation. The following example command sequences open two separate StreamBase Command Prompts, each set with the environment from its StreamBase installation.
If you prefer to have a primary StreamBase release installed, and you want to set the global Windows environment for that primary release, then use the sb-config utility with caution.
Be sure to run the correct sb-config utility when using the
--setsysenvoptions. You have one sb-config utility for each installation. Before running sb-config, open a StreamBase Command Prompt for the installation you want to become the primary system default, and verify that you have the intended release with the following command:
If you use sb-config --setsysenv or --setenv to set the global environment for a primary StreamBase release, then thereafter, that release's utilities are available in any standard Windows command session. To use the StreamBase commands for a non-primary installation, you must explicitly open a StreamBase Command Prompt for the non-primary release.
Follow these rules if you have, on the same Windows machine, one StreamBase 3.x installation and one or more StreamBase 5.x or 6.x installation:
Do not use the 5.x or 6.x sb-config utility to modify your machine's global environment. This would overwrite the StreamBase 3.x global environment settings. Once overwritten, they can only be restored by manual edits or by reinstalling StreamBase 3.x.
Use any standard Windows Command Prompt to run utilities from your StreamBase 3.x installation.
Use the StreamBase Command Prompt in your StreamBase 5.x or 6.x installation to run utilities from that installation.
With mixed 3.x and 5.0 or later installations, the StreamBase 3.x
bin directory is still in the PATH, after the 5.x or 6.x
bin directory. This means utilities from 3.x that
do not have matching files in 5.x or 6.x can still be inadvertently run at the
5.x or 6.x StreamBase Command Prompt.
For running most utilities and samples on Windows Vista and Windows 7, you can use the normal StreamBase Command Prompt as installed in the Start menu. However, with User Account Control (UAC) enabled, certain StreamBase commands will fail silently. These include commands that attempt to modify the global environment (sb-config --setenv and --setsysenv), or that attempt to write to the Windows registry (sbd --install-service and --remove-service).
To run such commands on Vista or 7 with UAC enabled, you must run the StreamBase Command Prompt with administrator privileges. Follow these steps:
Click the Windows orb in the lower left corner of the Taskbar.
Click All Programs.
Open the StreamBase n.m folder, where n.m represents your release number.
Right-click the StreamBase Command Prompt entry and select Run as administrator from the context menu.
Click Continue in the resulting User Account Control dialog.
A StreamBase Command Prompt opened with administrator privileges shows the word
Administrator in the title bar, and opens by default in
Windows\system32 directory instead of the
StreamBase installation directory.
To navigate to the StreamBase installation directory, use the following command: