Top
Systemwalker Runbook Automation Reference Guide
Systemwalker

1.4.1 swrba_admin (Administration command)

Description

This command enables an administrator to operate following operations without using Web console.

Synopsis

When you register Automated Operation Process Group:

swrba_admin app-add -user User ID -file Bar file

When you update Automated Operation Process Group:

swrba_admin app-update -user User ID -file Bar file

When you register process definition:

swrba_admin pd-add -user User ID -file Process definition file -appid Automated Operation Process Group ID

When you update process definition:

swrba_admin pd-update -user User ID -file Process definition file -appid Automated Operation Process Group ID

When you publish process definition:

swrba_admin pd-publish -user User ID -appid Automated Operation Process Group ID -pdname Process definition name [-version Version of process definition]

When you retrieval process definition:

swrba_admin pd-list -user User ID [-state {draft|published|obsolete}] [-appid Automated Operation Process Group ID] [-pdname Process definition name,... [-namematch {forward|backward}]]

When you start process:

swrba_admin pi-start -user User ID -appid Automated Operation Process Group ID -pdname Process definition name [-version Version of process definition] [-paramfile Parameter file]

When you retrieval process instance:

swrba_admin pi-list -user User ID [-startedafter yyyy-mm-dd] [-startedbefore yyyy-mm-dd] [-state {running|closed|suspended|aborted|created|error}] [-piid Process instance ID] [-pdname Process definition name,... [-namematch {forward|backward}]] [-initiator User ID that started process] [-appid Automated Operation Process Group ID]

When you collect detailed information of process instance:

swrba_admin pi-get -user User ID -d Output directory [-startedafter yyyy-mm-dd] [-startedbefore yyyy-mm-dd] [-state {running|closed|suspended|aborted|created|error}] [-piid Process instance ID] [-pdname Process definition name,... [-namematch {forward|backward}]] [-initiator User ID for starting] [-appid Automated Operation Process Group ID]

When you delete process instance:

swrba_admin pi-delete -user User ID {[-startedafter yyyy-mm-dd] [-startedbefore yyyy-mm-dd] [-state {running|closed|suspended|aborted|created|error}] [-piid Process instance ID] [-pdname Process definition name,... [-namematch {forward|backward}]] [-initiator User ID for starting] [-appid Automated Operation Process Group ID]}

It is also possible to set the password as a parameter by specifying -password. When the password is not set to the parameter, password input is required after execution of this command.

Options

The following options can't be specified at the same time.

app-add

This option registers Automated Operation Process Group.

-file Bar file

Specify the path of the Bar file that is registered. When same name Automated Operation Process Group is exist, this command outputs error. When registration succeeds, Automated Operation Process Group becomes online automatically.

app-update

This option updates Automated Operation Process Group.

-file Bar file

Specify the path of the Bar file that is updated. When the specified Automated Operation Process Group doesn't exist, this command outputs an error.

When the Automated Operation Process Group has been updated, the Automated Operation Process Group becomes off-line, and it becomes impossible to refer to the process definition besides the Automated Operation Process Group owner. When the update finished, the automatic process group becomes on-line automatically.

pd-add

This option registers process definition.

-file Process definition file

This option registers process definition. When the same name process definition exists in the Automated Operation Process Group or the Automated Operation Process Group it doesn't exist, this command outputs an error. Moreover, when you don't specify the automatic process group ID, this command outputs an error.

-appid Automated Operation Process Group ID

Specify the Automated Operation Process Group ID that stores the process definition. When the specified Automated Operation Process Group doesn't exist, this command outputs an error.

pd-update

This command updates process definition.

-file Process definition file

This command updates process definition. When the specified process definition doesn't exist, this command outputs an error. The process definition is registered with state of draft.

Moreover, even if the update of the process definition is completed, the update is not reflected in the process instance that has already started. The update becomes effective from the process started after the publication of the updated process definition.

- appid Automated Operation Process Group ID

Specify the Automated Operation Process Group ID that stores the process definition. When the specified Automated Operation Process Group doesn't exist, this command outputs an error.

pd-publish

This option publishes the process definition.

- appid Automated Operation Process Group ID

Specify the Automated Operation Process Group ID. When the specified Automated Operation Process Group doesn't exist, this command outputs an error.

-pdname Process definition name

Specify the process definition name. When the process definition doesn't exist, this command outputs an error.

-version Version of process definition

Specify the version of process definition. When the version of process definition doesn't exist, this command outputs an error.

When you omit this option, this command publishes the latest version. When you specified the published version, this command outputs an error.

pd-list

This option retrieves process definition and displays it as a list form. When you don't specify any parameter, this command retrieves all process definition. The parameters that can be specified are show below.

-state State of process definition

Specify state of the process definition. When you omit this option, this command retrieves all state. The states that can be specified are shown below.

  • draft : draft state

  • published : published state

  • obsolete : obsolete state

When you specify two or more options, specify it by comma (,) delimitation.

- appid Automated Operation Process Group ID

Specify the Automated Operation Process Group ID.

-pdname Process definition name

Specify the process definition name.

-namematch forward|backward

Specify the retrieval pattern of the process definition name. Select forward agreement or backward agreement. When you specify none, this command retrieves with perfect matching.

pi-start

This option starts process.

-appid Automated Operation Process Group ID

Specify the Automated Operation Process Group ID. When the specified Automated Operation Process Group doesn't exist, this command outputs an error.

-pdname Process definition name

Specify the process definition name. When the process definition doesn't exist, this command outputs an error.

-version Version of process definition

Specify the version of process definition. When the version of process definition doesn't exist, this command outputs an error.

When you omit this option, this command publishes the latest version. When you specified the published version, this command outputs an error.

-paramfile Parameter file

Specify the file name in which the parameter necessary for the starting process is described. Describe the following content in the file.

UDA name =value
...

The description form of the file is a general property file form of Java.

Specify the value for UDA and start the process. When the specified UDA doesn't exist, this command outputs an error. Moreover, The form of the value that can be used is only STRING type. When character-code of the specified file is not UTF-8, this command outputs an error.

You can start the published process definition and the process definition that belong to the user who executed this command.

pi-list

This option retrieves the process instance and displays it by the list form. When you specified none, this command retrieves all process instances. You can specify the parameters that are shown below.

-startedafter Start date

Specify the start date of the period when the process was started. Specify it in the form of the following.

  • yyyy-mm-dd

-startedbefore End date

Specify the end date of the period when the process was started. Specify it in the form of the following.

  • yyyy-mm-dd

When you only specified -startedafter, this command retrieves the period from the specified date to now. When you specified this command outputs the error when the option is specified by a form other than the above and when the relation between the start date and the end date is illegal.

-piid Process instance ID

Specify the process instance ID.

-state State of process definition

Specify the state of process definition. When you don't specify none option, this command retrieves all process definition. The states that can be specified are shown below.

  • running

  • closed

  • suspended

  • aborted

  • created

  • error

When you specify two or more options, specify it by comma (,) delimitation.

- pdname Process definition name

Specify the process definition name. When you specify two or more options, specify it by comma (,) delimitation.

Moreover, you can set the detailed condition by using the following parameter.

-namematch forward|backward

Specify the retrieval pattern of the process definition name. Select forward agreement or backward agreement. When you specify none, this command retrieves with perfect matching.

- appid Automated Operation Process Group ID

Specify the Automated Operation Process Group ID. When the specified Automated Operation Process Group doesn't exist, this command outputs an error.

-initiator User ID that started process

Specify the user ID that started the process. When you specify two or more options, specify it by comma (,) delimitation.

pi-get

This option retrieves the process instance and collects detailed information. When you don't specify parameter, this command retrieves all process instances. The parameters that you can specify are shown below.

-d Output directory

Specify the output directory. The structure and output contents are shown below.

- Automated Operation Process Group ID
    - process instance ID
        - process instance ID.xml   : The file that has the detailed information of process instance
        - attachmentsfiles directory : The directory that stores the files appended to process instance

For more information about the detailed information file for process instance, refer to 2.4 Detailed Information File for Process Instance.

-startedafter Start date

Specify the start date of the period when the process was started. Specify it in the form of the following.

yyyy-mm-dd

-startedbefore End date

Specify the end date of the period when the process was started. Specify it in the form of the following.

yyyy-mm-dd

When you only specified -startedafter, this command retrieves the period from the specified date to now. When you specified this command outputs the error when the option is specified by a form other than the above and when the relation between the start date and the end date is illegal.

-piid Process instance ID

Specify the process instance ID.

-state State of process definition

Specify the state of process definition. When you don't specify none option, this command retrieves all process definition. The states that can be specified are shown below.

  • running

  • closed

  • suspended

  • aborted

  • created

  • error

When you specify two or more options, specify it by comma (,) delimitation.

- pdname Process definition name

Specify the process definition name. When you specify two or more options, specify it by comma (,) delimitation. Moreover, you can set the detailed condition by using the following parameter.

-namematch forward|backward

Specify the retrieval pattern of the process definition name. Select forward agreement or backward agreement. When you specify none, this command retrieves with perfect matching.

- appid Automated Operation Process Group ID

Specify the Automated Operation Process Group ID. When the specified Automated Operation Process Group doesn't exist, this command outputs an error.

-initiator User ID that started process

Specify the user ID that started the process. When you specify two or more options, specify it by comma (,) delimitation.

pi-delete

This option deletes the process instance.

-startedafter Start date

Specify the start date of the period when the process was started. Specify it in the form of the following.

yyyy-mm-dd

-startedbefore End date

Specify the end date of the period when the process was started. Specify it in the form of the following.

yyyy-mm-dd

When you only specified -startedafter, this command retrieves the period from the specified date to now. When you specified this command outputs the error when the option is specified by a form other than the above and when the relation between the start date and the end date is illegal.

-state State of process definition

Specify the state of process definition. When you don't specify none option, this command retrieves all process definition. The states that can be specified are shown below.

  • running

  • closed

  • suspended

  • aborted

  • created

  • error

When you specify two or more options, specify it by comma (,) delimitation.

-piid Process instance ID

Specify the process instance ID.

- pdname Process definition name

Specify the process definition name. When you specify two or more options, specify it by comma (,) delimitation. Moreover, you can set the detailed condition by using the following parameter.

-namematch forward|backward

Specify the retrieval pattern of the process definition name. Select forward agreement or backward agreement. When you specify none, this command retrieves with perfect matching.

- appid Automated Operation Process Group ID

Specify the Automated Operation Process Group ID. When the specified Automated Operation Process Group doesn't exist, this command outputs an error.

-initiator User ID that started process

Specify the user ID that started the process. When you specify two or more options, specify it by comma (,) delimitation.

Return Values

Return Value

Meaning

0

Normal termination

1

Parameter error

2

Attestation error

3

Error on Manager server

4

Internal error

5

Authority error

6

I/O error

Irregularity

Forced ending

Command Location

[Windows]

<Systemwalker Runbook Automation installation directory>\bin
Note: The default location is C:\Fujitsu\Systemwalker\SWRBAM

[Linux]

/opt/FJSVswrbam/bin


Privilege Required/Execution Environment

[Windows]

[Linux]

Note

Execution Result/Output Format

When you newly register the process definition:

FSP_SW/RB-A_BASE: INFO: 02001: pd-add has finished. Option: pd-add file sample0001.xpdl appid app001 Code:0

When you retrieve the process definition:

FSP_SW/RB-A_BASE: INFO: 02000: pd-list is starting. Option:pd-list

ApplicationID ProcessID ProcessDifinitionName VersionStatusOwner
sample001 0001 sample process0011.0published rba_user1
sample002 0002 sample process0021.0published rba_user1
sample002 0001 sample process0031.0published rba_user1

FSP_SW/RB-A_BASE: INFO: 02001: pd-list has finished. Option:pd-list Code:0

When you retrieve the process instance:

FSP_SW/RB-A_BASE: INFO: 02000: pd-list is starting. Option:pd-list

ProcessInstanceID ProcessInstanceNameStatusInitiator
2889PROCESS_cl_1closedibpm_server1
2890PROCESS_cl_1runningibpm_server1
2891PROCESS_cl_1erroribpm_server1

FSP_SW/RB-A_BASE: INFO: 02001: pd-list has finished. Option:pd-list Code:0