lunacm hsm commands

lunacm hsm monitor Command

NAME

hsm monitor         Sample the HSM for statistics.

SYNOPSIS

lunash:> hsm information monitor [-slot <integer>] [-interval <integer>] [-rounds <integer>] [-noheader] [-save]

DESCRIPTION

Sample the HSM to get some statistics, such as, HSM up-time, command counts, and utilization counters.


A single run of this command, without arguments, takes approximately five seconds to complete. One measurement is taken at launch, then after five seconds (the default minimum) a second measurement is taken and compared with the first.

The date and time in the output are derived from:

  1. the system time and
  2. the HSM count of seconds since reset.

"B" is quite accurate; "A" less so.

In the examples, note the line "HSM Last Reset (+/- 5 Error Margin)..." That margin is due to possible variability of the default system clock. To improve the accuracy of the input to those calculations, we suggest that you use NTP for system time.

 

OPTIONS

(Option)             Parameter                      Description
.....................................................................................
-serial          -se       <integer>                HSM Serial Number
-interval        -i        <integer>                Polling interval to the HSM (5-999)
-rounds          -r        <integer>                Number of samples to collect (1-65535)
-noheader        -n        .                        Omit Header and Footer
-save            -sa       .                        Save Output to a File

-slot <slotnumber> [optional] This parameter is optional if your host does not have additional HSMs attached. If you have a USB-connected HSM, such as Luna G5 for PKI, then the hsm information monitor command defaults to showing utilization data from the embedded HSM, but the serial parameter allows you to select an HSM other than the default. Data is collected for a single HSM when the command is run.

-interval <integer> [optional] This parameter sets the interval over which the HSM is polled. The default is 5 seconds.   The maximum interval is 999 seconds.

-rounds <integer> [optional] This parameter sets the number of samples to collect during the HSM polling. The default is a single round, which includes a first sample at the time the command is launched, followed by the interval (either the default 5 seconds, or the interval that you specified), followed by a second sample which is compared with the first, to complete the round.   The maximum number of rounds for one operation of hsm information monitor is 65535.

-noheader [optional] This parameter turns off the header and footer that are normally provided with the displayed or saved records. You might choose to omit the header and footer in a saved file, in order to make the file cleaner for concatenation and parsing by your analysis tools.

-save [optional] This parameter sends the captured-and-calculated records to a file "hsm_stats", while also displaying the output to your terminal. The filename is not modifiable, so contents are overwritten each time the command is run. Use 'scp' to retrieve the file to a workstation for analysis.

For ongoing/continual collection of such HSM information, we recommend using SNMP.

SAMPLE OUTPUT

With no arguments (output to terminal):

 [mysa5] lunash:>hsm information monitor

-------------------|---------------------------------|---------------------------------
                   |       HSM Command Counts        |        HSM Utilization (%)
 HSM Uptime (Secs) |-----------------|---------------|-----------------|---------------
                   | Since HSM Reset | Last   5 Secs | Since HSM Reset | Last   5 Secs
-------------------|-----------------|---------------|-----------------|---------------
         1,115,399 |      57,468,854 |            30 |            1.27 |          0.21
-------------------|-----------------|---------------|-----------------|---------------

    Average HSM Utilization In This Period  :  0.21%
    HSM Last Reset (+/-5 Secs Error Margin) :  Fri May 31 14:59:47 2013

Command Result : 0 (Success)
[mysa5] lunash:>
  

  With arguments (output to terminal):

 [local_host] lunash:>hsm information monitor -interval 6 -rounds 6

-------------------|---------------------------------|---------------------------------
                   |       HSM Command Counts        |        HSM Utilization (%)
 HSM Uptime (Secs) |-----------------|---------------|-----------------|---------------
                   | Since HSM Reset | Last   6 Secs | Since HSM Reset | Last   6 Secs
-------------------|-----------------|---------------|-----------------|---------------
         1,116,668 |      57,470,863 |             1 |            1.27 |          0.00
         1,116,674 |      57,470,864 |             1 |            1.27 |          0.00
         1,116,680 |      57,470,894 |            30 |            1.27 |          0.18
         1,116,686 |      57,470,895 |             1 |            1.27 |          0.00
         1,116,692 |      57,470,896 |             1 |            1.27 |          0.00
         1,116,698 |      57,470,926 |            30 |            1.27 |          0.18
-------------------|-----------------|---------------|-----------------|---------------

    Average HSM Utilization In This Period  :  0.06%
    HSM Last Reset (+/-5 Secs Error Margin) :  Fri May 31 14:59:46 2013

Command Result : 0 (Success)
[local_host] lunash:>
 

 

  With arguments (output to file):

 [local_host] lunash:>hsm information monitor -interval 6 -rounds 6 -save

-------------------|---------------------------------|---------------------------------
                   |       HSM Command Counts        |        HSM Utilization (%)
 HSM Uptime (Secs) |-----------------|---------------|-----------------|---------------
                   | Since HSM Reset | Last   6 Secs | Since HSM Reset | Last   6 Secs
-------------------|-----------------|---------------|-----------------|---------------
         1,117,227 |      57,471,775 |             1 |            1.27 |          0.00
         1,117,233 |      57,471,805 |            30 |            1.27 |          0.18
         1,117,239 |      57,471,806 |             1 |            1.27 |          0.00
         1,117,245 |      57,471,807 |             1 |            1.27 |          0.00
         1,117,251 |      57,471,837 |            30 |            1.27 |          0.18
         1,117,257 |      57,471,838 |             1 |            1.27 |          0.00
-------------------|-----------------|---------------|-----------------|---------------

    Average HSM Utilization In This Period :  0.06%
    HSM Last Reset                         :  Fri May 31 14:59:46 2013


The HSM untilization counters are saved to file hsm_stats.
Please run `my file list` command to see it. You may also
want to `scp` the file out for further analysis.

Command Result : 0 (Success)
[local_host] lunash:>