Ivanti Automation powered by RES
Apply Registry Settings
Use the Task Apply Registry Settings to change settings in the system registries of Agent computers.
Careless registry editing can cause irreversible damage! Approach this task with caution, and only after you have made a backup.
- In all fields where the name of a registry key or value needs to be provided, you can copy the name of the relevant key or value from the local computer or from another Agent. This is less error prone than typing it in manually. To copy a key name or value, right-click the relevant (sub)tree and choose Open [key name] to open the window Pick keys/values from registry. Here, you can add keys or values to the Task.
- To add a key with its value, select the (default) name, and click Add.
- To add a key without its value, select the key in the browse tree and click Add.
- In the same window you can also click Connect to browse the registry of another Agent and copy the information from there. To type the name in manually instead of copying it, right-click the (sub)tree in the window Apply Registry Settings and choose New. With either method, ensure that you add not only the key, but also any relevant values.
- To delete a registry key or value, add it to the Task, then right-click and choose Toggle "remove this key and subkeys" or Toggle "remove this value". Keys and values toggled for deletion are marked with . If Delete is selected, the registry key will only be deleted from the settings of the Task, and not from the registry of the Agent when the Task is executed. You can also use Toggle "remove this value" to reset default registry keys to their default value (value not set).
- If the icon is not shown on the key or value, it will not be deleted.
- By default, when a key is deleted from the registry, all its subkeys and values are deleted too, even if they are not shown in the Task window. To set exceptions for a specific key or value, add it to the Task, then right-click it and choose Toggle "remove this key and subkeys" or Toggle "remove this value".
- When importing registry files, Microsoft Windows interprets specific parts differently than Ivanti Automation. This can lead to unexpected results if you use Ivanti Automation to export files that contain deletion exceptions, and then import the file into an external registry server. For predictable results, always use Ivanti Automation to export and import registry settings.
- When importing registry files, choose how the merge should handle keys that exist in both the original registry file and in the file being imported:
- with Replace existing data, the new Registry file overwrites the old one completely.
- with Perform incremental merge with existing data, new keys from the imported file are added, but existing keys are left untouched.
- with Perform differential merge with existing data, only keys that exist in both files are kept. If both files contain the same key with the same value, but with different value data, then the value data from the imported file overwrites the value data of the original.
- To use pattern matching on the name of a registry key, add it to the Task, then right-click and choose Toggle "use pattern matching on keyname". This allows you to perform specific actions with the key, such as adding keys and values to other keys, or removing these keys and values.
How to use pattern matching in the names of registry keys
- Add a new key in the relevant Registry location, and use the relevant wildcard(s) in the name of the key.
- Right-click the key and choose Toggle "use pattern matching on keyname". The selected key is marked with a blue star to indicate that the name will be interpreted according to the pattern matching rules.
Suppose you want to delete all references to locally cached copies of user profiles on a number of Agents. These profiles all start with S-1-5-21 and are all located in HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList.
- Right-click HKEY_LOCAL_MACHINE and click Open HKEY_LOCAL_MACHINE. This opens the window Pick keys/values from registry.
- Browse to the key HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList and click Add.
- Click OK to confirm that the selected key has been added to the Task.
- Click Close to close the window Pick keys/values from registry.
- In the window Apply Registry Settings, right-click the key ProfileList, choose New > Key.
- Type S-1-5-21* as the name of the registry key. Click elsewhere to fix the new name.
- Right-click this key and choose Toggle "use pattern matching on keyname". The selected key is marked with a blue star.
- Right-click the same key and choose Toggle "remove this key and all subkeys". The selected key is marked for removal.
As a result, when you schedule a Job with this Task on a set of Agents, Ivanti Automation will remove all keys that match the pattern and that appear in the registry key HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList, including its subkeys and values.
Suppose you want to set a value for Adobe Acrobat Professional, but there are several versions of that suite in use. By using pattern matching on the name of the registry key name, you can create a registry key that matches all versions. For example, when you create a registry key HKEY_LOCAL_MACHINE\SOFTWARE\Adobe\Adobe Acrobat\*.*\Language, this key matches both HKEY_LOCAL_MACHINE\SOFTWARE\Adobe\Adobe Acrobat\6.0\Language and HKEY_LOCAL_MACHINE\SOFTWARE\Adobe\Adobe Acrobat\7.0\Language.
- Module parameters can replace the names of registry subkeys and values in the Task. Right-click the relevant key or value and choose Replace Key Name with parameter or Replace Value Name with parameter.
- To rename a key, add it to the Task and rename it, so that a duplicate key will be created. If this has been successful, execute another Task in which the original key is deleted.
If you use wildcard characters in the name of registry keys, and do not use the option Toggle "use pattern matching on keyname", the name of the registry key will be interpreted literally. For example, the asterisk (*) will be just an asterisk, not a wildcard character.
Was this article useful?
The topic was:
Not what I expected
Copyright © 2019, Ivanti. All rights reserved.