qmp-events.txt 5.3 KB
Newer Older
1 2
                   QEMU Monitor Protocol Events
                   ============================
L
Luiz Capitulino 已提交
3

4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32
BLOCK_IO_ERROR
--------------

Emitted when a disk I/O error occurs.

Data:

- "device": device name (json-string)
- "operation": I/O operation (json-string, "read" or "write")
- "action": action that has been taken, it's one of the following (json-string):
    "ignore": error has been ignored
    "report": error has been reported to the device
    "stop": error caused VM to be stopped

Example:

{ "event": "BLOCK_IO_ERROR",
    "data": { "device": "ide0-hd1",
              "operation": "write",
              "action": "stop" },
    "timestamp": { "seconds": 1265044230, "microseconds": 450486 } }

Note: If action is "stop", a STOP event will eventually follow the
BLOCK_IO_ERROR event.

RESET
-----

Emitted when the Virtual Machine is reseted.
L
Luiz Capitulino 已提交
33 34 35

Data: None.

36 37 38 39 40
Example:

{ "event": "RESET",
    "timestamp": { "seconds": 1267041653, "microseconds": 9518 } }

L
Luiz Capitulino 已提交
41 42 43 44 45 46 47 48 49 50 51 52
RESUME
------

Emitted when the Virtual Machine resumes execution.

Data: None.

Example:

{ "event": "RESUME",
    "timestamp": { "seconds": 1271770767, "microseconds": 582542 } }

53 54 55
RTC_CHANGE
----------

56
Emitted when the guest changes the RTC time.
57 58 59 60 61 62 63 64 65 66 67

Data:

- "offset": delta against the host UTC in seconds (json-number)

Example:

{ "event": "RTC_CHANGE",
    "data": { "offset": 78 },
    "timestamp": { "seconds": 1267020223, "microseconds": 435656 } }

68 69 70 71
SHUTDOWN
--------

Emitted when the Virtual Machine is powered down.
L
Luiz Capitulino 已提交
72 73 74

Data: None.

75 76 77 78 79 80 81 82 83 84 85 86
Example:

{ "event": "SHUTDOWN",
    "timestamp": { "seconds": 1267040730, "microseconds": 682951 } }

Note: If the command-line option "-no-shutdown" has been specified, a STOP
event will eventually follow the SHUTDOWN event.

STOP
----

Emitted when the Virtual Machine is stopped.
L
Luiz Capitulino 已提交
87 88 89

Data: None.

90
Example:
91

92 93
{ "event": "SHUTDOWN",
    "timestamp": { "seconds": 1267041730, "microseconds": 281295 } }
94

95 96
VNC_CONNECTED
-------------
97

98 99 100 101 102 103 104 105 106 107 108 109 110 111 112
Emitted when a VNC client establishes a connection.

Data:

- "server": Server information (json-object)
  - "host": IP address (json-string)
  - "service": port number (json-string)
  - "family": address family (json-string, "ipv4" or "ipv6")
  - "auth": authentication method (json-string, optional)
- "client": Client information (json-object)
  - "host": IP address (json-string)
  - "service": port number (json-string)
  - "family": address family (json-string, "ipv4" or "ipv6")

Example:
113

114 115 116 117 118 119 120
{ "event": "VNC_CONNECTED",
    "data": {
        "server": { "auth": "sasl", "family": "ipv4",
                    "service": "5901", "host": "0.0.0.0" },
        "client": { "family": "ipv4", "service": "58425",
                    "host": "127.0.0.1" } },
    "timestamp": { "seconds": 1262976601, "microseconds": 975795 } }
121

122

123 124 125 126
Note: This event is emitted before any authentication takes place, thus
the authentication ID is not provided.

VNC_DISCONNECTED
127 128
----------------

129 130
Emitted when the conection is closed.

131 132
Data:

133 134 135 136 137 138 139 140 141 142 143
- "server": Server information (json-object)
  - "host": IP address (json-string)
  - "service": port number (json-string)
  - "family": address family (json-string, "ipv4" or "ipv6")
  - "auth": authentication method (json-string, optional)
- "client": Client information (json-object)
  - "host": IP address (json-string)
  - "service": port number (json-string)
  - "family": address family (json-string, "ipv4" or "ipv6")
  - "x509_dname": TLS dname (json-string, optional)
  - "sasl_username": SASL username (json-string, optional)
144 145 146

Example:

147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183
{ "event": "VNC_DISCONNECTED",
    "data": {
        "server": { "auth": "sasl", "family": "ipv4",
                    "service": "5901", "host": "0.0.0.0" },
        "client": { "family": "ipv4", "service": "58425",
                    "host": "127.0.0.1", "sasl_username": "luiz" } },
    "timestamp": { "seconds": 1262976601, "microseconds": 975795 } }

VNC_INITIALIZED
---------------

Emitted after authentication takes place (if any) and the VNC session is
made active.

Data:

- "server": Server information (json-object)
  - "host": IP address (json-string)
  - "service": port number (json-string)
  - "family": address family (json-string, "ipv4" or "ipv6")
  - "auth": authentication method (json-string, optional)
- "client": Client information (json-object)
  - "host": IP address (json-string)
  - "service": port number (json-string)
  - "family": address family (json-string, "ipv4" or "ipv6")
  - "x509_dname": TLS dname (json-string, optional)
  - "sasl_username": SASL username (json-string, optional)

Example:

{ "event": "VNC_INITIALIZED",
    "data": {
        "server": { "auth": "sasl", "family": "ipv4",
                    "service": "5901", "host": "0.0.0.0"},
        "client": { "family": "ipv4", "service": "46089",
                    "host": "127.0.0.1", "sasl_username": "luiz" } },
        "timestamp": { "seconds": 1263475302, "microseconds": 150772 } }
L
Luiz Capitulino 已提交
184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202

WATCHDOG
--------

Emitted when the watchdog device's timer is expired.

Data:

- "action": Action that has been taken, it's one of the following (json-string):
            "reset", "shutdown", "poweroff", "pause", "debug", or "none"

Example:

{ "event": "WATCHDOG",
     "data": { "action": "reset" },
     "timestamp": { "seconds": 1267061043, "microseconds": 959568 } }

Note: If action is "reset", "shutdown", or "pause" the WATCHDOG event is
followed respectively by the RESET, SHUTDOWN, or STOP events.