A device can specify the interval at which it should start the policy provisioning. Time can be specified in days, hours,
and minutes.
The device starts the policy provisioning by downloading a manifest file from the central server. The central manifest file
manages the policy provisioning for the entire network. This file provides details of the policies to be deployed on hosts,
based on the host name, and EEM version.
Based on the host name or the EEM version, the policy manager decides the next action to be taken. If there are no policies
to be added or removed, no action is taken.
The following is a sample manifest file:
<adploy>
<CommonSection>
<RepositoryURL>tftp://10.106.16.20/folder1/EEM</RepositoryURL>
<StatusLogURL>tftp://10.106.16.20/folder1/EEM</StatusLogURL>
</CommonSection>
<MappingGroups>
<Group>
<Name>GROUP_1</Name>
<Operation>DELETE</Operation>
<FileGroup>FILE_LIST_1</FileGroup>
<DeviceGroup>DEVICE_LIST_1</DeviceGroup>
</Group>
<Group>
<Name>Group_2</Name>
<Operation>DELETE</Operation>
<FileGroup>FILE_LIST_2</FileGroup>
<DeviceGroup>DEVICE_LIST_2</DeviceGroup>
</Group>
</MappingGroups>
<FileGroups>
<FileGroup>
<FilegroupName>FILE_LIST_2</FilegroupName>
<Policies>
<Policy>
<Policy_id>123</Policy_id>
<Type>tcl</Type>
<EnvFilename>A.ENV</EnvFilename>
<PolicyFilename>A.tcl</PolicyFilename>
<PolicyDescription>Description about this Policy</PolicyDescription>
</Policy>
<Policy>
<Policy_id>123</Policy_id>
<Type>mlang</Type>
<EnvFilename>A.ENV</EnvFilename>
<PolicyFilename>A.py</PolicyFilename>
<PolicyDescription>Description about this Policy</PolicyDescription>
</Policy>
</Policies>
</FileGroup>
<FileGroup>
<FilegroupName>FILE_LIST_1</FilegroupName>
<Policies>
<Policy>
<Policy_id>13</Policy_id>
<Type>APPLET</Type>
<EnvFilename>A.ENV</EnvFilename>
<PolicyFilename>APP</PolicyFilename>
<PolicyDescription>Description about this Policy</PolicyDescription>
</Policy>
<Policy>
<Policy_id>15</Policy_id>
<Type>TCL</Type>
<EnvFilename>A.ENV</EnvFilename>
<PolicyFilename>A.tcl</PolicyFilename>
<PolicyDescription>Description about this Policy</PolicyDescription>
</Policy>
</Policies>
</FileGroup>
</FileGroups>
<DeviceGroups>
<DeviceGroup>
<Name>DEVICE_LIST_1</Name>
<InclusionList>4.0</InclusionList>
<ExclusionList>3.0</ExclusionList>
<DeviceListIs>EEM-Version</DeviceListIs>
<DeviceMatchIs>EXACT</DeviceMatchIs>
</DeviceGroup>
<DeviceGroup>
<Name>DEVICE_LIST_2</Name>
<InclusionList>[A-Za-z]$</InclusionList>
<ExclusionList>2147-29</ExclusionList>
<DeviceListIs>HOST-Name</DeviceListIs>
<DeviceMatchIs>REGEX</DeviceMatchIs>
</DeviceGroup>
</DeviceGroups>
</adploy>
Note |
XML tags are case sensitive.
|
Table 1. XML Tags Description
XML Tag
|
Description
|
<RepositoryURL>
|
Location where policies to be configured are stored.
|
<StatusURL>
|
Location where status logs are stored.
|
<Operation>Delete</Operation>
|
Deletes a policy. The value is not case sensitive.
|
<Operation> Add</Operation>
|
Adds a policy. The value is not case sensitive.
|
<Type>TCL|Applet|mlang</Type>
|
Type of policy. For example, whether it a TCL policy, a multi-language (Python) policy or an applet.
|
<InclusionList>
|
Includes the device for provisioning, if it matches the condition specified in the InclusionList.
|
<ExclusionList>
|
Excludes this device for provisioning, if it matches the condition specified in the ExclusionList.
|
<DeviceListIs>Host-Name|EEM-Version</DeviceListIs>
|
Filters the device list based on the host name or the EEM version.
|
<DeviceMatchIs>REGEX | EXACT</DeviceMatchIs>
|
Device exactly matches the specified host name or matches a regular expression. This value is not case-sensitive.
Note
|
Match condition is EXACT match for EEM-version and EXACT/REGEX for Host-Name
|
|
The following are some of the values that you can specify in the XML tags:
-
PolicyFilename: Name of policy file to be provisioned
-
EnvFilename: Name of the environment variable file to be provisioned.
-
EEM-version: The EEM version, the specified version in the tag should be a match. The value is not case-sensitive.
-
FILE_LIST_1: Contains a list of policy files.
Note |
The FILE_LIST_1 can be any user-defined string value. Ensure that the same string is used consistently in other places where
FILE_LIST_1 is referred.
|
-
DEVICE_LIST_1: Selects a device based on this list, if the EEM Version installed on the device is 4.0 not 3.0.
Note |
The DEVICE_LIST_1 can be any user-defined string value. Ensure that the same string is used consistently in other places where
DEVICE_LIST_1 is referred.
|
-
GROUP_1: FILE_LIST_1 should be mapped to DEVICE_LIST_1. If the device matches the DEVICE_LIST_1, based on device group conditions,
policy files in FILE_LIST_1 are provisioned on that particular device. If there is no match, provisioning is not done.
Note |
The GROUP_1 can be any user-defined string value. Ensure that the same string is used consistently in other places where GROUP_1
is referred.
|
The following is a sample applet file:
event manager applet interface_Shutdown
event syslog pattern "Interface FastEthernet1/0, changed state to administratively down"
action 1.0 cli command "show ip interface brief"
exit
Note |
Only one applet per file is allowed.
|