]> git.proxmox.com Git - qemu.git/blame - QMP/qmp-events.txt
qemu-iotests: exclude vmdk and qcow from 043
[qemu.git] / QMP / qmp-events.txt
CommitLineData
d74c7dfd
LC
1 QEMU Monitor Protocol Events
2 ============================
e2419113 3
cb8900fe
LC
4BALLOON_CHANGE
5--------------
6
7Emitted when the guest changes the actual BALLOON level. This
8value is equivalent to the 'actual' field return by the
9'query-balloon' command
10
11Data:
12
13- "actual": actual level of the guest memory balloon in bytes (json-number)
14
15Example:
16
17{ "event": "BALLOON_CHANGE",
18 "data": { "actual": 944766976 },
19 "timestamp": { "seconds": 1267020223, "microseconds": 435656 } }
20
d74c7dfd
LC
21BLOCK_IO_ERROR
22--------------
23
24Emitted when a disk I/O error occurs.
25
26Data:
27
28- "device": device name (json-string)
29- "operation": I/O operation (json-string, "read" or "write")
30- "action": action that has been taken, it's one of the following (json-string):
31 "ignore": error has been ignored
32 "report": error has been reported to the device
33 "stop": error caused VM to be stopped
34
35Example:
36
37{ "event": "BLOCK_IO_ERROR",
38 "data": { "device": "ide0-hd1",
39 "operation": "write",
40 "action": "stop" },
41 "timestamp": { "seconds": 1265044230, "microseconds": 450486 } }
42
43Note: If action is "stop", a STOP event will eventually follow the
44BLOCK_IO_ERROR event.
45
cb8900fe
LC
46BLOCK_JOB_CANCELLED
47-------------------
48
49Emitted when a block job has been cancelled.
50
51Data:
52
ed61fc10
JC
53- "type": Job type (json-string; "stream" for image streaming
54 "commit" for block commit)
cb8900fe
LC
55- "device": Device name (json-string)
56- "len": Maximum progress value (json-int)
57- "offset": Current progress value (json-int)
58 On success this is equal to len.
59 On failure this is less than len.
60- "speed": Rate limit, bytes per second (json-int)
61
62Example:
63
64{ "event": "BLOCK_JOB_CANCELLED",
65 "data": { "type": "stream", "device": "virtio-disk0",
66 "len": 10737418240, "offset": 134217728,
67 "speed": 0 },
68 "timestamp": { "seconds": 1267061043, "microseconds": 959568 } }
69
70BLOCK_JOB_COMPLETED
71-------------------
72
73Emitted when a block job has completed.
74
75Data:
76
ed61fc10
JC
77- "type": Job type (json-string; "stream" for image streaming
78 "commit" for block commit)
cb8900fe
LC
79- "device": Device name (json-string)
80- "len": Maximum progress value (json-int)
81- "offset": Current progress value (json-int)
82 On success this is equal to len.
83 On failure this is less than len.
84- "speed": Rate limit, bytes per second (json-int)
85- "error": Error message (json-string, optional)
86 Only present on failure. This field contains a human-readable
87 error message. There are no semantics other than that streaming
88 has failed and clients should not try to interpret the error
89 string.
90
91Example:
92
93{ "event": "BLOCK_JOB_COMPLETED",
94 "data": { "type": "stream", "device": "virtio-disk0",
95 "len": 10737418240, "offset": 10737418240,
96 "speed": 0 },
97 "timestamp": { "seconds": 1267061043, "microseconds": 959568 } }
98
32c81a4a
PB
99BLOCK_JOB_ERROR
100---------------
101
102Emitted when a block job encounters an error.
103
104Data:
105
106- "device": device name (json-string)
107- "operation": I/O operation (json-string, "read" or "write")
108- "action": action that has been taken, it's one of the following (json-string):
109 "ignore": error has been ignored, the job may fail later
110 "report": error will be reported and the job canceled
111 "stop": error caused job to be paused
112
113Example:
114
115{ "event": "BLOCK_JOB_ERROR",
116 "data": { "device": "ide0-hd1",
117 "operation": "write",
118 "action": "stop" },
119 "timestamp": { "seconds": 1265044230, "microseconds": 450486 } }
120
a66a2a36
PB
121BLOCK_JOB_READY
122---------------
123
124Emitted when a block job is ready to complete.
125
126Data:
127
128- "device": device name (json-string)
129
130Example:
131
132{ "event": "BLOCK_JOB_READY",
133 "data": { "device": "ide0-hd1" },
134 "timestamp": { "seconds": 1265044230, "microseconds": 450486 } }
135
136Note: The "ready to complete" status is always reset by a BLOCK_JOB_ERROR
137event.
138
0402a5d6
MT
139DEVICE_DELETED
140-----------------
141
142Emitted whenever the device removal completion is acknowledged
143by the guest.
144At this point, it's safe to reuse the specified device ID.
145Device removal can be initiated by the guest or by HMP/QMP commands.
146
147Data:
148
149- "device": device name (json-string, optional)
15054fce 150- "path": device path (json-string)
0402a5d6
MT
151
152{ "event": "DEVICE_DELETED",
15054fce
MT
153 "data": { "device": "virtio-net-pci-0",
154 "path": "/machine/peripheral/virtio-net-pci-0" },
0402a5d6
MT
155 "timestamp": { "seconds": 1265044230, "microseconds": 450486 } }
156
6f382ed2
LC
157DEVICE_TRAY_MOVED
158-----------------
159
160It's emitted whenever the tray of a removable device is moved by the guest
161or by HMP/QMP commands.
162
163Data:
164
165- "device": device name (json-string)
166- "tray-open": true if the tray has been opened or false if it has been closed
167 (json-bool)
168
169{ "event": "DEVICE_TRAY_MOVED",
170 "data": { "device": "ide1-cd0",
171 "tray-open": true
172 },
173 "timestamp": { "seconds": 1265044230, "microseconds": 450486 } }
174
d74c7dfd
LC
175RESET
176-----
177
178Emitted when the Virtual Machine is reseted.
e2419113 179
e2419113
LC
180Data: None.
181
d74c7dfd
LC
182Example:
183
184{ "event": "RESET",
185 "timestamp": { "seconds": 1267041653, "microseconds": 9518 } }
186
6ed2c484
LC
187RESUME
188------
189
190Emitted when the Virtual Machine resumes execution.
191
192Data: None.
193
194Example:
195
196{ "event": "RESUME",
197 "timestamp": { "seconds": 1271770767, "microseconds": 582542 } }
198
80cd3478
LC
199RTC_CHANGE
200----------
201
db11571f 202Emitted when the guest changes the RTC time.
80cd3478
LC
203
204Data:
205
206- "offset": delta against the host UTC in seconds (json-number)
207
208Example:
209
210{ "event": "RTC_CHANGE",
211 "data": { "offset": 78 },
212 "timestamp": { "seconds": 1267020223, "microseconds": 435656 } }
213
d74c7dfd
LC
214SHUTDOWN
215--------
216
217Emitted when the Virtual Machine is powered down.
e2419113 218
e2419113
LC
219Data: None.
220
d74c7dfd
LC
221Example:
222
223{ "event": "SHUTDOWN",
224 "timestamp": { "seconds": 1267040730, "microseconds": 682951 } }
225
226Note: If the command-line option "-no-shutdown" has been specified, a STOP
227event will eventually follow the SHUTDOWN event.
228
cb8900fe
LC
229SPICE_CONNECTED, SPICE_DISCONNECTED
230-----------------------------------
231
232Emitted when a SPICE client connects or disconnects.
233
234Data:
235
236- "server": Server information (json-object)
237 - "host": IP address (json-string)
238 - "port": port number (json-string)
239 - "family": address family (json-string, "ipv4" or "ipv6")
240- "client": Client information (json-object)
241 - "host": IP address (json-string)
242 - "port": port number (json-string)
243 - "family": address family (json-string, "ipv4" or "ipv6")
244
245Example:
246
247{ "timestamp": {"seconds": 1290688046, "microseconds": 388707},
248 "event": "SPICE_CONNECTED",
249 "data": {
250 "server": { "port": "5920", "family": "ipv4", "host": "127.0.0.1"},
251 "client": {"port": "52873", "family": "ipv4", "host": "127.0.0.1"}
252}}
253
254SPICE_INITIALIZED
255-----------------
256
257Emitted after initial handshake and authentication takes place (if any)
258and the SPICE channel is up'n'running
259
260Data:
261
262- "server": Server information (json-object)
263 - "host": IP address (json-string)
264 - "port": port number (json-string)
265 - "family": address family (json-string, "ipv4" or "ipv6")
266 - "auth": authentication method (json-string, optional)
267- "client": Client information (json-object)
268 - "host": IP address (json-string)
269 - "port": port number (json-string)
270 - "family": address family (json-string, "ipv4" or "ipv6")
271 - "connection-id": spice connection id. All channels with the same id
272 belong to the same spice session (json-int)
273 - "channel-type": channel type. "1" is the main control channel, filter for
274 this one if you want track spice sessions only (json-int)
275 - "channel-id": channel id. Usually "0", might be different needed when
276 multiple channels of the same type exist, such as multiple
277 display channels in a multihead setup (json-int)
278 - "tls": whevener the channel is encrypted (json-bool)
279
280Example:
281
282{ "timestamp": {"seconds": 1290688046, "microseconds": 417172},
283 "event": "SPICE_INITIALIZED",
284 "data": {"server": {"auth": "spice", "port": "5921",
285 "family": "ipv4", "host": "127.0.0.1"},
286 "client": {"port": "49004", "family": "ipv4", "channel-type": 3,
287 "connection-id": 1804289383, "host": "127.0.0.1",
288 "channel-id": 0, "tls": true}
289}}
290
d74c7dfd
LC
291STOP
292----
293
294Emitted when the Virtual Machine is stopped.
e2419113 295
e2419113
LC
296Data: None.
297
d74c7dfd 298Example:
586153d9 299
7af72c24 300{ "event": "STOP",
d74c7dfd 301 "timestamp": { "seconds": 1267041730, "microseconds": 281295 } }
0d72f3d3 302
67e3cf26
LC
303SUSPEND
304-------
305
306Emitted when guest enters S3 state.
307
308Data: None.
309
310Example:
311
312{ "event": "SUSPEND",
313 "timestamp": { "seconds": 1344456160, "microseconds": 309119 } }
314
25df49f6
LC
315SUSPEND_DISK
316------------
317
318Emitted when the guest makes a request to enter S4 state.
319
320Data: None.
321
322Example:
323
324{ "event": "SUSPEND_DISK",
325 "timestamp": { "seconds": 1344456160, "microseconds": 309119 } }
326
327Note: QEMU shuts down when entering S4 state.
328
d74c7dfd
LC
329VNC_CONNECTED
330-------------
0d72f3d3 331
d74c7dfd
LC
332Emitted when a VNC client establishes a connection.
333
334Data:
335
336- "server": Server information (json-object)
337 - "host": IP address (json-string)
338 - "service": port number (json-string)
339 - "family": address family (json-string, "ipv4" or "ipv6")
340 - "auth": authentication method (json-string, optional)
341- "client": Client information (json-object)
342 - "host": IP address (json-string)
343 - "service": port number (json-string)
344 - "family": address family (json-string, "ipv4" or "ipv6")
345
346Example:
0d2ed46a 347
d74c7dfd
LC
348{ "event": "VNC_CONNECTED",
349 "data": {
350 "server": { "auth": "sasl", "family": "ipv4",
351 "service": "5901", "host": "0.0.0.0" },
352 "client": { "family": "ipv4", "service": "58425",
353 "host": "127.0.0.1" } },
354 "timestamp": { "seconds": 1262976601, "microseconds": 975795 } }
0d2ed46a 355
aa1db6ed 356
d74c7dfd
LC
357Note: This event is emitted before any authentication takes place, thus
358the authentication ID is not provided.
359
360VNC_DISCONNECTED
aa1db6ed
LC
361----------------
362
dee3bffc 363Emitted when the connection is closed.
d74c7dfd 364
aa1db6ed
LC
365Data:
366
d74c7dfd
LC
367- "server": Server information (json-object)
368 - "host": IP address (json-string)
369 - "service": port number (json-string)
370 - "family": address family (json-string, "ipv4" or "ipv6")
371 - "auth": authentication method (json-string, optional)
372- "client": Client information (json-object)
373 - "host": IP address (json-string)
374 - "service": port number (json-string)
375 - "family": address family (json-string, "ipv4" or "ipv6")
376 - "x509_dname": TLS dname (json-string, optional)
377 - "sasl_username": SASL username (json-string, optional)
aa1db6ed
LC
378
379Example:
380
d74c7dfd
LC
381{ "event": "VNC_DISCONNECTED",
382 "data": {
383 "server": { "auth": "sasl", "family": "ipv4",
384 "service": "5901", "host": "0.0.0.0" },
385 "client": { "family": "ipv4", "service": "58425",
386 "host": "127.0.0.1", "sasl_username": "luiz" } },
387 "timestamp": { "seconds": 1262976601, "microseconds": 975795 } }
388
389VNC_INITIALIZED
390---------------
391
392Emitted after authentication takes place (if any) and the VNC session is
393made active.
394
395Data:
396
397- "server": Server information (json-object)
398 - "host": IP address (json-string)
399 - "service": port number (json-string)
400 - "family": address family (json-string, "ipv4" or "ipv6")
401 - "auth": authentication method (json-string, optional)
402- "client": Client information (json-object)
403 - "host": IP address (json-string)
404 - "service": port number (json-string)
405 - "family": address family (json-string, "ipv4" or "ipv6")
406 - "x509_dname": TLS dname (json-string, optional)
407 - "sasl_username": SASL username (json-string, optional)
408
409Example:
410
411{ "event": "VNC_INITIALIZED",
412 "data": {
413 "server": { "auth": "sasl", "family": "ipv4",
414 "service": "5901", "host": "0.0.0.0"},
415 "client": { "family": "ipv4", "service": "46089",
416 "host": "127.0.0.1", "sasl_username": "luiz" } },
417 "timestamp": { "seconds": 1263475302, "microseconds": 150772 } }
9eedeb3b 418
17c8660b
LC
419WAKEUP
420------
421
422Emitted when the guest has woken up from S3 and is running.
423
424Data: None.
425
426Example:
427
428{ "event": "WATCHDOG",
429 "timestamp": { "seconds": 1344522075, "microseconds": 745528 } }
430
9eedeb3b
LC
431WATCHDOG
432--------
433
434Emitted when the watchdog device's timer is expired.
435
436Data:
437
438- "action": Action that has been taken, it's one of the following (json-string):
439 "reset", "shutdown", "poweroff", "pause", "debug", or "none"
440
441Example:
442
443{ "event": "WATCHDOG",
444 "data": { "action": "reset" },
445 "timestamp": { "seconds": 1267061043, "microseconds": 959568 } }
446
447Note: If action is "reset", "shutdown", or "pause" the WATCHDOG event is
448followed respectively by the RESET, SHUTDOWN, or STOP events.
c401a8a5
HT
449
450GUEST_PANICKED
451--------------
452
453Emitted when guest OS panic is detected.
454
455Data:
456
457- "action": Action that has been taken (json-string, currently always "pause").
458
459Example:
460
461{ "event": "GUEST_PANICKED",
462 "data": { "action": "pause" } }