The management of licenses for your DB2®products is done primarily through the License Center within the Control Center of the online interface to the product. From the License Center you can check the license
information, statistics, registered users, and current users for each of the installed products.
When the Control Center cannot be used, the db2licm Licensed Management Tool command performs basic license functions. With this command, you are able to add, remove, list, and modify licenses and policies installed on your local system.
Related reference:
v “db2licm - License Management Tool” in the Command Reference
Environment Variables and the Profile Registry
Environment and registry variables control your database environment.
You can use the Configuration Assistant (db2ca) to configure configuration parameters and registry variables.
Prior to the introduction of the DB2®profile registry, changing your
environment variables on Windows®workstations (for example) required you to change an environment variable and reboot. Now, your environment is controlled, with a few exceptions, by registry variables stored in the DB2 profile registries. Users on UNIX®operating systems with system
administration (SYSADM) authority for a given instance can update registry values for that instance. Windows users do not need SYSADM authority to update registry variables. Use the db2set command to update registry
variables without rebooting; this information is stored immediately in the profile registries. The DB2 registry applies the updated information to DB2 server instances and DB2 applications started after the changes are made.
When updating the registry, changes do not affect the currently running DB2 applications or users. Applications started following the update use the new values.
Note: There are DB2 environment variablesDB2INSTANCE, and DB2NODE which may not be stored in the DB2 profile registries. On some operating systems the set command must be used in order to update these environment variables. These changes are in effect until the next time the system is rebooted. On UNIX platforms, the export command may be used instead of the set command.
Using the profile registry allows for centralized control of the environment variables. Different levels of support are now provided through the different profiles. Remote administration of the environment variables is also available when using the DB2 Administration Server.
There are four profile registries:
v The DB2 Instance Level Profile Registry. The majority of the DB2 environment variables are placed within this registry. The environment variable settings for a particular instance are kept in this registry. Values defined in this level override their settings in the global level.
v The DB2 Global Level Profile Registry. If an environment variable is not set for a particular instance, this registry is used. This registry has the
machine-wide environment variable settings. In DB2 UDB ESE, one global-level profile exists at each machine.
v The DB2 Instance Node Level Profile Registry. This registry level contains variable settings that are specific to a partition (node) in a multi-partition environment. Values defined in this level override their settings at the instance and global levels.
v The DB2 Instance Profile Registry. This registry contains a list of all instance names recognized by this system. You can see the complete list of all the instances available on the system by runningdb2ilist.
DB2 configures the operating environment by checking for registry values and environment variables and resolving them in the following order:
1. Environment variables set with theset command. (Or the export command on UNIX platforms.)
2. Registry values set with the instance node level profile (using the db2set -i
<instance name> <nodenum>command).
3. Registry values set with the instance level profile (using the db2set -i command).
4. Registry values set with the global level profile (using the db2set -g command).
Related concepts:
v “DB2 registry and environment variables” in the Administration Guide:
Performance
Related tasks:
v “Declaring registry and environment variables” on page 32
Declaring registry and environment variables
Procedure:
The db2set command supports the local declaration of the registry variables (and environment variables).
To display help information for the command, use:
db2set?
To list the complete set of all supported registry variables, use:
db2set-lr
To list all defined registry variables for the current or default instance, use:
db2set
To list all defined registry variables in the profile registry, use:
db2set-all
To show the value of a registry variable in the current or default instance, use:
db2set registry_variable_name
To show the value of a registry variable at all levels, use:
db2set registry_variable_name -all
To change a registry variable for in the current or default instance, use:
db2set registry_variable_name=new_value
To change a registry variable default for all databases in the instance, use:
db2set registry_variable_name=new_value -i instance_name
To change a registry variable default for a particular partition in an instance, use:
db2set registry_variable_name=new_value -i instance_name node_number
To change a registry variable default for all instances in the system, use:
db2set registry_variable_name=new_value -g
If you user the Lightweight Directory Access Protocol (LDAP), you can set registry variables in LDAP using:
v To set registry variables at the user level within LDAP, use:
db2set-ul
v To set registry variables at the global level within LDAP, use:
db2set-gl user_name
When running in an LDAP environment, it is possible to set a DB2 registry variable value in LDAP such that its scope is global to all machines and all users that belong to a directory partition or to a Windows NT domain.
Currently, the only DB2 registry variable that can be set at the LDAP global level is DB2LDAP_SEARCH_SCOPE.
To set the search scope value at the global level in LDAP, use:
db2set-gl db2ldap_search_scope = value
where the value can be “local”, “domain”, or “global”.
Notes:
1. There is a difference between the -g option which is used to set DB2 registry variables at the machine global level and the-gl which is specific to the LDAP global level.
2. The user level registry variable is only supported on Windows when running in an LDAP environment.
3. Variable settings at the user level contains user specific variable settings.
Any changes to the user level are written to the LDAP directory.
4. The parameters “-i”, “-g”, “-gl”, and “-ul” cannot be used at the same time in the same command.
5. Some variables will always default to the global level profile. They cannot be set at the instance or node level profiles; for example, DB2SYSTEM and DB2INSTDEF.
6. On UNIX, you must have system administration (SYSADM) authority to change registry values for an instance. Only users with root authority can change parameters in global-level registries.
To reset a registry variable for an instance back to the default found in the Global Profile Registry, use:
db2set-r registry_variable_name
To reset a registry variable for a node in an instance back to the default found in the Global Profile Registry, use:
db2set-r registry_variable_name node_number
To delete a variable’s value at a specified level, you can use the same
command syntax to set the variable but specify nothing for the variable value.
For example, to delete the variable’s setting at the node level, enter:
db2set registry_variable_name= -i instance_name node_number
To delete a variable’s value and to restrict its use, if it is defined at a higher profile level, enter:
db2set registry_variable_name= -null instance_name
This command will delete the setting for the parameter you specify and restrict high level profiles from changing this variable’s value (in this case, DB2 global-level profile). However, the variable you specify could still be set by a lower level profile (in this case, the DB2 node-level profile).
Related concepts:
v “DB2 registry and environment variables” in the Administration Guide:
Performance
Related tasks:
v “Setting environment variables on Windows” on page 34 v “Setting environment variables on UNIX systems” on page 37 v “Searching the LDAP directory partitions or domains” on page 331
v “Setting DB2 registry variables at the user level in the LDAP environment”
on page 334