Skip Ribbon Commands
Skip to main content
Navigate Up
Sign In

Quick Launch

Average Rating:

facebook Twitter
Email
Print Bookmark Alert me when this article is updated

Feedback

HOW TO: Create a Secure Agent blackout file using the blackout-windows-cli command line utility
Solution
You can configure a blackout period for a Secure Agent to configure specific hours, days, or intervals in which no data integration jobs can run on the agent. To configure a blackout period on a Secure Agent, you must create a blackout file. You can use the blackout-windows-cli command-line utility to create, modify, and validate the blackout file and to test whether a date occurs within a blackout period.

Note: The blackout periods that you define in the blackout file stop the Data Integration Server service from running jobs on a Secure Agent during the blackout period. They do not prevent other types of jobs from running on the agent.

Blackout file structure

The blackout file is an XML file that specifies the repeat frequency, start date, and end date for each blackout period. 

For example, the following blackout file contains two blackout periods: one blackout period from July 27, 2019 5:00 AM through July 28, 2019 11:00 PM and a second blackout period that repeats on Fridays from 2:00-4:00 PM: 

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<BlackoutWindows>
    <BlackoutWindow>
        <RepeatFrequency>OneTime</RepeatFrequency>
        <Start>2019-07-27 5:00:00</Start>
        <End>2019-07-28 23:00:00</End>
    </BlackoutWindow>
    <BlackoutWindow>
        <RepeatFrequency>Friday</RepeatFrequency>
        <Start>14:00:00</Start>
        <End>16:00:00</End>
    </BlackoutWindow>
</BlackoutWindows>

A Secure Agent can have one blackout file. When you create a blackout file, create a file named blackoutWindows.dat in the following directory:
<Secure Agent Installation Directory>\apps\Data_Integration_Server\conf\

You can override the file name and directory by setting the BlackoutWindowFile Tomcat property for the Data Integration Server service of the Secure Agent. For more information about the blackout file, see the "Runtime environments" chapter in the Informatica Intelligent Cloud Services Administrator guide.

Command-line utility
You can create the blackout file manually, or you can use the blackout-windows-cli command line utility to create, modify, and validate the blackout file. You can also use the utility to test whether a date occurs during a blackout period. Request the command line utility from Informatica Global Customer Support. 

Request the following utility based on your operating system:
  • Windows: blackout-windows-cli.bat
  • Unix: blackout-windows-cli.sh
The utility uses the following syntax:

blackout-windows-cli [-a <repeat_frequency>] [-d <period_number>] [-e <end_time>] [-f <file>] [-l] [-s <start_time>] [-t <test_time>] [-v]

The following table lists the options and arguments:

Option

Arguments

Description

-a

repeat_frequency                               

Adds a blackout period and specifies the repeat frequency.

Must be one of the following values:

  • OneTime
  • Daily
  • Weekdays
  • Sunday
  • Monday
  • Tuesday
  • Wednesday
  • Thursday
  • Friday
  • Saturday

For example: -a Onetime

-d

period_number

Deletes the numbered blackout period.

Tip: Use the -l (list) option to find the blackout period number.

For example, the following option and argument deletes the first blackout period in the file:

-d 1

-e

end_time

Blackout period end time in the following format: yyyy-mm-dd hh24:mi:ss

For example:

-e "2019-07-25 10:26:55"

-f

file

File path and file name for the blackout file.

For example:

-f C:\Program Files\Informatica Cloud Secure Agent\apps\Data_Integration_Server\blackoutWindows.dat

-l

n/a

Lists the blackout periods in the file in numerical order.

-s

start_time

Blackout period start time in the following format: yyyy-mm-dd hh24:mi:ss

For example:

-s "2019-08-30 13:45:00"

-t

test_time

Checks whether a test time is within a blackout period. The time value must be in the following format: yyyy-mm-dd hh24:mi:ss

For example:

-t "2019-07-30 09:00:00"

-v

n/a

Verifies whether the blackout file is valid.


Examples
The following examples illustrate how to use the utility.

Adding a blackout period

Use the -a option to add a blackout period. If the blackout file does not exist, the utility creates it. Otherwise, the utility returns the modified contents of the blackout file.

Input:
blackout-windows-cli.bat -f C:\Program Files\Informatica Cloud Secure Agent\apps\Data_Integration_Server\blackoutWindows.dat -a onetime -s "2016-07-20 7:00:00" -e "2016-09-25 18:00:00"

Output:
Window#: 1, RepeatFrequency: OneTime, Start: 2016-07-20 7:00:00, End: 2016-09-25 18:00:00

Adding a blackout period that repeats on Mondays

Use the -a option to add a blackout period and specify the repeat frequency. Use the -s and -e options to specify the start and end dates.

Input:
blackout-windows-cli.bat -f C:\Program Files\Informatica Cloud Secure Agent\apps\Data_Integration_Server\blackoutWindows.dat -a Monday -s "20:00:00" -e "22:00:00"

Output:
Window#: 1, RepeatFrequency: OneTime, Start: 2016-07-20 7:00:00, End: 2016-09-25 18:00:00
Window#: 2, RepeatFrequency: Monday, Start: 20:00:00, End: 22:00:00

Listing all blackout periods

Use the -l option to list the blackout periods in the order in which they appear in the blackout file.

Input:
blackout-windows-cli.bat -f C:\Program Files\Informatica Cloud Secure Agent\apps\Data_Integration_Server\blackoutWindows.dat -l

Output:
Window#: 1, RepeatFrequency: OneTime, Start: 2016-07-20 7:00:00, End: 2016-09-25 18:00:00
Window#: 2, RepeatFrequency: Monday, Start: 20:00:00, End: 22:00:00

Determining whether a specific date and time is within a blackout period

Use the -t option to specify the date and time that you want to check.

Input:
blackout-windows-cli.bat -f C:\Program Files\Informatica Cloud Secure Agent\apps\Data_Integration_Server\blackoutWindows.dat -t "2016-0 9-25 18:00:00"

Output:
The input date [2016-09-25 18:00:00] is in the blackout window. RepeatFrequency: OneTime, Start: 2016-07-20 7:00:00, End: 2016-09-25 18:00:00

Deleting a blackout period 

Use the -d option to delete a blackout period. When you delete a blackout period, the utility returns the modified contents of the blackout file.

Tip: You can retrieve the blackout period number using the -l (list) option.

Input:
blackout-windows-cli.bat -f C:\Program Files\Informatica Cloud Secure Agent\apps\Data_Integration_Server\blackoutWindows.dat -d 2

Output:
Window#: 1, RepeatFrequency: OneTime, Start: 2016-07-20 7:00:00, End: 2016-09-25 18:00:00

Validating the blackout file

Use the -v option to validate the file format and check for​ errors such as a start date that occurs after the end date.

Input:
blackout-windows-cli.bat -f C:\Program Files\Informatica Cloud Secure Agent\apps\Data_Integration_Server\blackoutWindows.dat –v

Output:
Validate successfully

Or:
Failed to process blackout windows CLI. Unparseable date: "2016z-07-20 7:00:00"
More Information
Reference
​​For more information about the blackout file, see the Informatica Intelligent Cloud Services Administrator guide. You can access the Administrator guide from the documentation portal here: https://docs.informatica.com/integration-cloud/cloud-platform/current-version/administrator/preface.html​
Applies To
Product: Cloud Data Integration
Problem Type: Product Feature
User Type: Administrator
Project Phase: Optimize
Product Version: Cloud Data Integration Summer 2019
Database:
Operating System:
Other Software:
Attachments
Last Modified Date:8/9/2019 1:46 AMID:585442
People who viewed this also viewed

Feedback

Did this KB document help you?



What can we do to improve this information (2000 or fewer characters)