Download as pdf or txt
Download as pdf or txt
You are on page 1of 10

Batch Operation Management

Contents
8.2.2.2.1.1 Batch Operation Management
8.2.2.2.1.1.1 Start Batch Task (BAT)
8.2.2.2.1.1.2 Abort Batch Task (ABT BAT)
8.2.2.2.1.1.3 Query Batch Task Status (CHK BATSTAT)

8.2.2.2.1.1 Batch Operation Management


Function Description
The commands provided in this node are used to manage the tasks for executing MML
commands in batches.

Note
Before enabling the HSS9860 to execute MML commands in batches, compile a batch operation
file in .txt format.

Basic Concepts
Storage location for batch operation files
Before you perform a batch operation on the PGW Web LMT, use the file manager of the PGW
Web LMT to upload the batch operation file to a specified directory on the PGW server.
The specified directory is in \opt\pgw\pgwtmpfile\SYSHLRSN+user name format. In the
directory, SYSHLRSN indicates the System HLR serial number of the HSS9860, and user
name indicates the name of the current PGW Web LMT user. For example, if System HLR
serial number is 1, and the user name is admin, the specified directory is
\opt\pgw\pgwtmpfile\001admin.
To obtain the value of System HLR serial number, you can run LST SYSHLRSN.

 Start Batch Task (BAT)

 Abort Batch Task (ABT BAT)

 Query Batch Task Status (CHK BATSTAT)


Parent topic: System Management

8.2.2.2.1.1.1 Start Batch Task (BAT)


Function
BAT is used to start a batch operation task. Before starting a batch operation task, write the
MML commands to be executed into a file and upload the file to the specified directory. You can
enable either an instantaneous or scheduled batch operation task.

Note
 A batch operation file can contain a maximum of 100,000 MML commands.
 A batch operation task must be performed within 48 hours after it is started.
 If an active/standby PGW switchover occurs during the batch operation, some information in
the batch operation output may be lost.
 A maximum of 10 to 100 batch operation tasks can be performed concurrently, depending on
the number of PGW modules configured.
 If less than 5 PGW modules are configured, a maximum of 10 batch operation tasks can be
performed concurrently.
 If 5 to 50 PGW modules are configured, the maximum number of concurrent batch
operation tasks is twice the number of PGW modules.
 If more than 50 PGW modules are configured, a maximum of 100 batch operation tasks
can be performed concurrently.

Parameters

Parameter Parameter
ID Name Parameter Description

FILE File name This parameter specifies the name of a batch operation file.
A batch operation file is an ANSI-encoded text file, for
example, file.txt, and will be uploaded using the file manager
of the PGW Web LMT to a specified directory.
Value: a string of 1 to 128 characters containing letters,
digits, dots (.), and underscores (_).
No default value
TIME Operation time This parameter specifies the time when a batch operation is
performed.
Value: a string in YYYY&MM&DD&HH&MM&SS format
Default value: the time when this command is executed
Note:
 This parameter is optional. If this parameter is not
specified, the batch operation is performed immediately.
 The start time of the scheduled batch operation task cannot
be within the daylight saving time (DST) offset period.
Otherwise, the scheduled batch operation task may be
delayed.

Example
To enable the HSS9860 to run multiple MML commands at a time, perform the following
operations:
1. Write the MML commands to be executed into the file.txt file and upload the file to the
specified directory on the PGW.

2. Run the BAT command with File name set to file.txt and Operation time set to 2009/06/23
10:00:00.
BAT: FILE="file.txt", TIME=2009&06&23&10&00&00;

Output Description
If BAT is successful, the HSS9860 displays a message indicating that the operation succeeded.

If BAT fails, the HSS9860 displays an error code. Table 1 describes common error codes.

Table 1 Error codes

Error Code Description Cause Recommendation

ERR1009 Parameter The mandatory Specify File name.


missing parameter File name
was not specified.
ERR1005 File not The batch operation Upload the file to the specified directory on the
found file has not been PGW.
uploaded to the
specified directory on
the PGW.
Table 1 Error codes

Error Code Description Cause Recommendation

ERR1004 Invalid The File name or Enter the correct value for that parameter.
parameter Template ID
value parameter has an
invalid value.

Parent topic: Batch Operation Management

8.2.2.2.1.1.2 Abort Batch Task (ABT BAT)


Function
ABT BAT is used to terminate an ongoing or a scheduled batch operation task.

Note
None

Parameters

Parameter Parameter
ID Name Parameter Description

TASKID Batch task ID This parameter identifies the batch operation task to be
terminated. The batch task ID can be obtained using the CHK
BATSTAT command.
Value range: 1-4294967295
No default value

Example
To terminate the batch operation task with ID 56, run the following command:
ABT BAT: TASKID=56;

Output Description
If ABT BAT is successful, the HSS9860 displays a message indicating that the operation
succeeded.
If ABT BAT fails, the HSS9860 displays an error code. Table 1 describes a common error code.

Table 1 Error code

Error Code Description Cause Recommendation

ERR1004 Invalid The Batch task ID Enter the correct value for that parameter.
parameter parameter has an
value invalid value.

Parent topic: Batch Operation Management

8.2.2.2.1.1.3 Query Batch Task Status (CHK


BATSTAT)
Function
CHK BATSTAT is used to query information about batch operation tasks.
 To query the information about all batch operation tasks, do not specify any parameter.
 To query the information about a specific batch operation task, specify Batch task ID, other
parameters, or any combination of these parameters.

Note
Specify both Start time and End time, or neither of them. If both of them are specified, ensure
that Start time is earlier than End time.

Parameters

Parameter Parameter
ID Name Parameter Description

TASKID Batch task ID This parameter identifies the batch operation task to be
queried.
Value range: 1-4294967295
No default value
Note: This parameter is mandatory when Provide details is
set to TRUE.
OPNAME Operator name This parameter specifies the name of an operator.
Value: a string of 1 to 32 alphanumeric characters starting
with a letter.
No default value
BEGINTIME Start time This parameter specifies the time when the batch operation
task starts.
Value: a string in YYYY&MM&DD&HH&MM&SS format
No default value
Note: If you specify Batch task ID, do not specify Start
time or End time. Similarly, if you specify Start time and
End time, do not specify Batch task ID.
ENDTIME End time This parameter specifies the time when the batch operation
task ends.
Value: a string in YYYY&MM&DD&HH&MM&SS format
No default value
Note: If you have specified Start time, you must specify
End time, and do not specify Batch task ID.
STATE Task status This parameter specifies the status of the batch operation task
to be queried.
Value:
 READY: The task is ready for execution.
 RUNNING: The task is running.
 COMPLETED: The task is completed.
 ABORTED: The task is terminated.
No default value
Note: Do not specify Task status together with Batch task
ID.
DETAIL Provide details This parameter specifies whether the HSS9860 displays
details about the task.
Value:
 TRUE: The HSS9860 displays details about the task.
 FALSE: The HSS9860 does not display details about the
task.
Default value: FALSE
Note: If this parameter is set to TRUE, Batch task ID must
be specified.
SAVEAS Name of file for This parameter specifies the name of the file that stores the
saving results query result.
Value: a string of 1 to 20 characters containing letters, digits,
dots (.), and underscores (_).
No default value
Note:
 If only Name of file for saving results is specified, the
query result will be saved in the file but not displayed on
the PGW Web LMT. You can download the file using the
file manager.
 If Name of file for saving results is not specified and
more than 250 records are waiting to be displayed, the
HSS9860 displays the first 250 records.
 If Name of file for saving results is not specified and no
more than 250 records are waiting to be displayed, the
HSS9860 displays all the records.
 If Provide details is set to FALSE, do not specify Name
of file for saving results.
 If both Name of file for saving results and Batch task ID
are specified, set Provide details to TRUE.

Example
1. To query the information about all batch operation tasks, run the following command:
CHK BATSTAT:;
%%CHK BATSTAT:;%%
RETCODE = 0 Operation is successful

TASK ID = 536871010
TASK ID = 536871011
TASK ID = 536871012
TASK ID = 536871106

Total count = 4

There is together 1 report

--- END

2. To query the information about the batch operation task with ID 536871106 but not save the
query result into a file, run the following command:
CHK BATSTAT: TASKID=536871106, DETAIL=FALSE;
%%CHK BATSTAT: TASKID=536871106, DETAIL=FALSE;%%
RETCODE = 0 Operation is successful

<TASK ID> <HLR INDEX> <OPERATOR NAME> <START TIME>


<END TIME> <STATUS> <TOTAL> <SUCCESS> <DB SUCCEED BUT
NETWORK FAIL> <MML CMD>
536871106 1 admin 2013-07-31
09:57:57 2013-07-31 09:57:58 COMPLETED 3 3 0
/*HWHandle=139*/BAT: FILE="file.txt";

Total count = 1

There is together 1 report

--- END

3. To query the information about the batch operation task with ID 536871106 and save the
query result into a file, run the following command:
CHK BATSTAT: TASKID=536871106, DETAIL=TRUE, SAVEAS="file1.txt";
You can download the file using the file manager of the PGW Web LMT. The following
shows example contents of the file:

-------------------------------------------------Glossary Information-----
----------------------------------------------------
<TASKID> <OPERATOR NAME> <START TIME> <END TIME>
<STATUS TOTAL> <SUCCEESS> <DB SUCCEED BUT NETWORK
FAIL> <MML CMD>

536871106 admin 2013-07-31 09:57:57 2013-07-31 09:57:58


COMPLETED 3 3 0
/*HWHandle=139*/BAT: FILE="file.txt";

------------------------------------------------Success/Error/Status
Report --------------------------------------------------
<TIME:2013-07-31 09:57:57> <MML_CMD:LST HLRSN:; > <RESULT: Retcode = 0
SUCCESS0001:Operation is successful >
<TIME:2013-07-31 09:57:57> <MML_CMD:LST CNTRCD:; > <RESULT: Retcode = 0
SUCCESS0001:Operation is successful >
<TIME:2013-07-31 09:57:58> <MML_CMD:LST MAPSERV:; > <RESULT: Retcode = 0
SUCCESS0001:Operation is successful >
<TIME:2013-07-31 09:57:58BATCH_COMPLETED>END

Output Description
If CHK BATSTAT is successful, the HSS9860 displays the command output. Details of some
items in the output have been provided in the above parameter description. Table 1 describes the
output items that are not included in the parameter description.

Table 1 Output Description

Output Item Description

HLR INDEX This parameter indicates the system HLR to which


the operator logs in.
Table 1 Output Description

Output Item Description

DB SUCCEED BUT NETWORK FAIL This parameter indicates the number of MML
commands that successfully update data in the
HSS9860 database but fail to update data on the
network side.

MML CMD This parameter indicates the BAT command that


starts the batch operation task.

If CHK BATSTAT fails, the HSS9860 displays an error code. Table 2 describes common error
codes.

Table 2 Error codes

Error Code Description Cause Recommendation

ERR1004 Invalid A parameter has an Enter the correct value for that parameter.
parameter invalid value.
value
ERR1009 Parameter Possible causes are as Specify parameters again using the following rules:
missing follows:  Specify both Start time and End time, or
 Start time was not neither of them.
specified together  If you set Provide details to TRUE, specify
with End time. Batch task ID.
 Batch task ID  If you specify both Batch task ID and Name of
was not specified file for saving results, set Provide details to
when Provide TRUE.
details was set to
TRUE.
 Provide details
was not set to
TRUE when both
Batch task ID and
Name of file for
saving results
were specified.
ERR1010 Parameter Possible causes are as Specify parameters again using the following rules:
conflict follows:  If you specify Batch task ID, do not specify
 One of the Start Start time, End time, or Task status.
time, End time,  If you set Provide details to FALSE, do not
and Task status specify Name of file for saving results.
parameters was
Table 2 Error codes

Error Code Description Cause Recommendation

specified together
with Batch task
ID.
 Name of file for
saving results was
specified when
Provide details
was set to FALSE.
ERR1026 End End time was earlier Enter the correct Start time and End time.
parameter than Start time.
should be
greater/later
than begin
parameter

Parent topic: Batch Operation Management

You might also like