Hitachi

uCosminexus Application Server Command Reference Guide


cjmsbroker (starting CJMSP Broker)

Organization of this page

Format

cjmsbroker -name instance-name
             -reset store
             -reset messages
             -reset durables
             -remove instance
             -varhome location
             -vmargs argument 1 [[argument 2]...]
             -force
             -h | -help

Function

Starts the CJMSP Broker instance.

Arguments

-name instance-name

Specifies the name of the CJMSP Broker instance to be started. Specify different instance names, when you start multiple CJMSP Broker instances on one host. The default value is cjmsbroker.

The following are the naming rules for instances:

  • You cannot specify reserved device names in the Windows environment.

    Examples:

    AUX, CON, NUL, PRN, COM1- COM9, and LPT1-LPT9

  • You can specify the same number of characters as the maximum number of characters provided by the OS for creating a directory.

  • Combine and specify alphanumeric characters and special characters. However, you cannot use the following special characters in a Windows environment:

    [Figure] / : * ? " < > |

    In a UNIX environment, the characters that you can use depend on the file system specifications.

  • The operations are not guaranteed when you use a backslash (\) or a forward slash (/) in the instance name.

-reset store

Resets the configuration value of the persistence data store. When you reset the configuration value of the persistence data store, all the persistence data in the persistence data store are deleted.

Among the persistence data, if you want to delete only persistence messages, specify the -reset messages option, and if you want to delete only persistence subscribers, specify the -reset durables option.

-reset messages

Deletes only the persistence messages from all the persistence data in the persistence data store.

-reset durables

Deletes only the persistence subscriber from all the persistence data in the persistence data store.

-remove instance

Deletes the persistence data store or any other files and directories under the CJMSP Broker instance. However, the props directory and the log directory are not deleted.

You must note the following points when you use the -remove instance option:

  • Do not start the CJMSP Broker instance that is to be deleted.

  • When you specify the name of a CJMSP Broker instance with the -name option, the specified instance is deleted. Also, when you do not specify the -name option, the default CJMSP Broker instance cjmsbroker is deleted.

  • The cjmsbroker command is used for starting CJMSP Broker instances; however, when you specify the -remove instance option, CJMSP Broker instances are not started.

  • When data is already deleted using the -remove instance command or the repository of the instance file is already deleted, a message Removing instance data is displayed.

-varhome location

Specifies storage destinations of the var directory with absolute path. However, you cannot specify a network path. The default value is <CJMSP_HOME>/var.

For a storage destination, specify a directory that has both read and write permissions. If you specify a directory with only read permission, an error message will be displayed.

Also, if the specified directory does not exist or if you have stopped using the specified directory, create a new directory.

The following are the naming rules for the path to be specified at a storage destination:

  • You cannot specify reserved device names in a Windows environment. If specified, an error message is displayed.

    Examples:

    AUX, CON, NUL, PRN, COM1-COM9, and LPT1-LPT9

  • Combine and specify alphanumeric characters and special characters. However, you cannot use the following special characters in a Windows environment:

    [Figure] / : * ? " < > |

    In a UNIX environment, the characters that you can use depend on the file system specifications. If you use special characters that are not allowed, an error message is displayed.

  • For the path to be specified at the storage destination, follow the syntax rules of the Java standard file.

-vmargs argument

Specifies arguments that are passed to the JavaVM. You can specify the arguments of Java HotSpot VM. For details on specifiable arguments, see 14. Options for Invoking JavaVM in the uCosminexus Application Server Definition Reference Guide. Also, when you specify the -XX:-HitachiOutOfMemoryAbort option, the CJMS provider ignores the -vmargs option.

You can pass the arguments to the JavaVM only from command lines. There are no related setting properties in the configuration file of CJMSP Broker instances.

In the following cases, the entire argument is enclosed with double quotation marks (""):

  • When there is a space in the argument

  • When an equals sign (=) is included in the argument

  • When two or more arguments are specified (arguments are demarcated by space)

Example:
cjmsbroker -vmargs "-Xms256m -Xmx1024m"
  • Xms: Minimum heap size

  • Xmx: Maximum heap size

  • m: Capacity unit (megabytes)

In the above example, the minimum heap size is specified as 256 megabytes and the maximum heap size is specified as 1 gigabyte. The default value of the JavaVM heap size of the CJMSP Broker is 192 megabytes.

-force

Executes operation without a confirmation from the user.

-h | -help

Displays help.

Return values

0:

The command is terminated normally.

1:

The command is terminated abnormally.

Note that when you specify the -remove instance option, the following values are returned as the return value:

10:

The instance to be deleted does not exist.

11:

The instance to be deleted is running.

12:

There is no permission for deleting the instance.

13:

An internal error occurred when deleting the instance.

14:

An I/O error occurred when deleting the instance.

Notes