logo资料库

MYSQL 5.7 OCP认证最新完整166题.pdf

第1页 / 共115页
第2页 / 共115页
第3页 / 共115页
第4页 / 共115页
第5页 / 共115页
第6页 / 共115页
第7页 / 共115页
第8页 / 共115页
资料共115页,剩余部分请下载后查看
1.1 1. 1z0-888.exam 1z0-888 MySQL 5.7 Database Administrator Consider these global status variables: Which two conclusions can be made from the output? A). There are 140 Performance Schema threads at the time of the output. B). There are 510 connections to MySQL at the time of the output. C). The thread cache has been configured with thread_cache_size set to at least 6. D). There are more connections being idle than executing queries. E. All max_connections were in use at 2018-03-22 14:54:06 CD 1.2 2.
You want to create a temporary table named OLD_INVENTORY in the OLD_INVENTORY database on the master server. This table is not to be replicated to the slave server. Which two changes would ensure that the temporary table does not propagate to the slave? A). Set binlog_format=MIXED with the --replicate-ignore-temp-table option. B). Use the --replicate-do-db, --replicate-do-table, or --replicate-wild-do-table option with the value equal to OLD_INVENTORY. C). Change the binlog_format option to ROW and restart mysqld before you create the OLD_INVENTORY table. D). Stop SQL_THREAD on the slave until you have finished using the OLD_INVENTORY temporary table. E). Use the --replicate-ignore-table option with the value equal to OLD_INVENTORY.OLD_INVENTORY and restart mysqld before creating the temporary table. CE 1.3 3. The MySQL error log shows: InnoDB: Warning: a long semaphore wait: The relevant parts of the InnoDB monitor output shows: Which two options would help avoid the long wait in the future? A). Increase the value of the innodb_lock_wait_timeout option. B). Increase the value of the innodb_read_io_threads option. C). Change the table to use HASH indexes instead of BTREE indexes. D). Set the value of innodb_adaptive_hash_index to zero. E). Deactivate the query cache. F). Increase the size of the InnoDB buffer pool. DE
1.4 4.
A simple master-to-slave replication is currently being used. This information is extracted from the SHOW SLAVE STATUS output: You execute a "SHOW CREATE TABLE mytable" on the slave: You have issued a STOP SLAVE command. You have determined that it is safe to skip the transaction in this case. One or more statements are required before you can issue a START SLAVE command to resolve the duplicate key error. Which statement should be used? A). SET GTID_NEXT="CONSISTENCY"; BEGIN; COMMIT; SET GTID_NEXT="AUTOMATIC"; B). SET GTID_NEXT="5da6b4f5-6f60-11e8-b2d6-0010e05f3e06:8"; BEGIN; COMMIT; SET GTID_NEXT="AUTOMATIC"; C). SET GLOBAL SQL_SKIP_SLAVE_COUNTER=1 D). SET GLOBAL enforce_gtid_consistency=ON E). SET GTID_EXECUTED="5da6b4f5-6f60-11e8-b2d6-0010e05f3e06:8"; B 1.5 5. A single InnoDB table has been dropped by accident. You are unable to use an additional intermediate MySQL instance to restore the table. Which two backup methods can be used to restore the single table without stopping the MySQL instance?
A). a backup created with mysqldump --all-databases B). a backup created using FLUSH TABLES … FOR EXPORT C). an up-to-date replication slave D). a file system-level snapshot E). a file system copy created while MySQL was shut down AB 1.6 6. The /myfolder/my.cnf file has option set: [mysqld] skip-log-bin /myfolder2/my.cnf has this option set: [mysqld] log-bin = /valid/path/to/mysqlbinlog All mentioned paths are accessible to the account that you are currently using. Assume that any other options mentioned in either file are valid and legal option definitions. You start an instance by using this command line: mysqld --defaults-file=/myfolder/my.cnf --defaults-extra- file=/myfolder2/my.cnf What is the outcome? A). MySQL starts and Binary Logging is enabled. B). MySQL fails to start due to the conflicting options in the configuration files. C). MySQL fails to start due to conflicting options on the command line. D). MySQL starts but Binary Logging is disabled. D 1.7 7. Why should you be selective when granting the PROCESS privilege to an account? A). It allows a client to see another user's queries with the SHOW PROCESSLIST command. B). It allows a client to control running process on a server. C). It allows a client to process scripts. D). It allows the use of stored routines. A 1.8 8. As the root user, you attempt to start MySQL and find this error in the error log: mysqld: Can’t change dir to '/var/lib/mysql/' (Errcode: 13 - Permission denied)
The user option is set to mysql in /etc/my.cnf. What is the reason for this error and how do you fix it? A). You forgot to add datadir=/var/lib/mysql to the configuration.
B). You should not run the command as root. Running the command as the mysqladmin user will solv e the problem. C). You cannot start MySQL without creating service values first. Check the permission for service values in /etc/init.d to see if the internet service daemon is working and try again. D). You forgot to add password variables to the configuration so it cannot change the user. E). The owner of /var/lib/mysql is root. Change the ownership to mysql and retry the command. E 1.9 9. You are remotely logged in to MySQL as the user "backup". The account has temporarily been granted full privileges WITH GRANT to perform the actions required. You want to change the password for the locally existing "backup" user. Select the three command which will perform the required action. A). ALTER USER USER() IDENTIFIED BY 'password'; B). CREATE USER 'backup'@'localhost' IDENTIFIED BY 'password'; C). ALTER USER 'backup'@'localhost' IDENTIFIED BY 'password'; D). SET PASSWORD FOR 'backup'@'localhost' = PASSWORD('password') E). ALTER USER 'backup' IDENTIFIED BY 'password'; F). SET PASSWORD= 'password'; G). SET PASSWORD FOR 'backup'@'localhost' = 'password'; ACD 1.10 10. Which storage option for MySQL data directory typically offers the worst performance in a highly concurrent, OLTP-heavy, IO-bound workload? A). iSCSI Lun B). SAN (Fibre Channel) Lun C). NFS (Networked File System) mount D). battery-backed locally-attached RAID 5 array C 1.11 11. What are three methods to attempt SQL injection? A). Include single and double quotes in the submitted data. B). Enter non-numeric values in numeric fields. C). Enter falsified values of the correct data type.
D). Modify the URL using percent encoding. E). Enter numeric values into text fields. F). Resend form data submitted using the POST method. CDF
分享到:
收藏