title: Mysql query error: Fail to read any response from the server, the underlying connection might get lost unexpectedly
body: <p>I use vertx java to build an app and writing tests for mysql queries. I can successful get results before but after I modified my.cnf because of other stuffs. I cannot no long get returned results but &quot;Fail to read any response from the server, the underlying connection might get lost unexpectedly&quot;. I searched google, but I cannot figure out exactly where is wrong and how to fix it.
  I would post my.cnf file:</p>
  <pre><code>[client]
  port    = 3306
  socket  = /tmp/mysql.sock
  # This was formally known as [safe_mysqld]. Both versions are currently parsed.
  [mysqld_safe]
  socket  = /tmp/mysql.sock 
  nice    = 0
  syslog
  
  [mysqld]
  # Basic Settings
  port = 3306
  user      = root
  pid-file  = /usr/local/mysql/data/mysqld.local.pid 
  socket    = /tmp/mysql.sock
  port      = 3306
  basedir   = /usr/local/mysql/
  datadir   = /usr/local/mysql/data
  tmpdir    = /tmp
  lc-messages-dir         = /usr/local/mysql/share
  skip-external-locking
  
  # Engine
  default-storage-engine  = InnoDB
  
  # Listening IP
  bind-address            = 0.0.0.0
  
  # Safety
  max-connect-errors      = 1000000
  max_allowed_packet      = 64M
  skip-name-resolve
  sysdate-is-now          = 1
  innodb                  = FORCE
  innodb-strict-mode      = 1
  tls_version     = TLSv1,TLSv1.1,TLSv1.2
  wait_timeout            = 28800
  interactive_timeout     = 10000
  
  # Buffers
  sort_buffer_size        = 4M
  read_buffer_size        = 2M
  join_buffer_size        = 8M
  read_rnd_buffer_size    = 16M
  
  
  # MyISAM
  key-buffer-size         = 32M
  
  # CACHES AND LIMITS #
  tmp-table-size          = 128M
  max-heap-table-size     = 128M
  
  # Bin logs
  binlog-format           = ROW
  log_bin         = /tmp/binlog
  max_binlog_size         = 100M
  
  server-id = 1 # randomize it incase of multiple servers
  
  # InnoDB
  innodb-buffer-pool-size         = 2048M
  innodb_buffer_pool_instances    = 8
  innodb_log_buffer_size          = 8M
  innodb-log-files-in-group       = 2
  innodb-log-file-size            = 256M
  innodb-file-per-table           = 1
  innodb-flush-log-at-trx-commit  = 1
  innodb-flush-method             = O_DIRECT
  
  # With virtual synchrony redundancy, make write queries faster
  innodb_doublewrite              = 1
  
  
  # LOGGING
  general_log_file                = /usr/local/mysql/mysql.log
  log-error                       = /usr/local/mysql/data/mysqld.local.err
  log-queries-not-using-indexes   = 1
  
  [mysqldump]
  quick
  quote-names
  max_allowed_packet  = 64M
  
  [isamchk]
  key_buffer    = 16M
  
  #
  # * IMPORTANT: Additional settings that can override those from this file!
  #   The files must end with '.cnf', otherwise they'll be ignored.
  #
  </code></pre>
  <p>Can you tell me what's wrong with the configuration and what should I change? Thanks</p>