What should the database specialist do to accomplish this task?
Create a custom DB parameter group and set the wait_timeout parameter value to 900. Associate the DB instance with the custom parameter group.
Connect to the MySQL database and run the SET SESSION wait_timeout=900 command.
Edit the my.cnf file and set the wait_timeout parameter value to 900. Restart the DB instance.
Modify the default DB parameter group and set the wait_timeout parameter value to 900.
Explanations:
Creating a custom DB parameter group and setting thewait_timeoutto 900 is the correct approach for configuring the timeout for non-interactive connections. Associating the DB instance with the custom parameter group ensures the change is applied persistently.
TheSET SESSION wait_timeoutcommand only modifies the timeout for the current session and is not persistent across database restarts. It doesn’t apply to all connections, nor does it persist after the DB instance is restarted.
Amazon RDS doesn’t allow direct access to themy.cnffile for customization, so this option is not feasible in the RDS environment.
Modifying the default DB parameter group is not possible in Amazon RDS. The default parameter group is immutable; custom parameter groups must be created and applied for changes to take effect.