This topic describes how to create an Action.
Note
To run SQL Actions, runme.sql is required. Before executing the Action, BMC Database Automation automatically replaces GA, GAC and GAD variables that are specified in runme.sql with the value that has been set in the environment by using braces ({}); for example, {GA_DB_NAME}
and {GA_DB_ORACLE_HOME}
. This substitution helps provide easy access to variables that are set in the environment of the SQL script. For more information about environment variables for Actions, see Actions environment variables.
In the General page, populate the following fields, and click Next.
Field | Description |
---|---|
Name | Type a name for this Action. |
Type | Select the type for this Action (Script Action or SQL Action). |
Scope | Select the scope for this Action. |
Description | (Optional) Type a description of this Action. |
Container | Assign the Action to a domain. |
Available To | (Optional) Select the domains to which this Action is available. Only users with permission to perform Action Roles and Capabilities in these domains are able to run this Action. The selected domains appear in the Selected Available Domains field. |
Selected Available Domains | View the available domains based on what you selected in the Available To field. |
Restricted Action | Select the check box to assign this Action as restricted. Only users with Run a Restricted Action capability can run the restricted Action. When selecting this option, the Restricted Action property is displayed in the Action Information section of the Action View page and set to Yes. |
In the Action Execution page, populate the following fields, and click Next.
Field | Description | |
---|---|---|
Action Run As | (For script actions only): Enter the permission level at which the Action runs.
| |
Execution Sequence | Select how multiple Actions are run.
|
|
Rescan Nodes On Completion | (Optional) Select this field to scan the nodes after the Action has completed running. | |
Continue On Error | (Optional) Select this field to allow serial activities to continue to run in the event of a failure. |
In the Availability page, populate the following fields, and click Next.
Field | Description |
---|---|
Available as Pre-Provisioning Script | Select this field to make this Action available as a pre-provisioning script file in the Custom Scripts Configuration page for provisioning activities. The scope of the Action determines availability. See Actions scope and provisioning associations. |
Available as Post-Provisioning Script | Select this field to make this Action available as a post-provisioning script file and final script file (when applicable) in the Custom Scripts Configuration page for provisioning activities. The scope of the Action determines availability. See Actions scope and provisioning associations. |
Appears in scope_type Menu | Select this field to add this Action to the menu for the Grid view associated with the scope selected, by using the information specified in the Menu Name and Menu Option Name fields. For example, if the scope selected for an Action is Oracle Database Instance, the information appears in the menus for Oracle database instances in the Grid view. |
Menu Name | Specify the Action category where this Action appears. You can select an existing category, or create a new one. |
Menu Option Name | Specify the name of this Action as it appears in the specified Action category. |
In the Remediation page, populate the following fields, and click Next.
Field | Description |
---|---|
Is Remediation Action | Select the check box to specify that this is a Remediation Action. When this option is selected the remaining fields in the page display. |
Standards | Select the standard from the menu. |
Remediation Checks | Displays the name of the checks to remediate. If there are no remediation checks, click Add Check and type the name of a check for the selected standard. Click the Remove icon to remove a check. |
(For SQL Actions only) In the Credentials page, select the Credentials Options option button corresponding to one of the following options:
Field | Description |
---|---|
(For DB2): Run as Instance User | Runs the Action using the administrator credentials for the selected database instance. |
Enter Credentials Now | Displays the Credentials section, where you specify the user name and password. |
Require Credentials at Run Time | Requires that you specify the user name and password in the Credentials page when you run the Action. |
In the Application Schema page, populate the following fields, and click Next.
Field | Description |
---|---|
Is Application Schema Action | Select this field if there is an Action associated to this application schema. Selecting the check box enables the remaining fields on the page. |
Container | Select the container domain for the application schema for which this Action is being associated. |
Application Schema | Select the application schema from the selected container. |
Application Schema Relationship | Select the relationship of the application schema:
|
In the Restrictions page, populate the following fields, and click Next.
Field | Description |
---|---|
Is Clustered | Select this field to specify this Action for clustered databases. This field is not displayed for Actions with a scope of Node. |
Application Type | Specify the application type for this Action. This field is displayed only for Actions with a scope of Application or Application Instance. |
Application Major Version | Click Add to specify a restriction to a major version of an application in the field.
|
Application Minor Version | Click Add to specify a restriction to a minor version of an application in the field.
|
scope_type Major Version | Specify the major version of the scope type for this Action. Click Add to open the field for entry, and then enter the version number and click Add to add it to the major version list. This field does not appear for Actions with a scope of Node. |
scope_type Minor Version | Specify the minor version of the scope type for this Action. Click Add to open the field for entry, and then enter the version number and click Add to add it to the minor version list. This field does not appear for Actions with a scope of Node. |
Operating System Alias | Specify the OS aliases for this Action. Click show to open the field for selection, and then select the OS aliases and click to move them to the Selected list box. |
Operating System Architecture | Specify the OS architecture for this Action. Click show to open the field for selection, and then select the OS architecture and click to move it to the Selected list box. |
Operating System Long Name | Specify the OS long name for this Action. Click Add to open the field for entry, and then enter the version number and click Add to add it to the minor version list. |
Operating System Type | Specify the OS types for this Action. Click show to open the field for selection, and then select the OS types and click to move them to the Selected list box. |
In the Action Files page, populate the following fields, and click Next.
Note
BMC Database Automation supports the uploading of zipped content files. The maximum file size supported for a zipped content file is 2 GB.
Field | Description |
---|---|
Content Files | Specify the runme or runme.bat file required for every Action. Click Upload File to locate and upload the runme or runme.bat file and any additional files for this Action. |
Zipped Content Files | Upload multiple content files. To locate and upload a .zip file containing multiple files such as the runme and Action content files, including custom verification checks, click Upload Zip File to locate and upload the .zip file. |
Template Files | Upload template files. To locate and upload one or more Action XML template files for use with this Action, click Upload Template File. |
BMC Database Automation Actions can be used as pre-provisioning and post-provisioning scripts during provisioning operations. When the options for Available as Pre-Provisioning Script and Available as Post-Provisioning Script are selected on the Actions Configuration page, the Actions scope determines the relevant scripts to display on the Custom Scripts Configuration page during provisioning.
Actions Scope | |||||||||
Database type | Wizard | Oracle | SQL Server | Sybase | |||||
Node | Home | DB | DB instance | Member instance | DB | Dataserver/ Dataserver instance | Repserver/ Repserver instance | ||
Oracle | Create cluster | X | X | ||||||
Add node | X | X | |||||||
Remove node | X | X | |||||||
Remove cluster | X | X | |||||||
Create Oracle database | X | X | X | X | |||||
Add instance | X | X | X | X | |||||
Upgrade Oracle database | X | X | X | X | |||||
Remove instance | X | X | X | X | |||||
Remove Oracle database | X | X | X | X | |||||
Create Oracle Home | X | X | |||||||
SQL Server | Create MSSQL instance | X | X | ||||||
Add node to instance | X | X | |||||||
Remove node from instance | X | X | |||||||
Remove MSSQL instance | X | X | |||||||
Create MSSQL database | X | X | X | ||||||
Remove MSSQL database | X | X | X | ||||||
Sybase | Create Dataserver | X | X | ||||||
Remove Dataserver | X | X | |||||||
Create Replication Server | X | X | |||||||
Remove Replication Server | X | X |