Novell Home

Capturing Windows Registry data in Inventory Database

Novell Cool Solutions: Trench
By Andrew Hill

Digg This - Slashdot This

Posted: 15 Jul 2004
 

Update: Andrew informs us that he has received so many enhancement requests for this popular tool, he has decided to place the source code in Novell Forge where other developers can roll up their sleeves and help make improvements. For the latest version, and to lend a hand yourself, see this Forge project. (Also available from a Forge Red Carpet channel.)


The purpose of this software is to allow capture of Windows registry data in the ZENworks for Desktops inventory database.

1.0 Installation

  1. zRegScan.exe must be copied to the C:\ZENworks directory of all workstations that you wish to scan.
  2. The runtime libraries included in this package may be deployed to the workstations, if they do not exist - these should all be placed in \System32.
  3. The registry keys that you wish to scan must be configured within the registry of each machine, as follows.

Create the following key:
HKEY_LOCAL_MACHINE\Software\Novell\ZENworks\Custom Inventory

Below this key, create a String Value named sequentially starting with "1" for each registry entry you wish to scan.

The format of each value is as follows:

<CIM Attribute Name>,<Hive: LocalMachine or CurrentUser>,<Registry Key Path>,<Registry Value Name>

For example:

1 = CostCenter,LocalMachine,Software\Corporate Settings,CostCenter

2.0 Configuring ZENworks Inventory

Within the Workstation Inventory policy, the following tasks must be completed.

  1. Enable custom scanning
  2. Specify zRegScan.exe as the Custom Scan Executable


  3. Click on the Custom Attribute Editor


  4. Add custom attributes as desired

Note: All custom attributes must be entered under the "Computer System Information" class.

3.0 Operation

Once these steps are completed, zRegScan.exe will be executed during normal inventory scans, and will create and populate the custom.ini file in the C:\ZENworks directory. This file will then be interrogated by the ZENworks inventory scanner and the values will be stored in the inventory database.

To verify that custom inventory information is in the database, right-click on one of the affected workstation objects in ConsoleOne, then choose Actions | Inventory. The custom attributes will be displayed under General | System Identification, as shown below.



The attributes will be updated each time the inventory scanner runs on the workstations.

4.0 Limitations

This release has several limitations:

  • There is very minimal error checking
  • The ZENworks directory (where temporary inventory files are stored) must be on C:
  • Registry items may only be scanned in HKEY_LOCAL_MACHINE and HKEY_CURRENT_USER hives

5.0 Changes

  • 1.4
    • Fixed problem requiring local administrator rights. The key was being erroneously opened as all access instead of read-only.
    • Fixed handling of non-existent and null values - the ZfD inventory scanner does not accept null values. Any non-existent or null value will be replaced with "N/A".

This tool is available for download from Novell Forge http://forge.novell.com/modules/xfmod/project/?zregscan.

If you have any questions you may contact Andrew at anhill@novell.com


Novell Cool Solutions (corporate web communities) are produced by WebWise Solutions. www.webwiseone.com

© 2014 Novell