PHP MySQL set Connection Timeout

后端 未结 6 684
醉梦人生
醉梦人生 2020-12-17 18:19

There are certain posts on MySQL connection set time out from PHP using mysql.connect_timeout. I want to know if this set timeout from PHP just time out the initial connecti

6条回答
  •  囚心锁ツ
    2020-12-17 18:49

    The connect_timeout parameter is only valid at connection time. It's useful to check if your DB server is reachable in 20 seconds or so. Once connected the specified timeout is no longer valid.

    I don't find any query timeout parameter on official mysql manual page: http://dev.mysql.com/doc/refman/5.5/en/server-system-variables.html so I don't think this is possibile.

提交回复
热议问题