Skip to content

Commit cc16c5c

Browse files
committed
Add tutorial to deploy a CICS policy sample
Signed-off-by: Mark Cocker <[email protected]>
1 parent 41b60ae commit cc16c5c

File tree

3 files changed

+61
-3
lines changed

3 files changed

+61
-3
lines changed

docs/_data/sidebars/cdp_sidebar.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ entries:
2323
output: web
2424

2525
- title: Tutorials
26-
url: cdp-Deploying-your-first-nodejs-app.html
26+
url: cdp-Preparing-a-zOS-PT-image.html
2727
output: web
2828
folderitems:
2929
- title: Preparing a z/OS PT image
@@ -35,6 +35,9 @@ entries:
3535
- title: Deploying your first Node.js app
3636
url: cdp-Deploying-your-first-nodejs-app.html
3737
output: web
38+
- title: Deploying a CICS policy
39+
url: cdp-Deploying-a-CICS-policy.html
40+
output: web
3841
- title: Deploying using individual actions
3942
url: cdp-Deploying-using-individual-actions.html
4043
output: web
Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
---
2+
title: Deploying a CICS policy
3+
tags: [tutorial]
4+
keywords:
5+
summary: "The following steps take you through deploying a CICS policy using CICS Explorer."
6+
sidebar: cdp_sidebar
7+
permalink: cdp-Deploying-a-CICS-policy.html
8+
folder: cdp
9+
toc: true
10+
---
11+
12+
[CICS policies](https://www.ibm.com/support/knowledgecenter/en/SSGMCP_5.5.0/fundamentals/policies/policies.html) are used to monitor the state of the CICS region, and the resources and workload in it. A policy consists of rules that define the conditions the required to be met for the rule to trigger, and the action to take when the conditions are met.
13+
14+
This tutorial shows how to download an example CICS policy and deploy it using the CICS deploy plug-in. The policy will result in a CICS message DFHMP3009 being written when the number of active tasks in your CICS regions goes above 90% of your MXT value. This sample is described in article [Using CICS policy system rules to monitor system health](https://developer.ibm.com/cics/2017/07/04/using-cics-policy-system-rules-monitor-system-health/).
15+
16+
### Procedure
17+
18+
1. Install the Zowe CLI and plug-ins by following the steps in [Installing](cdp-Installing).
19+
20+
2. Create Zowe CLI profiles by following the steps in [Creating Zowe CLI profiles](cdp-Creating-Zowe-CLI-profiles).
21+
22+
3. Clone the [cics-policy-samples](https://github.ibm.com/CICS/cics-policy-samples/tree/master) repository.
23+
24+
```text
25+
git clone https://github.ibm.com/CICS/cics-policy-samples.git
26+
27+
cd cics-policy-samples/bundles/CICSDEV_system_rule
28+
```
29+
30+
4. Deploy the CICS bundle into CICS.
31+
32+
```text
33+
zowe cics-deploy push bundle --name Policy --overwrite
34+
```
35+
36+
A progress bar is shown with status messages as the CICS bundle is deployed. This can take a few minutes. The command will summarize the deployment, for example:
37+
38+
<pre class="messageText">
39+
WARNING: No .zosAttributes file found in the bundle directory, default values will be applied.
40+
Regions in scope 'CICPY000' of CICSplex 'ZOSPTINT':
41+
Applid: CICPY000 jobname: CICPY000 jobid: STC47025 sysname: MV2C
42+
PUSH operation completed</pre>
43+
44+
The warning can be ignored as the default values result in the files being uploaded in text that is suitable for this bundle.
45+
46+
The CICS BUNDLE resource named `Policy` is defined, installed, and enabled in CICS. If the BUNDLE `Policy` was already defined or installed in CICS, it is undeployed first. As the BUNDLE is enabled, the policy is also enabled. If there are errors, retry with the `--verbose` option for more detailed output, or refer to [Troubleshooting](cdp-Troubleshooting-General).
47+
48+
### Results
49+
50+
The CICS policy is enabled in the CICS region. When the policy rule is triggered, CICS will write message DFHMP3009 to the CICS region JES job log. See [Log and trace files](cdp-Troubleshooting-General).
51+
52+
To get started with defining your own CICS policy:
53+
* [Download and start the CICS Explorer](https://www.ibm.com/support/knowledgecenter/en/SSSQ3W_5.5.0/com.ibm.cics.core.help/topics/concepts/install_planning_client.html).
54+
* Create a CICS bundle project using the procedure [Creating a CICS bundle project](https://www.ibm.com/support/knowledgecenter/SSSQ3W_5.5.0/com.ibm.cics.core.help/topics/tasks/create_bundle.html).
55+
* Create a policy using the procedure [To create a policy in a CICS bundle project](https://www.ibm.com/support/knowledgecenter/SSSQ3W_5.5.0/com.ibm.cics.core.help/topics/tasks/task_create_policy.html).

docs/pages/cdp/cdp-Provisioning-a-CICS-region.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,10 +80,10 @@ Before you can provision a CICS region, a z/OS PT image needs to be created and
8080

8181
7. Update your Zowe CLI cics-deploy profile to deploy to your CICS region by default.
8282

83-
Update `--scope` to specify the value from DFH_REGION_APPLID, and `--bundle-directory` to specify the `bundles` subdirectory of DFH_REGION_ZFS_DIRECTORY. For example:
83+
Update `--scope` to specify the value from DFH_REGION_APPLID, and `--target-directory` to specify the `bundles` subdirectory of DFH_REGION_ZFS_DIRECTORY. For example:
8484

8585
```console
86-
zowe profiles update cics-deploy cics --scope CICPY000 --bundle-directory "/u/cicprov/mnt/CICPY000/bundles"
86+
zowe profiles update cics-deploy cics --scope CICPY000 --target-directory "/u/cicprov/mnt/CICPY000/bundles"
8787
```
8888

8989
#### Results

0 commit comments

Comments
 (0)