Chapter 18. Logging results

After your scripts are written, deployed, and executed on a system, you need to know whether the scripts ran successfully. The best way to make this determination is to log the results of the scripts. There are many options for logging script results, and we’ll look at them in this chapter.

Logging results from scripts is a basic technique. Quite often, you will want to store the results of a script. While there are many options for data storage that range in complexity from writing to a database to creating webpages, three techniques are used so often that they should be part and parcel of the IT professional’s scripting toolkit. ...

Get Windows PowerShell Best Practices now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.