AWS Certified Database – Specialty – Question167

A database specialist needs to configure an Amazon RDS for MySQL DB instance to close non-interactive connections that are inactive after 900 seconds.
What should the database specialist do to accomplish this task?

A.
Create a custom DB parameter group and set the wait_timeout parameter value to 900. Associate the DB instance with the custom parameter group.
B. Connect to the MySQL database and run the SET SESSION wait_timeout=900 command.
C. Edit the my.cnf file and set the wait_timeout parameter value to 900. Restart the DB instance.
D. Modify the default DB parameter group and set the wait_timeout parameter value to 900.

Correct Answer: B

Explanation:

Explanation:
If we set the wait_timeout variable for a session, it will valid only for a particular session. But when we set the wait_timeout variable globally it will valid for all the sessions.
Reference: https://dilsichandrasena.medium.com/changing-mysql-wait-timeout-var…