ari_stark.ansible_oracle_modules.oracle_jobwindow (1.2.1) — module

Manage DBMS_SCHEDULER job windows in Oracle database

| "added in version" 0.8.0 of ari_stark.ansible_oracle_modules"

Authors: Ilmar Kerm, ilmar.kerm@gmail.com, @ilmarkerm

Install collection

Install with ansible-galaxy collection install ari_stark.ansible_oracle_modules:==1.2.1


Add to requirements.yml

  collections:
    - name: ari_stark.ansible_oracle_modules
      version: 1.2.1

Description

Manage DBMS_SCHEDULER job windows in Oracle database

Can be run locally on the controlmachine or on a remote host


Requirements

Usage examples

  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- hosts: localhost
  vars:
    oraclehost: 192.168.56.101
    oracleport: 1521
    oracleservice: orcl
    oracleuser: system
    oraclepassword: oracle
    oracle_env:
      ORACLE_HOME: /usr/lib/oracle/12.1/client64
      LD_LIBRARY_PATH: /usr/lib/oracle/12.1/client64/lib
  tasks:
    - name: job window
      oracle_jobwindow:
        hostname: "{{ oraclehost }}"
        port: "{{ oracleport }}"
        service_name: "{{ oracleservice }}"
        user: "{{ oracleuser }}"
        password: "{{ oraclepassword }}"
        state: enabled
        name: SUNDAY_WINDOW
        interval: freq=daily;byday=SUN;byhour=6;byminute=0; bysecond=0
        comments: Sunday window for maintenance tasks
        duration_hour: 12
        resource_plan: DEFAULT_MAINTENANCE_PLAN
      environment: "{{ oracle_env }}"

Inputs

    
mode:
    choices:
    - normal
    - sysdba
    default: normal
    description:
    - The mode with which to connect to the database
    required: true

name:
    description:
    - Scheduler window name
    required: true

port:
    default: 1521
    description:
    - The listener port number on the host
    required: false

user:
    description:
    - The Oracle user name to connect to the database, must have DBA privilege
    required: false

state:
    choices:
    - enabled
    - disabled
    - absent
    description:
    - If absent then window is dropped, if enabled or disabled then window is created
      at the requested state
    required: true

comments:
    description:
    - Comment about the window
    required: false

hostname:
    default: localhost
    description:
    - The Oracle database host
    required: false

password:
    description:
    - The Oracle user password for 'user'
    required: false

duration_min:
    description:
    - Total window duration in minutes
    required: false
    type: int

service_name:
    description:
    - The database service name to connect to
    required: true

duration_hour:
    description:
    - Total window duration in hours
    required: false
    type: int

resource_plan:
    description:
    - Comment about the window
    required: false

repeat_interval:
    aliases:
    - interval
    description:
    - Window repeat interval using DBMS_SCHEDULER calendaring syntax
    required: true

window_priority:
    aliases:
    - priority
    choices:
    - low
    - high
    default: low
    description:
    - Window priority