You install a copy of Mysql 5.6.13 on a brand new Linux server by using RPM packages.
The server starts successfully as verified by the following commands: $ pidof mysqld 3132
$tail – n2 /var/lib.mysql/hostname.err 2013-08-18 08:18:38 3132 [Note] /usr/sbin/mysqld:
ready for connections. Version: ‘5.6.13-enterprise-commercial-advaced’ socket:
‘/tmp/mysql.sock’ port; 3306 Mysql Enterprise Server – Advanced Edition (Commercial) You
attempt to log in as the root user with the following command: $mysql –u root ERROR 1045
(28000): Access denied for user ‘root’@’localhost’ (using password: NO) Which statement is
true about this scenario?
A.
The RPM installation script sets a default password of password for new installations.
B.
The local root user must log in with a blank password initially: mysql –u root –p.
C.
New security measures mean that the mysql_secure_installation script must be run first
on all new installations.
D.
The mysql_install_bd post-installation script used – random-password.
Explanation:
D
A, default password is sent to /root if you use the RPM packages. Use ls -al then your will see the secret directory then you can cat the file to grab the password
D
Since the exam is for mysql 5.6, D is correct.
http://dev.mysql.com/doc/refman/5.6/en/mysql-install-db.html
mysql_install_db –random-passwords
which creates .mysql_secret in $HOME/.mysql_secret
But you have to reset the password, because it is created as expired.
For MySQL 5.7, a default password is created when calling:
mysqld –initialize
I agree that the answer is D because from 5.6.8 any installation via RPM package, calls the script mysql_install_db with –random-password .
https://dev.mysql.com/doc/refman/5.6/en/linux-installation-rpm.html