Installing : Installing the UNICOM Digital Transformation Toolkit : Licensing UNICOM Digital Transformation Toolkit : Managing users’ access to licenses : Controlling the number of licenses: Policy file
  
Controlling the number of licenses: Policy file
The license defines the maximum number of concurrent licenses for specific modules that the License Server allows to be used.
In addition, the policy system enables you to specify how module licenses are to be assign. For example, you can limit the number of licenses that an individual user can use.
The policy filename is the same as the license file, plus a filename extension of Policy. For example, if the license is called License.ABC, the policy file is called License.ABC.Policy.
The default location of the named users files is the same directory as the license. To use a policy file in a different directory, see PolicyFilesPath=directorypath.
Defining policy rules
Policy rules can apply to individual users or to hosts (that is, computers that the ULT_Client is on); this is useful for products where ‘thin client’ software runs on different client computers.
Specify the rules in the [Policy Rules] section of the policy file.
A rule specifies the users or hosts to which it applies, followed by the maximum number of modules or categories that they can use.
Specifying the users and hosts
 
To specify
Use
all users
ALL_USERS
all hosts
ALL_HOSTS
individual users
USER[username]
Example:
USER[bob]
individual hosts
HOST[hostname]
Example:
HOST[bob-pc]
groups of users
USER_GROUP[groupname]
Example:
USER_GROUP [Sales]
groups of hosts
HOST_GROUP[groupname]
Example:
HOST_GROUP[London]
Specifying the modules and categories
Use one of these:
MODULE[modulename] SOFT_LIMIT=number
CATEGORY[categoryname] SOFT_LIMIT=number
For example:
ALL_USERS CATEGORY [Floating User] SOFT_LIMIT=2
This example enables users to use a maximum of “Floating User” licenses at once. For information about the SOFT_LIMIT parameter, see Principals that match multiple Rules.
Defining policy user groups and host groups
Define groups of users and hosts in the [Policy Groups] section.
Syntax
DEFINE USER_GROUP[groupname] = username[,username]...
DEFINE HOST_GROUP[groupname] = hostname[,hostname]...
The list of users or hosts can combine individual items and other policy groups that have been defined earlier in the file by using USER_GROUP[<name>] or HOST_GROUP[<name>]
Example
[Policy Groups]
DEFINE USER_GROUP[A] = Alice
DEFINE USER_GROUP[B] = Bob, Julie
DEFINE USER_GROUP[C] = USER_GROUP[A], USER_GROUP[B], Fred
Policy rules can then be defined for USER_GROUP[A] (Alice), USER_GROUP[B] (Bob and Julie), and USER_GROUP[C] (Alice, Bob, Julie, and Fred).
Principals that match multiple Rules
A user or host can have multiple policy rules applied to them. The rules are evaluated in the order in which they are defined in the file; this means that rules later in the file can override the limits specified by earlier rules. For example, you can put an “ALL_USERS” rule near the top to define default restrictions, and then later rules can override this specific subsets of users, such as administrators.
You can control this overriding behavior by using HARD_LIMIT and SOFT_LIMIT rule definitions:
HARD_LIMIT cannot be increased by any later HARD_LIMIT rule, but can be reduced further.
SOFT_LIMIT can be unconditionally overridden (and may be increased) by a later SOFT_LIMIT rule.
Once all rules have been applied (in order), the limit for a user or host for the specified module or category is the lowest of the resulting HARD_LIMIT and SOFT_LIMIT values.
-1 means ‘unlimited’ (up to the limits defined in the License).
Example policy files
Example 1
[Policy Rules]
ALL_USERS CATEGORY [Floating User] SOFT_LIMIT=2
This example enables users to use a maximum of 2 Floating User licenses.
Example 2
[Policy Groups]
DEFINE USER_GROUP[Managers] = Alice, Bob
[Policy Rules]
ALL_USERS CATEGORY [Floating User] SOFT_LIMIT=2
USER_GROUP[Managers] CATEGORY [Floating User] SOFT_LIMIT=10
This extension of Example 1 still limits most users to consuming up to 2 Floating User licenses; however, members of the Managers group (Alice and Bob) can use a maximum of 10 each.
Example 3
[Policy Groups]
DEFINE USER_GROUP[Managers] = Alice, Bob
DEFINE USER_GROUP[Externals] = Bob, Jane
[Policy Rules]
ALL_USERS CATEGORY [Floating User] SOFT_LIMIT=2
USER_GROUP[Externals] CATEGORY [Floating User] HARD_LIMIT=5
USER_GROUP[Managers] CATEGORY [Floating User] SOFT_LIMIT=10
USER[Bob] CATEGORY [Floating User] HARD_LIMIT=50
This extension sets a HARD_LIMIT of 5 for members of the “Externals” user group for the Floating Users Category. When Bob uses the system, his membership of the “Externals” group means he can use only five Floating User licenses, despite having all four of the rules in the example applied to him.
Go up to
Managing users’ access to licenses