1 QEMU Monitor Protocol Events
2 ============================
7 Emitted when the guest changes the actual BALLOON level. This
8 value is equivalent to the 'actual' field return by the
9 'query-balloon' command
13 - "actual": actual level of the guest memory balloon in bytes (json-number)
17 { "event": "BALLOON_CHANGE",
18 "data": { "actual": 944766976 },
19 "timestamp": { "seconds": 1267020223, "microseconds": 435656 } }
24 Emitted when a disk I/O error occurs.
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
37 { "event": "BLOCK_IO_ERROR",
38 "data": { "device": "ide0-hd1",
41 "timestamp": { "seconds": 1265044230, "microseconds": 450486 } }
43 Note: If action is "stop", a STOP event will eventually follow the
49 Emitted when a block job has been cancelled.
53 - "type": Job type ("stream" for image streaming, json-string)
54 - "device": Device name (json-string)
55 - "len": Maximum progress value (json-int)
56 - "offset": Current progress value (json-int)
57 On success this is equal to len.
58 On failure this is less than len.
59 - "speed": Rate limit, bytes per second (json-int)
63 { "event": "BLOCK_JOB_CANCELLED",
64 "data": { "type": "stream", "device": "virtio-disk0",
65 "len": 10737418240, "offset": 134217728,
67 "timestamp": { "seconds": 1267061043, "microseconds": 959568 } }
72 Emitted when a block job has completed.
76 - "type": Job type ("stream" for image streaming, json-string)
77 - "device": Device name (json-string)
78 - "len": Maximum progress value (json-int)
79 - "offset": Current progress value (json-int)
80 On success this is equal to len.
81 On failure this is less than len.
82 - "speed": Rate limit, bytes per second (json-int)
83 - "error": Error message (json-string, optional)
84 Only present on failure. This field contains a human-readable
85 error message. There are no semantics other than that streaming
86 has failed and clients should not try to interpret the error
91 { "event": "BLOCK_JOB_COMPLETED",
92 "data": { "type": "stream", "device": "virtio-disk0",
93 "len": 10737418240, "offset": 10737418240,
95 "timestamp": { "seconds": 1267061043, "microseconds": 959568 } }
100 It's emitted whenever the tray of a removable device is moved by the guest
101 or by HMP/QMP commands.
105 - "device": device name (json-string)
106 - "tray-open": true if the tray has been opened or false if it has been closed
109 { "event": "DEVICE_TRAY_MOVED",
110 "data": { "device": "ide1-cd0",
113 "timestamp": { "seconds": 1265044230, "microseconds": 450486 } }
118 Emitted when the Virtual Machine is reseted.
125 "timestamp": { "seconds": 1267041653, "microseconds": 9518 } }
130 Emitted when the Virtual Machine resumes execution.
137 "timestamp": { "seconds": 1271770767, "microseconds": 582542 } }
142 Emitted when the guest changes the RTC time.
146 - "offset": delta against the host UTC in seconds (json-number)
150 { "event": "RTC_CHANGE",
151 "data": { "offset": 78 },
152 "timestamp": { "seconds": 1267020223, "microseconds": 435656 } }
157 Emitted when the Virtual Machine is powered down.
163 { "event": "SHUTDOWN",
164 "timestamp": { "seconds": 1267040730, "microseconds": 682951 } }
166 Note: If the command-line option "-no-shutdown" has been specified, a STOP
167 event will eventually follow the SHUTDOWN event.
169 SPICE_CONNECTED, SPICE_DISCONNECTED
170 -----------------------------------
172 Emitted when a SPICE client connects or disconnects.
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")
187 { "timestamp": {"seconds": 1290688046, "microseconds": 388707},
188 "event": "SPICE_CONNECTED",
190 "server": { "port": "5920", "family": "ipv4", "host": "127.0.0.1"},
191 "client": {"port": "52873", "family": "ipv4", "host": "127.0.0.1"}
197 Emitted after initial handshake and authentication takes place (if any)
198 and the SPICE channel is up'n'running
202 - "server": Server information (json-object)
203 - "host": IP address (json-string)
204 - "port": port number (json-string)
205 - "family": address family (json-string, "ipv4" or "ipv6")
206 - "auth": authentication method (json-string, optional)
207 - "client": Client information (json-object)
208 - "host": IP address (json-string)
209 - "port": port number (json-string)
210 - "family": address family (json-string, "ipv4" or "ipv6")
211 - "connection-id": spice connection id. All channels with the same id
212 belong to the same spice session (json-int)
213 - "channel-type": channel type. "1" is the main control channel, filter for
214 this one if you want track spice sessions only (json-int)
215 - "channel-id": channel id. Usually "0", might be different needed when
216 multiple channels of the same type exist, such as multiple
217 display channels in a multihead setup (json-int)
218 - "tls": whevener the channel is encrypted (json-bool)
222 { "timestamp": {"seconds": 1290688046, "microseconds": 417172},
223 "event": "SPICE_INITIALIZED",
224 "data": {"server": {"auth": "spice", "port": "5921",
225 "family": "ipv4", "host": "127.0.0.1"},
226 "client": {"port": "49004", "family": "ipv4", "channel-type": 3,
227 "connection-id": 1804289383, "host": "127.0.0.1",
228 "channel-id": 0, "tls": true}
234 Emitted when the Virtual Machine is stopped.
241 "timestamp": { "seconds": 1267041730, "microseconds": 281295 } }
246 Emitted when guest enters S3 state.
252 { "event": "SUSPEND",
253 "timestamp": { "seconds": 1344456160, "microseconds": 309119 } }
258 Emitted when the guest makes a request to enter S4 state.
264 { "event": "SUSPEND_DISK",
265 "timestamp": { "seconds": 1344456160, "microseconds": 309119 } }
267 Note: QEMU shuts down when entering S4 state.
272 Emitted when a VNC client establishes a connection.
276 - "server": Server information (json-object)
277 - "host": IP address (json-string)
278 - "service": port number (json-string)
279 - "family": address family (json-string, "ipv4" or "ipv6")
280 - "auth": authentication method (json-string, optional)
281 - "client": Client information (json-object)
282 - "host": IP address (json-string)
283 - "service": port number (json-string)
284 - "family": address family (json-string, "ipv4" or "ipv6")
288 { "event": "VNC_CONNECTED",
290 "server": { "auth": "sasl", "family": "ipv4",
291 "service": "5901", "host": "0.0.0.0" },
292 "client": { "family": "ipv4", "service": "58425",
293 "host": "127.0.0.1" } },
294 "timestamp": { "seconds": 1262976601, "microseconds": 975795 } }
297 Note: This event is emitted before any authentication takes place, thus
298 the authentication ID is not provided.
303 Emitted when the connection is closed.
307 - "server": Server information (json-object)
308 - "host": IP address (json-string)
309 - "service": port number (json-string)
310 - "family": address family (json-string, "ipv4" or "ipv6")
311 - "auth": authentication method (json-string, optional)
312 - "client": Client information (json-object)
313 - "host": IP address (json-string)
314 - "service": port number (json-string)
315 - "family": address family (json-string, "ipv4" or "ipv6")
316 - "x509_dname": TLS dname (json-string, optional)
317 - "sasl_username": SASL username (json-string, optional)
321 { "event": "VNC_DISCONNECTED",
323 "server": { "auth": "sasl", "family": "ipv4",
324 "service": "5901", "host": "0.0.0.0" },
325 "client": { "family": "ipv4", "service": "58425",
326 "host": "127.0.0.1", "sasl_username": "luiz" } },
327 "timestamp": { "seconds": 1262976601, "microseconds": 975795 } }
332 Emitted after authentication takes place (if any) and the VNC session is
337 - "server": Server information (json-object)
338 - "host": IP address (json-string)
339 - "service": port number (json-string)
340 - "family": address family (json-string, "ipv4" or "ipv6")
341 - "auth": authentication method (json-string, optional)
342 - "client": Client information (json-object)
343 - "host": IP address (json-string)
344 - "service": port number (json-string)
345 - "family": address family (json-string, "ipv4" or "ipv6")
346 - "x509_dname": TLS dname (json-string, optional)
347 - "sasl_username": SASL username (json-string, optional)
351 { "event": "VNC_INITIALIZED",
353 "server": { "auth": "sasl", "family": "ipv4",
354 "service": "5901", "host": "0.0.0.0"},
355 "client": { "family": "ipv4", "service": "46089",
356 "host": "127.0.0.1", "sasl_username": "luiz" } },
357 "timestamp": { "seconds": 1263475302, "microseconds": 150772 } }
362 Emitted when the guest has woken up from S3 and is running.
368 { "event": "WATCHDOG",
369 "timestamp": { "seconds": 1344522075, "microseconds": 745528 } }
374 Emitted when the watchdog device's timer is expired.
378 - "action": Action that has been taken, it's one of the following (json-string):
379 "reset", "shutdown", "poweroff", "pause", "debug", or "none"
383 { "event": "WATCHDOG",
384 "data": { "action": "reset" },
385 "timestamp": { "seconds": 1267061043, "microseconds": 959568 } }
387 Note: If action is "reset", "shutdown", or "pause" the WATCHDOG event is
388 followed respectively by the RESET, SHUTDOWN, or STOP events.