Using NS6 Custom Inventory in NS7

Article:HOWTO10489  |  Created: 2009-08-12  |  Updated: 2009-08-12  |  Article URL
Article Type
How To


Using NS6 Custom Inventory in NS7


Many of us have created a good number of custom inventory source files that amounts to a considerable investment of time, energy and cost. It would be a shame to have to duplicate those efforts to recreate the custom inventory in NS7. This document describes how to utilize the NS6 custom inventory scripts on an NS7 server.

Custom Inventory in NS7 is significantly different than in NS6. In fact, the two methods are incompatible. NS6 custom inventory will not run in an NS7 environment as an inventory process. However, by utilizing the data class creation and software management capabilities of NS7, it is possible to continue using the NS6 custom inventory files in an NS7 environment, thus preserving the investment in NS6 custom inventory.

NOTE: The purpose of this article is to give a sneak peak. UI elements, help or label text, may be changed in the interim between now and the release. This article provides no guarantees or promises of what will be delivered in the final release.

Prior to Upgrading to NS7

Before upgrading to NS7, please ensure that the following is done to preserve the NS6 custom inventory files. If you use stand-alone inventory, be sure to complete steps 3 & 4, also.

  1. Backup all the custom inventory scripts (cit, xml, etc.) in the above inventory directories.
  2. Backup all the ini files in the above inventory directories that invoke AeXCustInv.exe. By default, the file naming convention for these files is aexinvsoln*.ini.
  3. Backup all the stand-alone inventory packages in the above inventory directories.
  4. Backup the NSCap\bin\Win32\X86\AeXPkgEditor.exe file.

The directory paths for the custom inventory and related files are:

c:\program files\notification server\nscap\bin\win32\x86
c:\program files\notification server\nscap\bin\win32\x86\inventory solution.

NOTE: It is recommended that all files on the NS6 server in the ...\nscap\bin directory be backed up prior to beginning the NS7 migration and a copy of these files be made accessible for post migration configuration.


Prior to setting up the Software Resource package, ensure that the following prerequisites have been met.

  1. The Java 2 JRE 1.6 for use by certain NS Console screens. (As of this writing, Java JRE 6 Update 11 is available and seems to work fine).
  2. Appropriate interpreters for Perl, Python, VBScript, etc.
  3. The Software Management Solution agent must be installed on each client computer.
  4. The 7.x version of aexinvcollector.exe must exist on the NS7 server. This is installed by default as part of the NS7 installation.
  5. Either migrate the 6.x custom inventory data classes as part of the NS6 to NS7 migration or create new custom inventory data classes in the NS7 system.


Following are the high-level steps to using NS6 custom inventory on an NS7 server:

  1. Create the custom inventory data class in the NS7 console.
  2. Copy 6.x custom inventory source files (cit/xml) to a specific directory on the NS7 server.
  3. Create/modify an INI file with the custom inventory and collector command lines - same format as in NS6.
  4. Create a Software Resource, a package and a command line.
  5. Create a Task to run the NS6 custom inventory.

Create a Custom Inventory Data Class

  1. In the NS7 Console, click Settings, All Settings.
  2. Expand Discovery and Inventory, Inventory Solution and click on Manage Custom Dataclasses.


  3. Click on '* New Dataclass'.
  4. Enter 'User Account' for the name.
  5. Enter a Description. Note: At this time, please do not use any punctuation or special characters in the data class name, i.e., '-', '.', etc. or in the description.
  6. Click 'OK'.


  7. After the screen reloads, highlight the new dataclass and click 'Add attribute'.
  8. For the attribute name, enter "Name".
  9. Leave thedata type as string and maximum size as 50.
  10. In the'Key' drop-down list, select "No". The 'Data required' value will automatically change to "No". Leave this set to "No".
  11. Repeat steps 7, 8, 9 and10 for an attribute named "SID".
  12. Repeat steps 7, 8, 9 and10 for an attribute named, "Disabled".


  13. Check the option to 'Allow multiple rows froma single computer resource'. This is necessary in this example since multiple users can be reported on each computer and each will require a unique row in the database.
  14. Click 'Save changes' at the bottom of the screen.
  15. A completed custom dataclass would appear as shown below.

Copy NS6 Custom Inventory Source Files To A Specific Directory

The NS7 installation creates a package directory for NS6 custom inventory purposes. The path to this directory is:

"\program files\altiris\notification server\nscap\bin\win32\x86\Inventory\Custom Inventory 6.1"

  1. Copy all desired cit, xml and ini files from the NS6 server to this directory on the NS7 server. These files will then be available to the Software Resource process, described below.

This directory contains the following files:

  • AeXInvSoln.exe - Same file as that was provided in 6.1 SP2. This Launches AeXCustInv.exe and AeXNSInvCollector.exe as specified in AeXInvSoln.ini.
  • AeXCustInv.exe - This is a different file than that was provided in 6.1 SP2. It behaves in the similar way that it used to in 6.1 SP2, but have few bugs fixed.
  • AeXNSInvCollector.exe - This is a different file than that was provided in 6.1 SP2. This behaves similar way that it used to in 6.1 SP2 but with the only difference that now it generates the NSEs in the new format that is required for posting inventory to NS 7.0.
  • AeXNSEvent.dll - This is a new file, it was not present in 6.1 SP2. AeXNSInvCollector.exe uses this file for generating the NSEs in new format.
  • AeXInvSoln.ini - Specifies an example of how to launch the AeXCustInv.exe and AeXNSInvCollector.exe.
  • AeXCustInvStd.cit - Sample custom inventory script from 6.1 SP2.

Create or Update Inventory Solution INI Files

In NS6, there were several *.ini files that controlled the inventory processes that were to be ran on client computers. These ini files contained batch type commands, similar to the following

aexauditpls.exe /hidden /output xml
aexcustinv.exe /in .\AeXCustInvStd.cit /out AeXCustInvStd.nsi
aexsnplus.exe /output xml
aexnsinvcollector.exe /hidden /nsctransport /v default /useguid

To run NS6 inventory in NS7, we will need similar *.ini, or batch, files to execute the desired command lines. These files need to be in the same directory as the source cit/xml files, which is: "\program files\altiris\notification server\nscap\bin\win32\x86\Inventory\Custom Inventory 6.1". A sample ini file, named AeXInvSoln.ini, is included in this directory by default.

It is possible to include all desired custom inventory files in a single *.ini file and have a single Software Resource, package, command line and task. More likely, it will be desirable to create multiple *.ini files, one for each custom inventory or set of custom inventory processes, along with a Software Resource, package, command line and task for each.

These updated files should, under normal circumstances, do nothing other than run one or more aexcustinv.exe command lines followed by aexnsinvcollector.exe as the last command in the file. However, it may also be necessary to include custom commands or programs in this *.ini file. In this scenario, it may be necessary to run a 3rd party or custom app to collect data, create output data and have custom inventory gather that data and report it to the Notification Server. Since the *.ini file is essentially a batch file that is executed by the client agent, it is possible to include other pertinent commands in the *.ini file.

A sample *.ini file for an NS7 custom inventory task would look something like this:

aexcustinv.exe /in .\win32_useraccount.xml /out win32_useraccount.nsi
aexnsinvcollector.exe /hidden /nsctransport /v default /useguid

Note: It is good practice to keep the source xml file name and the nsi output file name identical.

Create a Software Resource

A Software Resource is similar to a Software Delivery Package and Program in NS6. It contains the package definition, including the path to the package, and the program definition, including the desired command line.

To create a Software Resource for a custom inventory package, do the following:

  1. In the NS Console, click on 'Manage Software'.
  2. Click on the "Software Catalog" menu item in the left-hand pane.
  3. Click on 'Import'. A new window will popup. (Ignore any warnings about configuring the Software Library. We will not be using the Software Library for this demo.)
  4. In the 'Package Source' drop-down list, select 'Access Package from an existing UNC' from the 'Source' drop-down list.
  5. In the new 'Location' text box, browse to: \\local_NS7_servername\nscap\bin\win32\x86\Inventory\Custom Inventory 6.1.
  6. Click on "Display Location".
  7. Highlight AeXInvSoln.exe.
  8. Click on 'Set Installation File".
  9. Click Next
  10. Select the 'Create a new software resource' radio button.
  11. Enter a name for this package. Note that for this example, the text '- Software Resource' has been appended to facilitate identification later.
  12. Ensure that 'Open software resource for editing when finished' is checked in the lower-left corner of this window.


  13. Click OK. The window will change.

Create a Software Resource Package & Command Line

  1. Leave the 'Properties' tab alone.
  2. Select the "Package" tab.
  3. Notice that the previously named software resource has been added automatically as a package.
  4. In the 'Command Lines' section, highlight the entry named 'Install' with 'aexinvsoln.exe' as the command line.
  5. Click the Edit (pencil) button in that section. A new window will appear.
  6. Enter "Custinv - Win32_UserAccount - CommandLine" in the 'Name' field.
  7. Check 'Command line requires a package'.
  8. Select the package named 'Custinv - Win32_UserAccount - Software Resource' in the 'Package' drop-down list.
  9. In the 'Installation File Type" drop-down list, select 'EXE Software Installation File'.
  10. In the 'Command Type" drop-down list, select 'Custom'.
  11. Change the 'Command Line' to read: "AeXInvSoln.exe /s win32_useraccount". The double-quotes do not appear to be needed so they can be removed for this demo.
  12. Click 'Save changes'.

Create a Job/Task to Run Custom Inventory

Now that the software resource, package and command line have been created, a Software Quick Delivery task can be created and scheduled.

  1. Go to 'Manage', 'Jobs and Tasks'.
  2. If needed, click on the top menu tree entry titled 'Jobs and Tasks' to load the 'Jobs and Tasks Portal'.


  3. Click on 'Create a new job or task' to begin the wizard.
  4. Scroll down toward the bottom and expand the 'Software' menu item, if it is not already expanded.
  5. Click on 'Quick Delivery' in the Software menu item list.
  6. In the new window, change the name and description.
  7. In the 'Software Resource' drop-down list, select 'Browse' and either browse to the custom inventory package or type in the name. It will load for you if you type the name correctly.


  8. Select the correct command line.
  9. Select the correct install package.
  10. Click 'OK'.

    At this point, the screen will refresh and the task will be added to the menu tree. The right-hand screen will load the Software Settings and Task Status screen for this task.

  11. The task can be run immediately using the 'Quick Run' method. Alternatively, it can be scheduled by selecting the 'New Schedule' option in the lower portion of the screen.



If the following error appears while scheduling the quick delivery task, it indicates that the Software Management Solution agent has not been installed on the client computers.


To remedy this:

  1. Go to Actions, Agents/Plug-ins, Rollout Agents/Plug-ins. Alternatively, go to Settings, All Settings.
  2. Drill-down to Agents/Plug-ins, Software, Software Management, <Platform>.
  3. Enable the 'SoftwareManagement Solution Plug-in for <Platform> Install.
  4. Once the clients install the Software Management Solution plug-in, reschedule the task.


win32_useraccount.ini_.txt (134 Bytes)
win32_useraccount.xml_.txt (1 kBytes)

Legacy ID


Article URL

Terms of use for this information are found in Legal Notices