1ctstat(1)                        User Commands                       ctstat(1)
2
3
4

NAME

6       ctstat - display active system contracts
7

SYNOPSIS

9       /usr/bin/ctstat [-a] [-i contractid...] [-t type...] [-v]
10            [-T u | d ] [interval [count]]
11
12

DESCRIPTION

14       The  ctstat  utility allows a user to observe the contracts active on a
15       system.
16
17
18       Unless you specify the -i or -t option, ctstat displays  statistics  on
19       all contracts in the system.
20

OPTIONS

22       The following options are supported:
23
24       -a
25
26           Display  all  contracts regardless of state. By default, only those
27           contracts which are in the owned, inherited, or orphan  states  are
28           displayed.
29
30
31       -i contractid...
32
33           Request  status  on  the  specified  contracts, identified by their
34           numeric contract identifier (contract_id).
35
36           This option accepts lists as arguments . Items in the list  can  be
37           separated  by commas, or enclosed in quotes and separated by commas
38           or spaces.
39
40
41       -T u | d
42
43           Display a time stamp.
44
45           Specify u for a printed representation of the internal  representa‐
46           tion  of time. See time(2). Specify d for standard date format. See
47           date(1).
48
49
50       -t type...
51
52           Request status on contracts of the specified type (type).
53
54           This option accepts lists as arguments. Items in the  list  can  be
55           separated  by commas, or enclosed in quotes and separated by commas
56           or spaces.
57
58           The following types are supported:
59
60           process
61
62               Process contracts
63
64
65
66       -v
67
68           Verbose output.
69
70

OPERANDS

72       The following operands are supported:
73
74       interval
75
76           Report once each interval seconds.
77
78
79       count
80
81           Print only count reports.
82
83

OUTPUT

85       The following list defines the column headings and the  meanings  of  a
86       ctstat report:
87
88       CTID
89
90           The contract ID of the contract.
91
92
93       ZONEID
94
95           The zone ID of the contract's creator.
96
97
98       TYPE
99
100           The contract type.
101
102
103       STATE
104
105           The state of the contract:
106
107           owned
108
109               Contract is owned by a process.
110
111
112           inherited
113
114               The  contract  owner has exited abnormally and the contract has
115               been inherited by the owner's process contract.
116
117
118           orphan
119
120               The contract owner has abandoned  the  contract,  the  contract
121               owner  exited  abnormally and the contract was not inherited by
122               the owner's process contract, or the process contract which had
123               inherited the contract was abandoned by its owner.
124
125
126           dead
127
128               The contract is no longer active. It is removed from the system
129               automatically when all references to it (open file descriptors,
130               contract templates, and events) have been released.
131
132
133
134       HOLDER
135
136           If  the contract is in the owned state, the pid of the process that
137           owns the contract. If the contract is in the inherited  state,  the
138           id of the regent process contract.
139
140
141       EVENTS
142
143           The number of unacknowledged critical events pending.
144
145
146       QTIME
147
148           The time until quantum ends, or - if no negotiation is in progress.
149
150
151       NTIME
152
153           The  time  until  negotiation  ends,  or  - if no negotiation is in
154           progress.
155
156

EXAMPLES

158       Example 1 Reporting on all Contracts in the System
159
160
161       The following example reports on all contracts in the system:
162
163
164         example% ctstat -a
165
166         CTID    TYPE    STATE   HOLDER  EVENTS  QTIME   NTIME
167         1       process owned   100579  0       -       -
168         2       process dead    -       1       -       -
169         3       process inherit 1       3       -       -
170         4       process orphan  -       0       -       -
171
172
173
174       Example 2 Obtaining a Verbose Report of All Contracts in the System
175
176
177       The following example obtains a verbose report of all contracts in  the
178       system:
179
180
181         example% ctstat -av
182
183         CTID    TYPE    STATE   HOLDER  EVENTS  QTIME   NTIME
184         1       process owned   100579  0       -       -
185                 informative event set: none
186                 critical event set:    hwerr core
187                 fatal event set:       hwerr
188                 parameter set:         none
189                 member processes:      100600 100601
190                 inherited ctids:       none
191                 service fmri:          svc:/system/init:default
192                 svc_fmri ctid:         1
193                 creator:               sched
194                 aux:
195
196         2       process dead    -       1       -       -
197                 informative event set: none
198                 critical event set:    none
199                 fatal event set:       hwerr core
200                 parameter set:         pgrponly
201                 member processes:      none
202                 inherited ctids:       none
203                 service fmri:          svc:/system/power:default
204                 svc_fmri ctid:         19
205                 creator:               svc.startd
206                 aux:                   start
207
208
209

EXIT STATUS

211       The following exit values are returned:
212
213       0
214
215           Successful completion.
216
217
218       1
219
220           An error occurred.
221
222
223       2
224
225           Invalid arguments.
226
227

FILES

229       /system/contract/*
230

ATTRIBUTES

232       See attributes(5) for descriptions of the following attributes:
233
234
235
236
237       ┌─────────────────────────────┬─────────────────────────────┐
238       │      ATTRIBUTE TYPE         │      ATTRIBUTE VALUE        │
239       ├─────────────────────────────┼─────────────────────────────┤
240       │Availability                 │SUNWcsu                      │
241       ├─────────────────────────────┼─────────────────────────────┤
242       │Interface Stability          │See below.                   │
243       └─────────────────────────────┴─────────────────────────────┘
244
245
246       The human readable output is Uncommitted. The invocation is Committed.
247

SEE ALSO

249       ctrun(1), ctwatch(1), contract(4), process(4), attributes(5)
250
251
252
253SunOS 5.11                        16 Jun 2009                        ctstat(1)
Impressum