1 04/04/86 command_usage_count, cuc
2
3 Syntax: cuc operation command_names -control_args
4
5
6 Function: provides a record of the number of times commands are used
7 and the User_ids for each invocation of them.
8
9
10 List of operations:
11 add
12 adds commands to the list of commands to be metered. Commands added
13 to the list in a single invocation form a command "group," which you
14 can manipulate as a whole.
15 delete, dl
16 deletes command groups from the list of commands to be metered.
17 print, pr
18 prints, and clears, the metered data subject to any restrictions
19 the specified control_args impose.
20
21
22 Arguments:
23 command_names
24 are long or short names of commands. With either the print or
25 delete operation, you need give only one command name from each
26 group to be printed or deleted; all the commands in each group so
27 represented are acted upon. If you supply no names with the print
28 or delete operation, all command groups are printed/deleted. You
29 must use long and/or short command names with the add operation; all
30 the names added in a single invocation are added as a single group
31 to the list. You can only use short names of commands with the
32 print and delete operations if you specified them with the add
33 operation.
34
35
36 Control arguments:
37 -all, -a
38 prints meters for all the command groups or deletes all command
39 groups from the list. You can't use it with the add operation.
40 Default for the print and delete operations if you give no
41 command_names
42 -brief, -bf
43 omits column headings from the printout. You can only use it with
44 the print operation. Default: to print column headings
45 -clear, -cl
46 clears the usage counters and user list when meters are printed.
47 You can only use it with the print operation. It clears the user
48 list even if you also supply -total.
49
50
51 -first N, -ft N
52 prints only the N greatest users of the specified commands. You can
53 only use it with the print operation. You can't use it in
54 conjunction with -total.
55 -total, -tt
56 prints only the total use of the commands in the specified command
57 groups when used with the print operation; meters only the total
58 usage of commands specified when used with the add operation. You
59 can't use it with the delete operation. Default with both of these
60 operations: to print/meter the users of the commands as well as
61 total usage; see "Notes" below
62
63
64 Access required: To add and delete commands and to clear meters, you
65 must have rw access to the command_usage_list_ segment. All users
66 should have r access to command_usage_list_ and rw access to
67 command_usage_totals_. Both segments are found using object search
68 rules and most commonly are in >sss system_library_standard
69 directory. If they are not in >sss, a link in >sss points to them.
70
71
72 Notes: The commands to be metered must be listed in a segment named
73 command_usage_list_. Usage totals are stored in a segment named
74 command_usage_totals_. This command actually performs three
75 operations: it prints and clears the meters, adds commands to
76 command_usage_list_, and deletes commands from command_usage_list_.
77
78
79 For each group of commands added without -total, cuc creates a segment
80 named command_name.usage in >sss or if a link is there wherever the
81 link points. You must put the link in >sss before the first usage of
82 "cuc add," since the metering program creates the command_name.usage
83 segment in the same directory in which it finds command_usage_list_.
84 The command_name.usage segment contains the list of User_ids for those
85 using the commands in the group. User_ids are printed in the order of
86 greatest usage. When you supply -first, in addition to printing the
87 user count and name for the N greatest users, cuc prints an additional
88 line giving the user count for "all others."
89
90 At sites using the access isolation mechanism AIM, only the usage of
91 system_low users is recorded.