From 86f6104e028cc8a032dc35f4f7559831fe6c7c20 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ren=C3=A9=20Canna=C3=B2?= Date: Fri, 20 Sep 2019 13:17:04 +1000 Subject: [PATCH] More verbosity on Ping timeout during ping #2265 --- lib/MySQL_Session.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/MySQL_Session.cpp b/lib/MySQL_Session.cpp index c38358c4f..5ea702815 100644 --- a/lib/MySQL_Session.cpp +++ b/lib/MySQL_Session.cpp @@ -1445,7 +1445,10 @@ int MySQL_Session::handler_again___status_PINGING_SERVER() { } else { if (rc==-1 || rc==-2) { if (rc==-2) { - proxy_error("Ping timeout during ping on %s , %d\n", myconn->parent->address, myconn->parent->port); + unsigned long long us = mysql_thread___ping_timeout_server*1000; + us += thread->curtime; + us -= myds->wait_until; + proxy_error("Ping timeout during ping on %s:%d after %lluus (timeout %dms)\n", myconn->parent->address, myconn->parent->port, us, mysql_thread___ping_timeout_server); } else { // rc==-1 int myerr=mysql_errno(myconn->mysql); proxy_error("Detected a broken connection during ping on (%d,%s,%d) , FD (Conn:%d , MyDS:%d) : %d, %s\n", myconn->parent->myhgc->hid, myconn->parent->address, myconn->parent->port, myds->fd, myds->myconn->fd, myerr, mysql_error(myconn->mysql));