qmp-events: move 'RTC_CHANGE' doc to schema
[qemu/ar7.git] / docs / qmp-events.txt
blob35760649aab5481adc84340a3ffbfa6a43653cf1
1                    QEMU Machine Protocol Events
2                    ============================
4 ACPI_DEVICE_OST
5 ---------------
7 Emitted when guest executes ACPI _OST method.
9  - data: ACPIOSTInfo type as described in qapi-schema.json
11 { "event": "ACPI_DEVICE_OST",
12      "data": { "device": "d1", "slot": "0", "slot-type": "DIMM", "source": 1, "status": 0 } }
14 BALLOON_CHANGE
15 --------------
17 Emitted when the guest changes the actual BALLOON level. This
18 value is equivalent to the 'actual' field return by the
19 'query-balloon' command
21 Data:
23 - "actual": actual level of the guest memory balloon in bytes (json-number)
25 Example:
27 { "event": "BALLOON_CHANGE",
28     "data": { "actual": 944766976 },
29     "timestamp": { "seconds": 1267020223, "microseconds": 435656 } }
31 Note: this event is rate-limited.
33 DEVICE_DELETED
34 --------------
36 Emitted whenever the device removal completion is acknowledged
37 by the guest.
38 At this point, it's safe to reuse the specified device ID.
39 Device removal can be initiated by the guest or by HMP/QMP commands.
41 Data:
43 - "device": device name (json-string, optional)
44 - "path": device path (json-string)
46 { "event": "DEVICE_DELETED",
47   "data": { "device": "virtio-net-pci-0",
48             "path": "/machine/peripheral/virtio-net-pci-0" },
49   "timestamp": { "seconds": 1265044230, "microseconds": 450486 } }
51 DUMP_COMPLETED
52 --------------
54 Emitted when the guest has finished one memory dump.
56 Data:
58 - "result": DumpQueryResult type described in qapi-schema.json
59 - "error": Error message when dump failed. This is only a
60   human-readable string provided when dump failed. It should not be
61   parsed in any way (json-string, optional)
63 Example:
65 { "event": "DUMP_COMPLETED",
66   "data": {"result": {"total": 1090650112, "status": "completed",
67                       "completed": 1090650112} } }
69 GUEST_PANICKED
70 --------------
72 Emitted when guest OS panic is detected.
74 Data:
76 - "action": Action that has been taken (json-string, currently always "pause").
78 Example:
80 { "event": "GUEST_PANICKED",
81      "data": { "action": "pause" } }
83 MEM_UNPLUG_ERROR
84 --------------------
85 Emitted when memory hot unplug error occurs.
87 Data:
89 - "device": device name (json-string)
90 - "msg": Informative message (e.g., reason for the error) (json-string)
92 Example:
94 { "event": "MEM_UNPLUG_ERROR"
95   "data": { "device": "dimm1",
96             "msg": "acpi: device unplug for unsupported device"
97   },
98   "timestamp": { "seconds": 1265044230, "microseconds": 450486 } }
100 NIC_RX_FILTER_CHANGED
101 ---------------------
103 The event is emitted once until the query command is executed,
104 the first event will always be emitted.
106 Data:
108 - "name": net client name (json-string)
109 - "path": device path (json-string)
111 { "event": "NIC_RX_FILTER_CHANGED",
112   "data": { "name": "vnet0",
113             "path": "/machine/peripheral/vnet0/virtio-backend" },
114   "timestamp": { "seconds": 1368697518, "microseconds": 326866 } }
117 QUORUM_FAILURE
118 --------------
120 Emitted by the Quorum block driver if it fails to establish a quorum.
122 Data:
124 - "reference":     device name if defined else node name.
125 - "sector-num":    Number of the first sector of the failed read operation.
126 - "sectors-count": Failed read operation sector count.
128 Example:
130 { "event": "QUORUM_FAILURE",
131      "data": { "reference": "usr1", "sector-num": 345435, "sectors-count": 5 },
132      "timestamp": { "seconds": 1344522075, "microseconds": 745528 } }
134 Note: this event is rate-limited.
136 QUORUM_REPORT_BAD
137 -----------------
139 Emitted to report a corruption of a Quorum file.
141 Data:
143 - "type":          Quorum operation type
144 - "error":         Error message (json-string, optional)
145                    Only present on failure.  This field contains a human-readable
146                    error message.  There are no semantics other than that the
147                    block layer reported an error and clients should not try to
148                    interpret the error string.
149 - "node-name":     The graph node name of the block driver state.
150 - "sector-num":    Number of the first sector of the failed read operation.
151 - "sectors-count": Failed read operation sector count.
153 Example:
155 Read operation:
156 { "event": "QUORUM_REPORT_BAD",
157      "data": { "node-name": "node0", "sector-num": 345435, "sectors-count": 5,
158                "type": "read" },
159      "timestamp": { "seconds": 1344522075, "microseconds": 745528 } }
161 Flush operation:
162 { "event": "QUORUM_REPORT_BAD",
163      "data": { "node-name": "node0", "sector-num": 0, "sectors-count": 2097120,
164                "type": "flush", "error": "Broken pipe" },
165      "timestamp": { "seconds": 1456406829, "microseconds": 291763 } }
167 Note: this event is rate-limited.
169 SPICE_CONNECTED
170 ---------------
172 Emitted when a SPICE client connects.
174 Data:
176 - "server": Server information (json-object)
177   - "host": IP address (json-string)
178   - "port": port number (json-string)
179   - "family": address family (json-string, "ipv4" or "ipv6")
180 - "client": Client information (json-object)
181   - "host": IP address (json-string)
182   - "port": port number (json-string)
183   - "family": address family (json-string, "ipv4" or "ipv6")
185 Example:
187 { "timestamp": {"seconds": 1290688046, "microseconds": 388707},
188   "event": "SPICE_CONNECTED",
189   "data": {
190     "server": { "port": "5920", "family": "ipv4", "host": "127.0.0.1"},
191     "client": {"port": "52873", "family": "ipv4", "host": "127.0.0.1"}
194 SPICE_DISCONNECTED
195 ------------------
197 Emitted when a SPICE client disconnects.
199 Data:
201 - "server": Server information (json-object)
202   - "host": IP address (json-string)
203   - "port": port number (json-string)
204   - "family": address family (json-string, "ipv4" or "ipv6")
205 - "client": Client information (json-object)
206   - "host": IP address (json-string)
207   - "port": port number (json-string)
208   - "family": address family (json-string, "ipv4" or "ipv6")
210 Example:
212 { "timestamp": {"seconds": 1290688046, "microseconds": 388707},
213   "event": "SPICE_DISCONNECTED",
214   "data": {
215     "server": { "port": "5920", "family": "ipv4", "host": "127.0.0.1"},
216     "client": {"port": "52873", "family": "ipv4", "host": "127.0.0.1"}
219 SPICE_INITIALIZED
220 -----------------
222 Emitted after initial handshake and authentication takes place (if any)
223 and the SPICE channel is up and running
225 Data:
227 - "server": Server information (json-object)
228   - "host": IP address (json-string)
229   - "port": port number (json-string)
230   - "family": address family (json-string, "ipv4" or "ipv6")
231   - "auth": authentication method (json-string, optional)
232 - "client": Client information (json-object)
233   - "host": IP address (json-string)
234   - "port": port number (json-string)
235   - "family": address family (json-string, "ipv4" or "ipv6")
236   - "connection-id": spice connection id.  All channels with the same id
237                      belong to the same spice session (json-int)
238   - "channel-type": channel type.  "1" is the main control channel, filter for
239                     this one if you want track spice sessions only (json-int)
240   - "channel-id": channel id.  Usually "0", might be different needed when
241                   multiple channels of the same type exist, such as multiple
242                   display channels in a multihead setup (json-int)
243   - "tls": whevener the channel is encrypted (json-bool)
245 Example:
247 { "timestamp": {"seconds": 1290688046, "microseconds": 417172},
248   "event": "SPICE_INITIALIZED",
249   "data": {"server": {"auth": "spice", "port": "5921",
250                       "family": "ipv4", "host": "127.0.0.1"},
251            "client": {"port": "49004", "family": "ipv4", "channel-type": 3,
252                       "connection-id": 1804289383, "host": "127.0.0.1",
253                       "channel-id": 0, "tls": true}
256 SPICE_MIGRATE_COMPLETED
257 -----------------------
259 Emitted when SPICE migration has completed
261 Data: None.
263 Example:
265 { "timestamp": {"seconds": 1290688046, "microseconds": 417172},
266   "event": "SPICE_MIGRATE_COMPLETED" }
268 MIGRATION
269 ---------
271 Emitted when a migration event happens
273 Data: None.
275  - "status": migration status
276      See MigrationStatus in ~/qapi-schema.json for possible values
278 Example:
280 {"timestamp": {"seconds": 1432121972, "microseconds": 744001},
281  "event": "MIGRATION", "data": {"status": "completed"}}
283 MIGRATION_PASS
284 --------------
286 Emitted from the source side of a migration at the start of each pass
287 (when it syncs the dirty bitmap)
289 Data: None.
291   - "pass": An incrementing count (starting at 1 on the first pass)
293 Example:
294 {"timestamp": {"seconds": 1449669631, "microseconds": 239225},
295  "event": "MIGRATION_PASS", "data": {"pass": 2}}
297 VNC_CONNECTED
298 -------------
300 Emitted when a VNC client establishes a connection.
302 Data:
304 - "server": Server information (json-object)
305   - "host": IP address (json-string)
306   - "service": port number (json-string)
307   - "family": address family (json-string, "ipv4" or "ipv6")
308   - "auth": authentication method (json-string, optional)
309 - "client": Client information (json-object)
310   - "host": IP address (json-string)
311   - "service": port number (json-string)
312   - "family": address family (json-string, "ipv4" or "ipv6")
314 Example:
316 { "event": "VNC_CONNECTED",
317     "data": {
318         "server": { "auth": "sasl", "family": "ipv4",
319                     "service": "5901", "host": "0.0.0.0" },
320         "client": { "family": "ipv4", "service": "58425",
321                     "host": "127.0.0.1" } },
322     "timestamp": { "seconds": 1262976601, "microseconds": 975795 } }
325 Note: This event is emitted before any authentication takes place, thus
326 the authentication ID is not provided.
328 VNC_DISCONNECTED
329 ----------------
331 Emitted when the connection is closed.
333 Data:
335 - "server": Server information (json-object)
336   - "host": IP address (json-string)
337   - "service": port number (json-string)
338   - "family": address family (json-string, "ipv4" or "ipv6")
339   - "auth": authentication method (json-string, optional)
340 - "client": Client information (json-object)
341   - "host": IP address (json-string)
342   - "service": port number (json-string)
343   - "family": address family (json-string, "ipv4" or "ipv6")
344   - "x509_dname": TLS dname (json-string, optional)
345   - "sasl_username": SASL username (json-string, optional)
347 Example:
349 { "event": "VNC_DISCONNECTED",
350     "data": {
351         "server": { "auth": "sasl", "family": "ipv4",
352                     "service": "5901", "host": "0.0.0.0" },
353         "client": { "family": "ipv4", "service": "58425",
354                     "host": "127.0.0.1", "sasl_username": "luiz" } },
355     "timestamp": { "seconds": 1262976601, "microseconds": 975795 } }
357 VNC_INITIALIZED
358 ---------------
360 Emitted after authentication takes place (if any) and the VNC session is
361 made active.
363 Data:
365 - "server": Server information (json-object)
366   - "host": IP address (json-string)
367   - "service": port number (json-string)
368   - "family": address family (json-string, "ipv4" or "ipv6")
369   - "auth": authentication method (json-string, optional)
370 - "client": Client information (json-object)
371   - "host": IP address (json-string)
372   - "service": port number (json-string)
373   - "family": address family (json-string, "ipv4" or "ipv6")
374   - "x509_dname": TLS dname (json-string, optional)
375   - "sasl_username": SASL username (json-string, optional)
377 Example:
379 { "event": "VNC_INITIALIZED",
380     "data": {
381         "server": { "auth": "sasl", "family": "ipv4",
382                     "service": "5901", "host": "0.0.0.0"},
383         "client": { "family": "ipv4", "service": "46089",
384                     "host": "127.0.0.1", "sasl_username": "luiz" } },
385         "timestamp": { "seconds": 1263475302, "microseconds": 150772 } }
387 VSERPORT_CHANGE
388 ---------------
390 Emitted when the guest opens or closes a virtio-serial port.
392 Data:
394 - "id": device identifier of the virtio-serial port (json-string)
395 - "open": true if the guest has opened the virtio-serial port (json-bool)
397 Example:
399 { "event": "VSERPORT_CHANGE",
400     "data": { "id": "channel0", "open": true },
401     "timestamp": { "seconds": 1401385907, "microseconds": 422329 } }
403 Note: this event is rate-limited separately for each "id".
405 WATCHDOG
406 --------
408 Emitted when the watchdog device's timer is expired.
410 Data:
412 - "action": Action that has been taken, it's one of the following (json-string):
413             "reset", "shutdown", "poweroff", "pause", "debug", or "none"
415 Example:
417 { "event": "WATCHDOG",
418      "data": { "action": "reset" },
419      "timestamp": { "seconds": 1267061043, "microseconds": 959568 } }
421 Note: If action is "reset", "shutdown", or "pause" the WATCHDOG event is
422 followed respectively by the RESET, SHUTDOWN, or STOP events.
424 Note: this event is rate-limited.