Skip to main content

Software  >  Rational  >  

Using PurifyPlus to test unmanaged code running as a Windows Service

 Technote (FAQ)
 
Question
How do I use IBM Rational PurifyPlus (Purify, Quantify and PureCoverage) to collect data from an unmanaged code running as a Microsoft Windows Service?
 
Answer
In order to test unmanaged code running as a Microsoft Windows Service, you will need to perform the following steps:
  1. Pre-instrument your application using PurifyPlus. This can be achieved by running the following command:

    > purify /replace=yes /run=no <your_service_app.exe>
    Note: for Quantify or PureCoverage, replace 'purify' with 'quantify' or 'coverage' respectively.

    The option /replace=yes will replace your original executable with the instrumented version and a backup copy is created (your_service_app.exe.Original) and saved in the same directory as the original. The option /run=no instructs PurifyPlus to instrument your executable without running it.
  2. Set your service to be interactive with the Windows desktop. Open the properties of your Service from Control Panel -> Administrative Tools -> Services. Then right-click on the Service and go to Properties. In the "Log On" tab, check the flag "Allow service to interact with desktop". If you do not perform this, you will not see the PurifyPlus Graphical User Interface (GUI) at runtime.
  3. It is recommended that you start the PurifyPlus user interface before starting the Service to guarantee that the results are displayed there. This is due to the fact that some Services are not allowed to start other programs, or it is used in a remote terminal session, or due to various other security restrictions. If you do not start the PurifyPlus user interface, you might be see the following problem:

    "Error 1053: The service did not respond to the start or control request in a timely fashion."

  4. Start your service.

    If you do not see the PurifyPlus user interface after you start your service or have problems with any of the steps above, contact IBM Rational Support.

    For instructions on using PurifyPlus to test managed code that is running as a Windows Service, click here.



Do you need more help?

For additional assistance, contact IBM Rational Customer Support:
Submit a Service Request (SR)

 
 
Cross Reference information
Segment Product Component Platform Version Edition
Software DevelopmentRational PurifyRuntimeWindows7.0
Software DevelopmentRational QuantifyRuntimeWindows7.0
Software DevelopmentRational PureCoverageRuntimeWindows7.0
 
 

Copyright and trademark information
IBM, the IBM logo and ibm.com are trademarks of International Business Machines Corp., registered in many jurisdictions worldwide. Other product and service names might be trademarks of IBM or other companies. A current list of IBM trademarks is available on the Web at "Copyright and trademark information" at www.ibm.com/legal/copytrade.shtml.
Rate this page
Please take a moment to complete this form to help us better serve you.
This material provides me with the information I need.




This material is clear and easy to understand.




Did the information help you to achieve your goal?
What updates, improvements, or related information would you like to see in this document?
Your response will be used to improve our document content. Requests for assistance, if applicable, should be submitted through your normal support channel as we cannot respond from this site.
Input the verification number to submit feedback:
Document information
 Product categories:
 Software
 Software Development
 Software Quality Management
 Rational PurifyPlus
 Runtime
 Operating system(s):
  Windows
 Software version:
  7.0
 Reference #:
  1410004
 IBM Group:
 Software Group
 Modified date:
 2009-11-06

Translate My Page
 
 

Rate this page

Help us improve this page. Your response will be used to improve our document content. Requests for assistance, if applicable, should be submitted through your normal support channel as we cannot respond from this site.