Caché Monitoring Guide - InterSystems Documentation
Caché Monitoring Guide - InterSystems Documentation
Caché Monitoring Guide - InterSystems Documentation
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
Customizing the ^pButtons Utility<br />
set rc=$$addprofile^pButtons("2minrun","A 2-minute run sampling every 10 seconds",10,12)<br />
The next time you run the ^pButtons utility, the list of profiles includes the following profile name and description:<br />
2minrun<br />
A 2-minute run sampling every 10 seconds<br />
Generate Profile<br />
Alternatively, you can quickly generate new profiles (with a meaningful name and description) with the following API<br />
command:<br />
set rc=$$genprofile^pButtons([,])<br />
where ( * ), which is required, must be in the format "hh:mm", "hh:", or mm; and ,<br />
which is optional, is the frequency with which to run each sample.<br />
Note:<br />
The maximum is 24 hours (86400 seconds); if you specify a longer duration, ^pButtons reduces it<br />
to 24 hours. The must be double-quoted only if it contains a colon (:); the colon denotes hours.<br />
The minimum , if specified, is 2 seconds, unless the duration (that is, * ) is less<br />
than one hour, in which case the minimum is 1 second). If you specify an invalid , ^pButtons<br />
increases it to the required minimum. If the is not specified, it defaults to 10 seconds.<br />
For example, to generate a profile named 12hours (with a generated profile name and description) that runs samples every<br />
5 minutes (300 seconds) over 12 hours, enter the following:<br />
set rc=$$genprofile^pButtons("12:",300)<br />
In addition, to generate a profile named 90mins that runs samples every 10 seconds for 90 minutes, enter the following:<br />
set rc=$$genprofile^pButtons(90)<br />
The next time you run the ^pButtons utility, the list of profiles includes the following profile names and descriptions:<br />
12hours<br />
90mins<br />
A 12 hour run sampling every 300 seconds<br />
A 90 minute run sampling every 10 seconds<br />
8.4.3.2 Edit Profiles<br />
You can edit an existing profile (except for the pre-defined “test” profile) with the following API command:<br />
set rc=$$editprofile^pButtons(,,[],[])<br />
where , which is required, must be unique and cannot contain spaces or white-noise characters; ,<br />
which is required, should be meaningful because it displayed in the menu when you run the ^pButtons utility; ,<br />
which is optional, is the time to run each sample, in seconds (in the range of 2 seconds to 300 seconds); and ,<br />
which is optional, is the number of times to run the profile.<br />
Note:<br />
The arguments are positional; if, for example, to edit the argument (and keep the value specified in the<br />
argument), you must include the comma separator, as follows: set<br />
rc=$$editprofile^pButtons("2minrun","A 5-minute run sampling every 30<br />
seconds",,50).<br />
If the duration exceeds 24 hours (86400 seconds), it is automatically reduced to 24 hours.<br />
For example, to modify the 2minrun profile to run a sampling every 30 seconds until it runs 10 samplings (for a total of 300<br />
seconds, or five minutes), enter the following:<br />
set rc=$$editprofile^pButtons("2minrun","A 5-minute run sampling every 30 seconds",30,10)<br />
The next time you run the ^pButtons utility, the list of profiles includes the following profile name and description:<br />
<strong>Caché</strong> <strong>Monitoring</strong> <strong>Guide</strong> 73