Using the Command Line for Performance Graphs
Cstatrpt.exe is a WhatsUp Gold utility that can generate Performance Graphs from the Statistics Log (ST-yyyy-mm-dd.tab files) data. You can invoke cstatrpt from the Windows Command Prompt (MS-DOS prompt). By default, the report is displayed in the Performance Graphs interface. The -x (for Export) argument is the only non-interactive mode (meaning no dialog boxes are displayed). The -x option creates a Performance Graph in HTML format, which you can display in a browser.
Basic Command Syntax
cstatrpt [-mmapname] [-ddevicename] [-Ddateopt][-syyyymmdd] [-eyyyymmdd] [-llogfile] [-osortmode] [-rreport] [-x]
| Argument |
Explanation |
| -mmapname |
The mapname must include the full path. For example, cstatrpt -mC:\Program Files\whatsup\network1.wup. You can enter a complete map name, or enter a partial name. For example, -m*network* will include network1, network2, network3 etc. |
| -ddevicename |
Use -d to specify the name of a device on which to base the report. You can enter a complete device name, or a partial name to include all devices that match the partial name. For example -d*WKS* will include WKS1, WKS2, WKS3, etc. |
| -Ddateopt |
Use -D to specify a recurring time period. wtd - Current week to date td - Today lastw - Last week mtd - Month to date lastm - Last month |
| -syyyymmdd |
Use -s to specify the start date for the report. The default is the oldest date in the log. |
| -eyyyymmdd |
Use -e to specify the end date for the report. The default is the most recent date in the log. |
| -llogfile |
Use -l to specify an alternate log file. The default is wugstatdata.tab. |
| -osortmode |
Use -o to specify one of the sort modes: Ascend sorts by device name in ascending order (this is the default value); Descend sorts by device name in descending order. |
| -rreport |
Use -r to specify one of the report types: Wugstatall.rpt - Comprehensive Report Wugstatdaily.rpt - Daily (Line Chart) Wugstatdow.rpt - Day of the Week (Area Chart) Wugstatdowbar.rpt - Day of the Week (Bar Chart) Wugstatmoy.rpt - Monthly (Area Chart) Wugstatmoybar.rpt - Monthly (Bar Chart) Wugstatdailytext.rpt - Daily Text Report Wugstatavail.rpt - Availability Report Wugstathour.rpt - Hourly Report |
| -x |
Use -x to export the report specified by -r to an HTML file, without running the graphical user interface. The exported file(s) is placed in the WUGWEBDIR\reporttype folder under the WhatsUp top directory. |
| -? |
Use -? to see a summary of argument options. |
Examples
The following examples create performance graphs for the Boston1 map:
Example 1.
cstatrpt -m*Boston1.wup
generates a Comprehensive report for all devices in the Boston1 map for all days in the log (uses defaults, except for the map name).
Example 2.
cstatrpt -m*Boston1.wup -rwugstatdaily.rpt -Dlastm -x
generates a daily report for all devices in the Boston1 map using the last month of log data, and exports the graphs to HTML format (does not display the Performance Graphs interface).