Generating a Central Error Log for Prism / PictureTaker Clients



The information in this article applies to:

• Prism Pack

• PictureTaker

Summary:

Prism Pack’s client (paclient.exe) and PictureTaker's client (PTClient.exe) are designed to keep a log file for each user/workstation where it performs an action. The log file stores information about when the Client was launched and closed, which Pictures were taken, which files were installed and uninstalled, and error messages. The log file in both Prism Pack and PictureTaker is called PICTAKER.LOG. By default it is stored on each workstation. Prism Pack and PictureTaker can be configured to store the log on a server, in a specific directory, with a unique name, etc.

NOTE:
New Boundary Technologies’ flagship product, Prism Deploy, has a deployment console that provides centralized reporting on the status of your deployments.
Prism Deploy’s Console provides immediate feedback on the results of your deployments including:

Quick View: Get a quick overview of the results of the deployment, including the number of targets that successfully received the Task.

Deployment Summary:  Summary information for the computers where the Task was installed successfully, uninstalled, or failed to install.

Deployment Log:  Detailed information on each event that occurred during the deployment for the highlighted targets or Tasks

Alerts:  Errors and other problems that occurred during the deployment for the highlighted targets or Tasks.

If this information is important to you, we encourage you to consider Prism Deploy as a deployment tool for your environment.

When deploying software to a large number of users/workstations (without Prism Deploy), you may still require a means for knowing if any users did not receive the software correctly. Rather than go through each user's log file or wait to get a call from a user, we have designed a way for you to easily determine when a deployment has problems. Our solution involves keeping a central INI file on a server that records the user name and a Prism Pack or PictureTaker error code. Once you are notified that something went wrong, you can view the user's log file to determine the error and find a resolution.

Solution:

We assume you are using Prism Pack scripts to install Packages and are calling them from a network drive. You can define a log file in the Prism script and specify the commands you want completed. You may also add commands to this script that keep track of errors and create a central INI file. Refer to the User's Guide for more detailed information.

Sample Prism/PictureTaker Script
The following is an example of what a script can contain. Notice the additional commands near the bottom of the script.

REM Create log file in user's home directory, 1MB max size, keep diagnostic information
/DefineLogFile h:\prism\pictaker.log /size 1000 /diagnostic

REM Install Office2000 Package located in Prism directory on server
REM Keep track of any Prism errors that may occur
REM If the errorlevel is higher than 3, install Package that documents the error
REM in i:\pictaker\logs\errormsg.ini
/InstallPackage i:\pictaker\apps\office2000.pwc

        /set PTERROR %LASTERROR%

If %LASTERROR% >= 3
        /InstallPackage I:\pictaker\logs\off2000err.pwc
Endif

The key is to create a Package (in our example, off2000err.pwc) that contains a file similar to the following:

Errormsg.ini
[Office2000]
error=%username% %pterror%  %pt_month%%pt_date%%pt_year2% %pt_hour%%pt_minute%

NOTE: The USERNAME variable in the example must be set on the target computer. This variable exists on all NT/2000/XP computers. Windows 9x/Me computers must have this variable defined in the Autoexec.BAT (e.g., SET USER=JULIE), via a Package that defines the username variable based the registry key HKLM\Network\logon,username=,  or through Novell login scripts. For example, a NetWare login script may contain the command:

SET USERNAME = %LOGIN_NAME

The resulting error log file
Since you can have multiple "error=" lines in the resulting INI file (in our example errormsg.ini), you must edit Prism Pack/PictureTaker's RULES.INI file to include the line Key=errormsg.ini,*,error in the [MultiKey] section. If you use names or keys other than "error=", update RULES.INI with the names you will be using. Be sure to edit the appropriate RULES.INI for the copy of paclient/PTClient users are running. If necessary, you can add a line to your Prism/PictureTaker script to /DefineRulesFile and point to a central RULES.INI file on your server. After users have run the script, the resulting Errormsg.ini may look something like this:

[Office2000]
error=Julie 10  090700 0817  (error 10 = a required file did not exist)
error=Pam 8  090800 0815  (error 8 = access to a file was denied)
error=Eric 3  090800 1345  (error 3 = there was not enough disk space to apply file)

The comments are included to document what the error number represents. This information is included in the User's Guide. Once you know which users had which error, you can refer to the individual user's log file for more details, then troubleshoot and fix the problem.

For deploying other applications, build a Package for each application that creates a new section in errormsg.ini. Our example created a section called [Office2000]. Internet Explorer could create a section called [IE5] and a mail application could create the section [MSMail]. You could also configure the Prism/PictureTaker Package to create a different INI file for each application.