biotwang 发表于 2016-7-20 11:49:10

【dbdao.com MySQL OCP认证专题】- MySQL 5.6 - OCP 考题讲解 - 13

【dbdao.com MySQL OCP认证专题】- MySQL 5.6 - OCP 考题讲解

13.

Consider the Mysql Enterprise Audit plugin.
A CSV file called data.csv has 100 rows of data.
The stored procedure prepare_db() has 10 auditable statements.
You run the following statements in the mydb database:mysql> CALL prepare_db();
mysql> LOAD DATA INFILE '/tmp/data.cav' INTO TABLE mytable;
mysql> SHOW TABLES;How many events are added to the audit log as a result of the preceding statements?


A. 102; top-level statements are logged, but LOAD DATA INFILE is logged as a separate event.
B. 3; only the top-level statements are logged.
C. 111; top-level statements and all lower-level statements are logged.
D. 12; only top-level statements and stored procedure events are logged.
----------------------------------------

答案:B

分析:
audit.log文件中每个<AUDIT_RECORD>元素代表了一个事件,如客户连接或关闭连接事件,执行SQL语句等。
仅顶层语句会被记录下来,存储程序(如触发器或存储过程)中的语句不会被记录。
命令如LOAD DATA INFILE在进行操作时,其对文件内容进行进行操作的具体细节不会被记录。
因此,A, C, D错,B正确。

参考:
http://dev.mysql.com/doc/refman/5.7/en/audit-log-plugin-logging-control.html
页: [1]
查看完整版本: 【dbdao.com MySQL OCP认证专题】- MySQL 5.6 - OCP 考题讲解 - 13