hironomiu's Blog

こそっと書いていきます。twitter_id:hironomiu

AWS RDS init_connectを設定した際の不具合

AWSのRDSでinit_connectにtimezone設定をしているサービスでの出来事

AWS側のメンテナンスでRDSの再起動が掛かった後、下のように接続が拒否された。

[root@XXXXX ~]# mysql

Welcome to the MySQL monitor.  Commands end with ; or \g.

Your MySQL connection id is 665

Server version: 5.5.12-log

 

Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.

This software comes with ABSOLUTELY NO WARRANTY. This is free software,

and you are welcome to modify and redistribute it under the GPL v2 license

 

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

 

mysql> show databases;

ERROR 2006 (HY000): MySQL server has gone away

No connection. Trying to reconnect...

Connection id:    666

Current database: *** NONE ***

 

ERROR 2013 (HY000): Lost connection to MySQL server during query

 

サイトエンジニアの調査で、これが原因だったらしい。

https://forums.aws.amazon.com/thread.jspa?messageID=239869