@@ -5,7 +5,7 @@ author: ajlam
5
5
ms.author : andrela
6
6
ms.service : mysql
7
7
ms.topic : conceptual
8
- ms.date : 06/11 /2019
8
+ ms.date : 06/26 /2019
9
9
---
10
10
11
11
# Audit Logs in Azure Database for MySQL
@@ -50,7 +50,7 @@ The following sections describe what's output by MySQL audit logs based on the e
50
50
| ---| ---|
51
51
| ` TenantId ` | Your tenant ID |
52
52
| ` SourceSystem ` | ` Azure ` |
53
- | ` TimeGenerated ` [ UTC] | Time stamp when the log was recorded in UTC |
53
+ | ` TimeGenerated [UTC] ` | Time stamp when the log was recorded in UTC |
54
54
| ` Type ` | Type of the log. Always ` AzureDiagnostics ` |
55
55
| ` SubscriptionId ` | GUID for the subscription that the server belongs to |
56
56
| ` ResourceGroup ` | Name of the resource group the server belongs to |
@@ -60,13 +60,14 @@ The following sections describe what's output by MySQL audit logs based on the e
60
60
| ` Resource ` | Name of the server |
61
61
| ` Category ` | ` MySqlAuditLogs ` |
62
62
| ` OperationName ` | ` LogEvent ` |
63
- | ` event_class ` | ` connection_log ` |
64
- | ` event_subclass ` | ` CONNECT ` , ` DISCONNECT ` , ` CHANGE USER ` (only available for MySQL 5.7) |
65
- | ` connection_id ` | Unique connection ID generated by MySQL |
66
- | ` host ` | Blank |
67
- | ` ip ` | IP address of client connecting to MySQL |
68
- | ` user ` | Name of user executing the query |
69
- | ` db ` | Name of database connected to |
63
+ | ` LogicalServerName_s ` | Name of the server |
64
+ | ` event_class_s ` | ` connection_log ` |
65
+ | ` event_subclass_s ` | ` CONNECT ` , ` DISCONNECT ` , ` CHANGE USER ` (only available for MySQL 5.7) |
66
+ | ` connection_id_d ` | Unique connection ID generated by MySQL |
67
+ | ` host_s ` | Blank |
68
+ | ` ip_s ` | IP address of client connecting to MySQL |
69
+ | ` user_s ` | Name of user executing the query |
70
+ | ` db_s ` | Name of database connected to |
70
71
| ` \_ResourceId ` | Resource URI |
71
72
72
73
### General
@@ -77,7 +78,7 @@ Schema below applies to GENERAL, DML_SELECT, DML_NONSELECT, DML, DDL, DCL, and A
77
78
| ---| ---|
78
79
| ` TenantId ` | Your tenant ID |
79
80
| ` SourceSystem ` | ` Azure ` |
80
- | ` TimeGenerated ` [ UTC] | Time stamp when the log was recorded in UTC |
81
+ | ` TimeGenerated [UTC] ` | Time stamp when the log was recorded in UTC |
81
82
| ` Type ` | Type of the log. Always ` AzureDiagnostics ` |
82
83
| ` SubscriptionId ` | GUID for the subscription that the server belongs to |
83
84
| ` ResourceGroup ` | Name of the resource group the server belongs to |
@@ -87,15 +88,16 @@ Schema below applies to GENERAL, DML_SELECT, DML_NONSELECT, DML, DDL, DCL, and A
87
88
| ` Resource ` | Name of the server |
88
89
| ` Category ` | ` MySqlAuditLogs ` |
89
90
| ` OperationName ` | ` LogEvent ` |
90
- | ` event_class ` | ` general_log ` |
91
- | ` event_subclass ` | ` LOG ` , ` ERROR ` , ` RESULT ` (only available for MySQL 5.6) |
91
+ | ` LogicalServerName_s ` | Name of the server |
92
+ | ` event_class_s ` | ` general_log ` |
93
+ | ` event_subclass_s ` | ` LOG ` , ` ERROR ` , ` RESULT ` (only available for MySQL 5.6) |
92
94
| ` event_time ` | Query start seconds in UNIX timestamp |
93
- | ` error_code ` | Error code if query failed. ` 0 ` means no error |
94
- | ` thread_id ` | ID of thread that executed the query |
95
- | ` host ` | Blank |
96
- | ` ip ` | IP address of client connecting to MySQL |
97
- | ` user ` | Name of user executing the query |
98
- | ` sql_text ` | Full query text |
95
+ | ` error_code_d ` | Error code if query failed. ` 0 ` means no error |
96
+ | ` thread_id_d ` | ID of thread that executed the query |
97
+ | ` host_s ` | Blank |
98
+ | ` ip_s ` | IP address of client connecting to MySQL |
99
+ | ` user_s ` | Name of user executing the query |
100
+ | ` sql_text_s ` | Full query text |
99
101
| ` \_ResourceId ` | Resource URI |
100
102
101
103
### Table access
@@ -104,7 +106,7 @@ Schema below applies to GENERAL, DML_SELECT, DML_NONSELECT, DML, DDL, DCL, and A
104
106
| ---| ---|
105
107
| ` TenantId ` | Your tenant ID |
106
108
| ` SourceSystem ` | ` Azure ` |
107
- | ` TimeGenerated ` [ UTC] | Time stamp when the log was recorded in UTC |
109
+ | ` TimeGenerated [UTC] ` | Time stamp when the log was recorded in UTC |
108
110
| ` Type ` | Type of the log. Always ` AzureDiagnostics ` |
109
111
| ` SubscriptionId ` | GUID for the subscription that the server belongs to |
110
112
| ` ResourceGroup ` | Name of the resource group the server belongs to |
@@ -114,12 +116,13 @@ Schema below applies to GENERAL, DML_SELECT, DML_NONSELECT, DML, DDL, DCL, and A
114
116
| ` Resource ` | Name of the server |
115
117
| ` Category ` | ` MySqlAuditLogs ` |
116
118
| ` OperationName ` | ` LogEvent ` |
117
- | ` event_class ` | ` table_access_log ` |
118
- | ` event_subclass ` | ` READ ` , ` INSERT ` , ` UPDATE ` , or ` DELETE ` |
119
- | ` connection_id ` | Unique connection ID generated by MySQL |
120
- | ` db ` | Name of database accessed |
121
- | ` table ` | Name of table accessed |
122
- | ` sql_text ` | Full query text |
119
+ | ` LogicalServerName_s ` | Name of the server |
120
+ | ` event_class_s ` | ` table_access_log ` |
121
+ | ` event_subclass_s ` | ` READ ` , ` INSERT ` , ` UPDATE ` , or ` DELETE ` |
122
+ | ` connection_id_d ` | Unique connection ID generated by MySQL |
123
+ | ` db_s ` | Name of database accessed |
124
+ | ` table_s ` | Name of table accessed |
125
+ | ` sql_text_s ` | Full query text |
123
126
| ` \_ResourceId ` | Resource URI |
124
127
125
128
## Next steps
0 commit comments