![]() |
![]() |
Use this command to check whether schedules processed successfully. You can minimize the time it takes to process this query by limiting the output to events whose scheduled start times fall within a date and time range.
The QUERY EVENT command may display information about an event for which there is no event record. For example, if you request information about a scheduled future event, this command will display the status of Future. Future indicates that an event record has not been created for this event. In addition, this command will display the status for past events whose event records have already been removed from the database. In this case, the server returns the status of Uncertain because the server cannot determine the actual event status without the event records.
The command syntax differs for queries that apply to scheduled client operations and to scheduled administrative commands.
Use the QUERY EVENT command to display scheduled and completed events for selected clients.
Tivoli Storage Manager keeps only one version of an event record in the database. If a client schedule is changed, all previous event records for that schedule are removed from the database.
Privilege Class
Any administrator can issue this command.
Syntax
>>-Query EVent--domain_name--schedule_name----------------------> .-Type--=--Client-. >--+-----------------+--+-------------------------+-------------> | .-,---------. | | V | | '-Nodes--=----node_name-+-' .-BEGINDate--=--current_date-. .-BEGINTime--=--00:00-. >--+----------------------------+--+---------------------+------> '-BEGINDate--=--date---------' '-BEGINTime--=--time--' .-ENDDate--=--end_date-. .-ENDTime--=--23:59-. >--+----------------------+--+-------------------+--------------> '-ENDDate--=--date-----' '-ENDTime--=--time--' .-EXceptionsonly--=--No------. >--+----------------------------+-------------------------------> '-EXceptionsonly--=--+-No--+-' '-Yes-' .-Format--=--Standard-----. >--+-------------------------+--------------------------------->< '-Format--=--+-Standard-+-' '-Detailed-'
Parameters
You can specify the data using one of the values below:
You can specify the data using one of the values below:
Value | Description | Example |
---|---|---|
HH:MM:SS | A specific time on the specified begin date | 10:30:08 |
NOW | The current time on the specified begin date | NOW |
NOW+HH:MM or +HH:MM | The current time plus hours and minutes on the specified begin date | NOW+03:00 or +03:00.
If you issue this command at 9:00 to query events scheduled to start 3 hours from now, you can specify either BEGINTIME=NOW+03:00 or BEGINTIME=+03:00. TSM displays events at 12:00 on the specified begin date. |
NOW-HH:MM or -HH:MM | The current time minus hours and minutes on the specified begin date | NOW-04:00 or -04:00.
If you issue this command at 9:00 to query events scheduled to start during the last 4 hours, you can specify either BEGINTIME=NOW-04:00 ENDTIME=NOW or BEGINTIME=-04:00 ENDTIME=NOW. TSM displays events at 5:00 on the specified begin date. |
You can specify the data using one of the values below:
You can specify the data using one of the values below:
Value | Description | Example |
---|---|---|
HH:MM:SS | A specific time on the specified end date | 10:30:08 |
NOW | The current time on the specified end date | NOW |
NOW+HH:MM or +HH:MM | The current time plus hours and minutes on the specified end date | NOW+03:00 or +03:00.
If you issue this command at 9:00 to query events scheduled to start 3 hours from now, you can specify either BEGINTIME=NOW ENDTIME=NOW+03:00 or BEGINTIME=NOW ENDTIME=+03:00. |
NOW-HH:MM or -HH:MM | The current time minus hours and minutes on the specified end date | NOW-04:00 or -04:00 |
Examples
Task 1
Display partial information for all events scheduled for DOMAIN1 that did not execute successfully. Limit the search to the client named JOE. Limit the events displayed to those that were scheduled to occur from February 11, 2001 (02/11/2001) to February 12, 2001 (02/12/2001).
query event domain1 * nodes=joe begindate=02/11/2001 enddate=02/12/2001 exceptionsonly=yes
+--------------------------------------------------------------------------------+ |Scheduled Start Actual Start Schedule Node Status | | Name Name | |-------------------- -------------------- --------- ---- --------- | |02/11/1999 01:00:00 02/11/1999 01:13:55 BACK1 JOE Failed | |02/12/1999 01:00:00 DAILYBKP JOE Missed | +--------------------------------------------------------------------------------+
Task 2
Display complete information for all events scheduled for processing by client JOE in DOMAIN1. Use any time from January 16, 1999 (01/16/1999) through January 17, 1999 (01/17/1999).
query event domain1 * nodes=joe begindate=01/16/1999 enddate=01/17/1999 format=detailed
+--------------------------------------------------------------------------------+ |Policy Domain Name: DOMAIN1 | | Schedule Name: DAILY_BACKUP | | Node Name: JOE | | Scheduled Start: 01/16/1999 01:00:00 | | Actual Start: | | Completed: | | Status: Missed | | Result: 0 | | | |Policy Domain Name: DOMAIN1 | | Schedule Name: DAILY_BACKUP | | Node Name: JOE | | Scheduled Start: 01/16/1999 01:00:00 | | Actual Start: 01/16/1999 01:13:55 | | Completed: 01/16/1999 01:18:27 | | Status: Completed | | Result: 0 | +--------------------------------------------------------------------------------+
where:
Use the QUERY EVENT command to display scheduled and completed events for selected administrative command schedules.
Privilege Class
Any administrator can issue this command.
Syntax
>>-Query EVent--schedule_name--Type--=--Administrative----------> .-BEGINDate--=--current_date-. .-BEGINTime--=--00:00-. >--+----------------------------+--+---------------------+------> '-BEGINDate--=--date---------' '-BEGINTime--=--time--' .-ENDDate--=--begin_date-. .-ENDTime--=--23:59-. >--+------------------------+--+-------------------+------------> '-ENDDate--=--date-------' '-ENDTime--=--time--' .-EXceptionsonly--=--No------. >--+----------------------------+-------------------------------> '-EXceptionsonly--=--+-No--+-' '-Yes-' .-Format--=--Standard-----. >--+-------------------------+--------------------------------->< '-Format--=--+-Standard-+-' '-Detailed-'
Parameters
You can specify the data using one of the values below:
You can specify the data using one of the values below:
Value | Description | Example |
---|---|---|
HH:MM:SS | A specific time on the specified begin date | 10:30:08 |
NOW | The current time on the specified begin date | NOW |
NOW+HH:MM or +HH:MM | The current time plus hours and minutes on the specified begin date | NOW+03:00 or +03:00.
If you issue this command at 9:00 to query events scheduled to start 3 hours from now, you can specify either BEGINTIME=NOW+03:00 or BEGINTIME=+03:00. TSM displays events at 12:00 on the specified begin date. |
NOW-HH:MM or -HH:MM | The current time minus hours and minutes on the specified begin date | NOW-04:00 or -04:00.
If you issue this command at 9:00 to query events scheduled to start during the last 4 hours, you can specify either BEGINTIME=NOW-04:00 ENDTIME=NOW or BEGINTIME=-04:00 ENDTIME=NOW. TSM displays events at 5:00 on the specified begin date. |
You can specify the data using one of the values below:
You can specify the data using one of the values below:
Value | Description | Example |
---|---|---|
HH:MM:SS | A specific time on the specified end date | 10:30:08 |
NOW | The current time on the specified end date | NOW |
NOW+HH:MM or +HH:MM | The current time plus hours and minutes on the specified end date | NOW+03:00 or +03:00.
If you issue this command at 9:00 to query events scheduled to start 3 hours from now, you can specify either BEGINTIME=NOW ENDTIME=NOW+03:00 or BEGINTIME=NOW ENDTIME=+03:00. |
NOW-HH:MM or -HH:MM | The current time minus hours and minutes on the specified end date | NOW-04:00 or -04:00 |
Examples
Task
Display partial information for all events scheduled for an administrative schedule named DOSADMIN. Limit the query to events that are scheduled for March 30, 1999 (03/30/1999).
query event dosadmin type=administrative begindate=03/30/1999 enddate=03/30/1999
+--------------------------------------------------------------------------------+ |Scheduled Start Actual Start Schedule Status | | Name | |-------------------- -------------------- --------- --------- | |03/30/1999 00:00:00 03/30/1999 00:00:01 DOSADMIN Completed | |03/30/1999 04:00:00 03/30/1999 04:00:01 DOSADMIN Completed | |03/30/1999 12:00:00 DOSADMIN Future | |03/30/1999 16:00:00 DOSADMIN Future | +--------------------------------------------------------------------------------+
where:
Table 152. Commands Related to QUERY EVENT
Command | Description |
---|---|
QUERY ACTLOG | Displays messages from the server activity log. |
DELETE EVENT | Deletes event records prior to a specified date and time. |
SET EVENTRETENTION | Specifies the number of days to retain records for scheduled operations. |
SET RANDOMIZE | Specifies the randomization of start times within a window for schedules in client-polling mode. |