Purpose
Tasks are utility-specific and are executed by the Data Mover agent. From a high-level, perspective, this view identifies tasks using Data Mover's task-related resources, such as agent task slots, load slots, and so forth. From a job-level perspective, it identifies work that is blocking a particular job and how long of a delay before execution.
Syntax
Data Mover XML SchemasParameters
See Parameter Order.
- agent_name
- [Optional] Agent name.
- dm.rest.endpoint
- [Optional] Enter a Data Mover REST server URL to overwrite the default value specified in the commandline.properties file in order to connect to a different REST server (and therefore a different daemon) at runtime.
- frequency
- [Optional] Frequency of status update in seconds.
- job_name
- Example: [Optional] Monitors tasks related to this job.
- security_password
- [Optional] Password for the super user or authorized Viewpoint user.
- security_password_encrypted
- [Optional] Encrypted password for the super user.
- security_username
- [Optional] User ID of the super user or authorized Viewpoint user. The user ID of the super user is dmcl_admin and cannot be changed.
- task_id
- [Optional] Task ID.
- task_status_mode
- [Optional] Lists all tasks with the status mode specified.
Usage Notes
- To stop the task view updates if you supplied a frequency parameter, press the system INTR character (UNIX) or Ctrl+C (Windows).
- The order of XML elements is significant and must be observed.
XML File Example
For the list_tasks command, type datamove list_tasks -f parameters.xml.
The following example shows all queued tasks for job job1 and taskid 123 on agent AgentA, and updates the view every five seconds.
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<dmListTasks xmlns="http://schemas.teradata.com/dataMover/v2009" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://schemas.teradata.com/unity/DataMover.xsd"> <task_status_mode>Q</task_status_mode>
<job_name>job1</job_name>
<task_id>123</task_id>
<agent_name>AgentA</agent_name>
<frequency>5</frequency>
</dmListTasks>
Because all parameters are option for the list_tasks command, the following example shows a minimal XML file.
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<dmListTasks xmlns="http://schemas.teradata.com/dataMover/v2009" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://schemas.teradata.com/unity/DataMover.xsd">
</dmListTasks>
Command Output Example
The following example is an excerpt of the output from the list_tasks command.
Output columns include the following as required or applicable:
- TASK
- JOB NAME
- PRIORITY
- STATUS
- AGENT
- QUEUE
- QUEUE ORDER
- UTILITY
- SRC SYSTEM
- TARGET SYSTEM
- USER POOL
- LAST UPDATE
Security
- The list_tasks command follows the same security checks as the list_jobs command.
- When security is not enabled, a command-line user has permission to run all Data Mover commands, which includes the list_tasks command.
- When security is enabled, a user needs job-level permission (if security is set to job level) and deamon-level read permission to run the list_tasks command.
Error Messages and Other Output
The following error messages cause the Data Mover command-line interface to exit with a failure code of -1:
Message | Description |
---|---|
- task_id: Error: [value] is not numeric. | task_id is specified but cannot be converted to a numeric number. |
- task_status_mode: Error: Invalid task_status_mode: [value]. See list_tasks help for the list of valid options. | task_status_mode is specified but with an incorrect value. |
- frequency: [value] is not an integer, value specified has an invalid format or the value is greater than 2147483647. | A frequency is specified but cannot be converted to an integer. |
- frequency: [value] is not a positive integer. | A frequency is specified but not as a positive integer. |
Error: Active tasks found but not visible due to security restriction. User must have read permission on job to view job's tasks. | Security is enabled and the user supplied does not have permission to view the tasks. |