Print PRINT
PDF

webMetods step by step Broker Configuration from command prompt


Broker Configuration From The Command Line:

webMethods Broker is a high speed message routing device and is the primary component in the message backbone in a webMethods integration environment.  It facilitates asynchronous, message-based integration using the publish and subscribe model.

A webMethods Broker (7.1.2) installation consists of the following 3 parts:

  • Broker Monitor:  Continually monitors the server’s run state. It automatically attempts to restart a server if it exits unexpectedly. Broker monitor is started by the command S45broker71 start from INSTALL_DIR directory. For each webMethods Broker installation, there is one Broker Monitor instance that monitors all Broker Servers.
  • Broker Server:  Manages the communication, routing and queue storage functions for all the Brokers that it hosts.  A single Broker Monitor can monitor multiple Broker Servers. A Broker server can have multiple Brokers
  • Broker:   A container for document types, client groups, and client state objects. One or many brokers may run on a Broker Server. Multiple Brokers can have a single Broker Server.

Note: All the following commands run from Broker install/bin directory


Create a Broker Server

Create a default Broker Server listening on port 6854 with default values for qs_log_file and qs_storage_file:

./server_config create INSTALL_DIR/data/awbrokers71/default/ -k XXXXXX-XXXXXX-XX-XXXXXX-XXXX-XXXXXX -p 6864

This will produce an output similar to the following:

Using Monitor configuration from "INSTALL_DIR/bin/awbrokermon.cfg".

Creating new Broker Server:

 

Datadir: INSTALL_DIR/data/awbrokers71/default

Executable: INSTALL_DIR/bin/awbroker

 

Port: 6864

License-key: "XXXXXX-XXXXXX-XX-XXXXXX-XXXX-XXXXXX"

 

Description: ""

Since no log file and no storage file were specified for config data, the Broker

 

Server will create a default log and storage file for config data at startup.

Since no log file and no storage file were specified for queue data the Broker Server

 

will create a default log and storage file for queue data at startup.

Triggered Broker Server Monitor to reread configuration.

 

Starting Broker Server (this may take a few moments).

Triggered Broker Server Monitor to start Broker Server.

 

Broker Server on port 6864 is now running.

Successfully created Broker Server in "INSTALL_DIR/data/awbrokers71/default".

A new entry is created in awbroker.cfg (INSTALL_DIR/bin/awbrokermon.cfg):

server-6864.datadir=INSTALL_DIR/data/awbrokers71/default

server-6864.exec=INSTALL_DIR/bin/awbroker

 

server-6864.version=7.1

server-6864.port=6864


To create another Broker Server on port 6870:

./server_config create INSTALL_DIR/data/awbrokers71/server2 -k XXXXXX-XXXXXX-XX-XXXXXX-XXXX-XXXXXX -p 6870

This will create an additional entry in awbroker.cfg:

...

server-6870.datadir=INSTALL_DIR/data/awbrokers71/server2

 

server-6870.exec=INSTALL_DIR/bin/awbroker

server-6870.version=7.1

 

server-6870.port=6870


Listing Broker Servers:

To list Broker Servers using Monitor configuration from “INSTALL_DIR/bin/awbrokermon.cfg”:

./server_config list

This will give the following output:

Using Monitor configuration from "INSTALL_DIR/bin/awbrokermon.cfg".

List of configured servers running on "localhost:6865":

 

1. Datadir: INSTALL_DIR/data/awbrokers71/default

Runstatus: Running

 

Executable: WM_HOME/webm71/Broker/bin/awbroker

Port: 6864

 

Version: 7.1

License-key: "XXXXXX-XXXXXX-XX-XXXXXX-XXXX-XXXXXX"

 

Description: ""

2. Datadir: INSTALL_DIR/data/awbrokers71/server2

 

Runstatus: Running

Executable: INSTALL_DIR/bin/awbroker

 

Port: 6870

Version: 7.1

 

License-key: "XXXXXX-XXXXXX-XX-XXXXXX-XXXX-XXXXXX"

Description: ""


Delete Broker Server:

When a Broker Server is deleted, it also deletes the data directory and updates the awbroker.cfg. For example, the following command deletes ‘server2′ Broker Server:

./server_config delete INSTALL_DIR/data/awbrokers71/server2/ -f

This will produce an output similar to the following:

Using Monitor configuration from "INSTALL_DIR/bin/awbrokermon.cfg".

The Broker Server on port 6870, associated with data directory

 

"INSTALL_DIR/data/awbrokers71/server2" is still running. Attempting to stop Broker Server.

Successfully stopped Broker Server on port 6870.

 

Deleting Broker Server.

Successfully removed Broker Server in

 

"INSTALL_DIR/data/awbrokers71/server2" from the Broker Server Monitor configuration file.

Triggered Broker Server Monitor to reread configuration.

 

Successfully removed Broker Server data directory

"INSTALL_DIR/data/awbrokers71/server2".


Starting Broker Server:

To start a Broker Server on port 6864:

./server_config start -h localhost -monitor_port 6865 -broker_port 6864

-h localhost is redundant as it defaults to localhost if none provided

Output:

Using Monitor configuration from "INSTALL_DIR/bin/awbrokermon.cfg".

The Broker Server at "localhost:6864" is not currently running.

 

Attempting to start it.

Locale character type is C.

 

Using builtin major message catalog.

Successfully started the Broker Server at "localhost:6864".

To confirm:

./server_config list

Output:

Using Monitor configuration from "INSTALL_DIR/bin/awbrokermon.cfg".

List of configured servers running on "localhost:6865":

 

1. Datadir:      INSTALL_DIR/data/awbrokers71/default

     Runstatus:    Running

 

     Executable:   WM_HOME/webm71/Broker/bin/awbroker

     Port:         6864

 

     Version:      7.1

     License-key: "XXXXXX-XXXXXX-XX-XXXXXX-XXXX-XXXXXX"

 

     Description: ""


Stopping Broker Server

To stop a Broker Server running on port 6864:

./server_config stop -h localhost -monitor_port 6865 -broker_port 6864

-h localhost is redundant as it defaults to localhost if none provided

Output:

Using Monitor configuration from "INSTALL_DIR/bin/awbrokermon.cfg".

The Broker Server at "localhost:6864" is currently running.

 

Would you like to stop it (y or Y for yes, no otherwise)?

y

 

Successfully stopped the Broker Server at "localhost:6864".

To confirm:

./server_config list

Result:

Using Monitor configuration from "INSTALL_DIR/bin/awbrokermon.cfg".

List of configured servers running on "localhost:6865":

 

1. Datadir:      INSTALL_DIR/data/awbrokers71/default

     Runstatus:    Stopped

 

     Executable:   INSTALL_DIR/bin/awbroker

     Port:         6864

 

     Version:      7.1

     License-key: "XXXXXX-XXXXXX-XX-XXXXXX-XXXX-XXXXXX"

 

     Description: ""


Create Broker

To create a broker (mywmBroker01) on a Broker Server running on port 6864:

./broker_create mywmBroker01@localhost:6864 -default -description "DEV Broker 01"

To add another broker to the same server:

./broker_create myBroker02@localhost:6864 -description "DEV Broker 02"

Broker Status

To find out the status for the Broker Server running on 6864:

./broker_status localhost:6864

will give an output similar to the following:

Version on Server "localhost:6864" is Version 7.1.2.0.78

091208

 

Status of "myBroker01@localhost:6864"

Territory:

 

Current time 11/12/2010 22:21:21.547

Creation time 10/21/2010 17:13:11

 

Number of clients 80

Number of document types 83

 

Total documents published by broker 0

Total documents published by clients 12

 

Total documents delivered by clients 15

Total documents queued for clients 62

 

brstats.eventLogLength 0

Status of "myBroker02@localhost:6864"

 

Territory:

Current time 11/12/2010 22:21:21.645

 

Creation time 11/12/2010 22:21:16

Number of clients 1

 

Number of document types 31

Total documents published by broker 0

 

Total documents published by clients 0

Total documents delivered by clients 0

 

Total documents queued for clients 0

brstats.eventLogLength 0


Delete Broker

To delete a broker running on ‘localhost’:

./broker_delete myBroker02@localhost:6864

will produce the following output:

Are you sure you want to delete "myBroker02@localhost:6864" (y/n)? y

"myBroker02@localhost:6864" has been deleted.


Ping Broker

To find the health of a broker:

./broker_ping myBroker01@localhost:6879

will produce the following output:

PING myBroker01@localhost:6879

myBroker01@localhost:6879 is alive

 

Similar Blogs:

webMethods step by step broker publish and wa...

webMethods step by step starting Integration ...

Adding a Broker Server to Broker Administrato...

Comments (5)Add Comment
Raj Kumar
...
written by Raj Kumar, July 08, 2013
Hi All,

Please refer SAG guide http://documentation.softwarea...ker/Broker 6.5/webMethods Broker Administrator's Guide 6.5.pdf
Under section: webMethods Broker Command-Line Utilities you find syntax and commands.

I was doing this scenario referring to SAG documentation long time back on win 2003 server with wM 7.1 installation

Best of luck.
Arjun
...
written by Arjun, June 23, 2013
Hi Could you please confirm the broker installation in Windows 8

1 : i tried but its got errored out.
2 : if any one tried please let me know the steps
Curtis Hamm
...
written by Curtis Hamm, June 21, 2013
Is there a way to create providers, connection factories and client groups from the command line? Can you provide some example syntax??
Arjun
...
written by Arjun, June 20, 2013
hi This is Arjun,

1 :Can you give me a tips to configure Broker in Window's.
2 :and Is it possible to install a broker in windows 8?
3 :how to configure cluster env in broker as well as mWS while doing cluster their is 2 things Load balancing and load sharing ? how to do it ?
Arjun
...
written by Arjun, June 19, 2013
hi This is Arjun,

1 :Can you give me a tips to configure Broker in Window's.
2 :and Is it possible to install a broker in windows 8?
3 :how to configure cluster env in broker as well as mWS while doing cluster their is 2 things Load balancing and load sharing ? how to do it ?

Write comment
You must be logged in to post a comment. Please register if you do not have an account yet.

busy